diff --git a/android/app/build.gradle b/android/app/build.gradle index d95bf24..5f85a5d 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -1,8 +1,8 @@ def localProperties = new Properties() def localPropertiesFile = rootProject.file('local.properties') if (localPropertiesFile.exists()) { - localPropertiesFile.withInputStream { stream -> - localProperties.load(stream) + localPropertiesFile.withReader('UTF-8') { reader -> + localProperties.load(reader) } } @@ -48,6 +48,7 @@ android { signingConfig signingConfigs.debug } release { + shrinkResources false minifyEnabled false signingConfig signingConfigs.release proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' diff --git a/android/build.gradle b/android/build.gradle index 581b100..31bd497 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -6,7 +6,7 @@ buildscript { } dependencies { - classpath 'com.android.tools.build:gradle:3.4.2' + classpath 'com.android.tools.build:gradle:3.5.0' classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" } } diff --git a/android/gradle.properties b/android/gradle.properties index 53ae0ae..b0bc401 100644 --- a/android/gradle.properties +++ b/android/gradle.properties @@ -1,3 +1,4 @@ android.enableJetifier=true android.useAndroidX=true org.gradle.jvmargs=-Xmx1536M +android.enableR8=false diff --git a/lib/main.dart b/lib/main.dart index ffc5c81..50ca567 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -1,21 +1,20 @@ import 'dart:async'; import 'package:checker/db.dart'; +import 'package:checker/screens/splash.dart'; import 'package:checker/strings.dart'; import 'package:flutter/material.dart'; -import 'package:checker/screens/splash.dart'; import 'package:flutter/services.dart'; import 'package:sentry/sentry.dart'; const platform = const MethodChannel('com.dinect.checker/instance_id'); main() { - + WidgetsFlutterBinding.ensureInitialized(); platform.invokeMethod('getFlavor').then((flavor) { platform.invokeMethod('getAppTitle').then((title) { - - String app = flavor; // dinect, autobonus - String appName= title; // Dinect, Dinect (INT), Autobonus + String app = flavor; // dinect, autobonus + String appName = title; // Dinect, Dinect (INT), Autobonus SqliteHelper helper = new SqliteHelper(); @@ -32,7 +31,8 @@ main() { }); } -initWithSystemValue(String app, String name, String locale, SqliteHelper helper) { +initWithSystemValue( + String app, String name, String locale, SqliteHelper helper) { helper.getSettings(false).then((settings) { if (settings.isEmpty) { createSettingsTable(app, name, helper); @@ -54,7 +54,7 @@ createSettingsTable(String app, String name, SqliteHelper helper) { start(String app, String name, String locale, SqliteHelper helper) { final SentryClient sentry = new SentryClient( - dsn: 'https://42166056b75d4fe49455555a9bc576a0@sentry.io/1376057'); + dsn: 'https://42166056b75d4fe49455555a9bc576a0@sentry.io/1376057'); FlutterError.onError = (FlutterErrorDetails details) { FlutterError.dumpErrorToConsole(details); @@ -74,7 +74,6 @@ start(String app, String name, String locale, SqliteHelper helper) { } class Checker extends StatefulWidget { - final SqliteHelper helper; final String app; final String appName; @@ -82,14 +81,11 @@ class Checker extends StatefulWidget { Checker(this.app, this.appName, this.helper); @override - State createState() => new CheckerState( - this.app, - this.appName, - this.helper); + State createState() => + new CheckerState(this.app, this.appName, this.helper); } class CheckerState extends State { - SqliteHelper helper; String app; String appName; @@ -98,9 +94,6 @@ class CheckerState extends State { @override Widget build(BuildContext context) { - return new MaterialApp( - title: appName, - home: new SplashScreen(helper, app) - ); + return new MaterialApp(title: appName, home: new SplashScreen(helper, app)); } } diff --git a/pubspec.lock b/pubspec.lock index ba1a54a..96f8061 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -7,14 +7,14 @@ packages: name: async url: "https://pub.dartlang.org" source: hosted - version: "2.0.8" + version: "2.4.0" charcode: dependency: transitive description: name: charcode url: "https://pub.dartlang.org" source: hosted - version: "1.1.2" + version: "1.1.3" collection: dependency: transitive description: @@ -29,18 +29,18 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "2.1.1" - dart2_constant: - dependency: transitive - description: - name: dart2_constant - url: "https://pub.dartlang.org" - source: hosted - version: "1.0.2+dart2" flutter: dependency: "direct main" description: flutter source: sdk version: "0.0.0" + flutter_plugin_android_lifecycle: + dependency: transitive + description: + name: flutter_plugin_android_lifecycle + url: "https://pub.dartlang.org" + source: hosted + version: "1.0.6" http: dependency: "direct main" description: @@ -61,7 +61,7 @@ packages: name: image_picker url: "https://pub.dartlang.org" source: hosted - version: "0.6.1+11" + version: "0.6.3+4" intl: dependency: "direct main" description: @@ -69,34 +69,27 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "0.16.1" - matcher: - dependency: transitive - description: - name: matcher - url: "https://pub.dartlang.org" - source: hosted - version: "0.12.6" meta: dependency: transitive description: name: meta url: "https://pub.dartlang.org" source: hosted - version: "1.1.7" + version: "1.1.8" path: dependency: transitive description: name: path url: "https://pub.dartlang.org" source: hosted - version: "1.6.2" + version: "1.6.4" path_provider: dependency: "direct main" description: name: path_provider url: "https://pub.dartlang.org" source: hosted - version: "1.4.5" + version: "1.6.1" pedantic: dependency: transitive description: @@ -118,20 +111,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "2.2.1" - quiver: - dependency: transitive - description: - name: quiver - url: "https://pub.dartlang.org" - source: hosted - version: "0.29.0+2" sentry: dependency: "direct main" description: name: sentry url: "https://pub.dartlang.org" source: hosted - version: "2.0.1" + version: "3.0.1" sky_engine: dependency: transitive description: flutter @@ -143,7 +129,7 @@ packages: name: source_span url: "https://pub.dartlang.org" source: hosted - version: "1.4.1" + version: "1.6.0" sprintf: dependency: "direct main" description: @@ -157,7 +143,7 @@ packages: name: sqflite url: "https://pub.dartlang.org" source: hosted - version: "1.1.8" + version: "1.2.1" stack_trace: dependency: transitive description: @@ -171,14 +157,21 @@ packages: name: string_scanner url: "https://pub.dartlang.org" source: hosted - version: "1.0.4" + version: "1.0.5" synchronized: dependency: transitive description: name: synchronized url: "https://pub.dartlang.org" source: hosted - version: "2.1.1" + version: "2.2.0" + term_glyph: + dependency: transitive + description: + name: term_glyph + url: "https://pub.dartlang.org" + source: hosted + version: "1.1.0" typed_data: dependency: transitive description: @@ -206,7 +199,7 @@ packages: name: xml url: "https://pub.dartlang.org" source: hosted - version: "3.5.0" + version: "3.6.0" sdks: - dart: ">=2.5.0 <3.0.0" - flutter: ">=1.9.1+hotfix.5 <2.0.0" + dart: ">=2.6.0 <3.0.0" + flutter: ">=1.12.13 <2.0.0" diff --git a/pubspec.yaml b/pubspec.yaml index d97fa6c..ed0f4ba 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -4,11 +4,11 @@ description: A new Flutter project. dependencies: http: '0.12.0+4' sprintf: "4.0.2" - path_provider: "1.4.5" - sqflite: "1.1.8" - image_picker: '0.6.1+11' # use for ask permissions @ iOS - xml: "3.5.0" - sentry: 2.0.1 + path_provider: "1.6.1" + sqflite: "1.2.1" + image_picker: '0.6.3+4' # use for ask permissions @ iOS + xml: "3.6.0" + sentry: 3.0.1 intl: 0.16.1 flutter: sdk: flutter