Skip to content

Commit b7ec38a

Browse files
provider_counter: update android and ios, add macos and web (#235)
1 parent 738861f commit b7ec38a

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+1378
-44
lines changed
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
gradle-wrapper.jar
2+
/.gradle
3+
/captures/
4+
/gradlew
5+
/gradlew.bat
6+
/local.properties
7+
GeneratedPluginRegistrant.java

provider_counter/android/app/build.gradle

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ android {
4343
targetSdkVersion 28
4444
versionCode flutterVersionCode.toInteger()
4545
versionName flutterVersionName
46-
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
46+
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
4747
}
4848

4949
buildTypes {
@@ -62,6 +62,6 @@ flutter {
6262
dependencies {
6363
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
6464
testImplementation 'junit:junit:4.12'
65-
androidTestImplementation 'com.android.support.test:runner:1.0.2'
66-
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
65+
androidTestImplementation 'androidx.test:runner:1.1.1'
66+
androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.1'
6767
}
Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
22
package="dev.flutter.provider_counter">
3-
43
<!-- io.flutter.app.FlutterApplication is an android.app.Application that
54
calls FlutterMain.startInitialization(this); in its onCreate method.
65
In most cases you can leave this as-is, but you if you want to provide
@@ -14,20 +13,18 @@
1413
android:name=".MainActivity"
1514
android:launchMode="singleTop"
1615
android:theme="@style/LaunchTheme"
17-
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
16+
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
1817
android:hardwareAccelerated="true"
1918
android:windowSoftInputMode="adjustResize">
20-
<!-- This keeps the window background of the activity showing
21-
until Flutter renders its first frame. It can be removed if
22-
there is no splash screen (such as the default splash screen
23-
defined in @style/LaunchTheme). -->
24-
<meta-data
25-
android:name="io.flutter.app.android.SplashScreenUntilFirstFrame"
26-
android:value="true" />
2719
<intent-filter>
2820
<action android:name="android.intent.action.MAIN"/>
2921
<category android:name="android.intent.category.LAUNCHER"/>
3022
</intent-filter>
3123
</activity>
24+
<!-- Don't delete the meta-data below.
25+
This is used by the Flutter tool to generate GeneratedPluginRegistrant.java -->
26+
<meta-data
27+
android:name="flutterEmbedding"
28+
android:value="2" />
3229
</application>
3330
</manifest>
Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
package dev.flutter.provider_counter
22

3-
import android.os.Bundle
4-
5-
import io.flutter.app.FlutterActivity
3+
import androidx.annotation.NonNull;
4+
import io.flutter.embedding.android.FlutterActivity
5+
import io.flutter.embedding.engine.FlutterEngine
66
import io.flutter.plugins.GeneratedPluginRegistrant
77

88
class MainActivity: FlutterActivity() {
9-
override fun onCreate(savedInstanceState: Bundle?) {
10-
super.onCreate(savedInstanceState)
11-
GeneratedPluginRegistrant.registerWith(this)
12-
}
9+
override fun configureFlutterEngine(@NonNull flutterEngine: FlutterEngine) {
10+
GeneratedPluginRegistrant.registerWith(flutterEngine);
11+
}
1312
}

provider_counter/android/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
buildscript {
2-
ext.kotlin_version = '1.2.71'
2+
ext.kotlin_version = '1.3.50'
33
repositories {
44
google()
55
jcenter()
66
}
77

88
dependencies {
9-
classpath 'com.android.tools.build:gradle:3.2.1'
9+
classpath 'com.android.tools.build:gradle:3.5.0'
1010
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
1111
}
1212
}
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,4 @@
11
org.gradle.jvmargs=-Xmx1536M
2+
android.enableR8=true
3+
android.useAndroidX=true
4+
android.enableJetifier=true

provider_counter/android/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
33
distributionPath=wrapper/dists
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists
6-
distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.2-all.zip
6+
distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.2-all.zip

provider_counter/ios/.gitignore

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
*.mode1v3
2+
*.mode2v3
3+
*.moved-aside
4+
*.pbxuser
5+
*.perspectivev3
6+
**/*sync/
7+
.sconsign.dblite
8+
.tags*
9+
**/.vagrant/
10+
**/DerivedData/
11+
Icon?
12+
**/Pods/
13+
**/.symlinks/
14+
profile
15+
xcuserdata
16+
**/.generated/
17+
Flutter/App.framework
18+
Flutter/Flutter.framework
19+
Flutter/Flutter.podspec
20+
Flutter/Generated.xcconfig
21+
Flutter/app.flx
22+
Flutter/app.zip
23+
Flutter/flutter_assets/
24+
Flutter/flutter_export_environment.sh
25+
ServiceDefinitions.json
26+
Runner/GeneratedPluginRegistrant.*
27+
28+
# Exceptions to above rules.
29+
!default.mode1v3
30+
!default.mode2v3
31+
!default.pbxuser
32+
!default.perspectivev3

provider_counter/ios/Flutter/AppFrameworkInfo.plist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<plist version="1.0">
44
<dict>
55
<key>CFBundleDevelopmentRegion</key>
6-
<string>en</string>
6+
<string>$(DEVELOPMENT_LANGUAGE)</string>
77
<key>CFBundleExecutable</key>
88
<string>App</string>
99
<key>CFBundleIdentifier</key>

provider_counter/ios/Runner.xcodeproj/project.pbxproj

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; };
1515
9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; };
1616
9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
17-
9740EEB41CF90195004384FC /* Debug.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 9740EEB21CF90195004384FC /* Debug.xcconfig */; };
1817
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
1918
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
2019
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
@@ -148,18 +147,18 @@
148147
97C146E61CF9000F007C117D /* Project object */ = {
149148
isa = PBXProject;
150149
attributes = {
151-
LastUpgradeCheck = 0910;
152-
ORGANIZATIONNAME = "The Chromium Authors";
150+
LastUpgradeCheck = 1020;
151+
ORGANIZATIONNAME = "";
153152
TargetAttributes = {
154153
97C146ED1CF9000F007C117D = {
155154
CreatedOnToolsVersion = 7.3.1;
156-
LastSwiftMigration = 0910;
155+
LastSwiftMigration = 1100;
157156
};
158157
};
159158
};
160159
buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */;
161160
compatibilityVersion = "Xcode 3.2";
162-
developmentRegion = English;
161+
developmentRegion = en;
163162
hasScannedForEncodings = 0;
164163
knownRegions = (
165164
en,
@@ -182,7 +181,6 @@
182181
files = (
183182
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */,
184183
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */,
185-
9740EEB41CF90195004384FC /* Debug.xcconfig in Resources */,
186184
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */,
187185
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */,
188186
);
@@ -267,12 +265,14 @@
267265
CLANG_WARN_BOOL_CONVERSION = YES;
268266
CLANG_WARN_COMMA = YES;
269267
CLANG_WARN_CONSTANT_CONVERSION = YES;
268+
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
270269
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
271270
CLANG_WARN_EMPTY_BODY = YES;
272271
CLANG_WARN_ENUM_CONVERSION = YES;
273272
CLANG_WARN_INFINITE_RECURSION = YES;
274273
CLANG_WARN_INT_CONVERSION = YES;
275274
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
275+
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
276276
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
277277
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
278278
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
@@ -296,6 +296,7 @@
296296
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
297297
MTL_ENABLE_DEBUG_INFO = NO;
298298
SDKROOT = iphoneos;
299+
SUPPORTED_PLATFORMS = iphoneos;
299300
TARGETED_DEVICE_FAMILY = "1,2";
300301
VALIDATE_PRODUCT = YES;
301302
};
@@ -306,8 +307,8 @@
306307
baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
307308
buildSettings = {
308309
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
310+
CLANG_ENABLE_MODULES = YES;
309311
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
310-
DEVELOPMENT_TEAM = S8QB4VV633;
311312
ENABLE_BITCODE = NO;
312313
FRAMEWORK_SEARCH_PATHS = (
313314
"$(inherited)",
@@ -321,7 +322,8 @@
321322
);
322323
PRODUCT_BUNDLE_IDENTIFIER = dev.flutter.providerCounter;
323324
PRODUCT_NAME = "$(TARGET_NAME)";
324-
SWIFT_VERSION = 4.0;
325+
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
326+
SWIFT_VERSION = 5.0;
325327
VERSIONING_SYSTEM = "apple-generic";
326328
};
327329
name = Profile;
@@ -340,12 +342,14 @@
340342
CLANG_WARN_BOOL_CONVERSION = YES;
341343
CLANG_WARN_COMMA = YES;
342344
CLANG_WARN_CONSTANT_CONVERSION = YES;
345+
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
343346
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
344347
CLANG_WARN_EMPTY_BODY = YES;
345348
CLANG_WARN_ENUM_CONVERSION = YES;
346349
CLANG_WARN_INFINITE_RECURSION = YES;
347350
CLANG_WARN_INT_CONVERSION = YES;
348351
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
352+
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
349353
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
350354
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
351355
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
@@ -394,12 +398,14 @@
394398
CLANG_WARN_BOOL_CONVERSION = YES;
395399
CLANG_WARN_COMMA = YES;
396400
CLANG_WARN_CONSTANT_CONVERSION = YES;
401+
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
397402
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
398403
CLANG_WARN_EMPTY_BODY = YES;
399404
CLANG_WARN_ENUM_CONVERSION = YES;
400405
CLANG_WARN_INFINITE_RECURSION = YES;
401406
CLANG_WARN_INT_CONVERSION = YES;
402407
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
408+
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
403409
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
404410
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
405411
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
@@ -423,6 +429,7 @@
423429
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
424430
MTL_ENABLE_DEBUG_INFO = NO;
425431
SDKROOT = iphoneos;
432+
SUPPORTED_PLATFORMS = iphoneos;
426433
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
427434
TARGETED_DEVICE_FAMILY = "1,2";
428435
VALIDATE_PRODUCT = YES;
@@ -451,8 +458,7 @@
451458
PRODUCT_NAME = "$(TARGET_NAME)";
452459
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
453460
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
454-
SWIFT_SWIFT3_OBJC_INFERENCE = On;
455-
SWIFT_VERSION = 4.0;
461+
SWIFT_VERSION = 5.0;
456462
VERSIONING_SYSTEM = "apple-generic";
457463
};
458464
name = Debug;
@@ -478,8 +484,7 @@
478484
PRODUCT_BUNDLE_IDENTIFIER = dev.flutter.providerCounter;
479485
PRODUCT_NAME = "$(TARGET_NAME)";
480486
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
481-
SWIFT_SWIFT3_OBJC_INFERENCE = On;
482-
SWIFT_VERSION = 4.0;
487+
SWIFT_VERSION = 5.0;
483488
VERSIONING_SYSTEM = "apple-generic";
484489
};
485490
name = Release;
@@ -508,7 +513,6 @@
508513
defaultConfigurationName = Release;
509514
};
510515
/* End XCConfigurationList section */
511-
512516
};
513517
rootObject = 97C146E61CF9000F007C117D /* Project object */;
514518
}

0 commit comments

Comments
 (0)