diff --git a/client/android/app/build.gradle b/client/android/app/build.gradle index 1ee7748..5ca598a 100644 --- a/client/android/app/build.gradle +++ b/client/android/app/build.gradle @@ -50,6 +50,10 @@ android { // TODO: Add your own signing config for the release build. // Signing with the debug keys for now, so `flutter run --release` works. signingConfig signingConfigs.debug + minifyEnabled true + useProguard true + + proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' } } aaptOptions { diff --git a/client/android/app/proguard-rules.pro b/client/android/app/proguard-rules.pro new file mode 100644 index 0000000..13f3f3f --- /dev/null +++ b/client/android/app/proguard-rules.pro @@ -0,0 +1,8 @@ +#Flutter Wrapper +-keep class io.flutter.app.** { *; } +-keep class io.flutter.plugin.** { *; } +-keep class io.flutter.util.** { *; } +-keep class io.flutter.view.** { *; } +-keep class io.flutter.** { *; } +-keep class io.flutter.plugins.** { *; } +-keep class com.dexterous.** { *; } \ No newline at end of file diff --git a/client/lib/pages/plant-detail.dart b/client/lib/pages/plant-detail.dart index 5e0c9fc..d4318dc 100644 --- a/client/lib/pages/plant-detail.dart +++ b/client/lib/pages/plant-detail.dart @@ -23,7 +23,7 @@ class PlantDetail extends StatelessWidget { assert(plant != null), assert(getUserPlantImage != null); - CachedNetworkImage userPlantImage; + Future userPlantImage; @override Widget build(BuildContext context) { @@ -90,7 +90,7 @@ class PlantDetail extends StatelessWidget { alignment: Alignment.topRight, child: RawMaterialButton( onPressed: () async { - Navigator.pushReplacementNamed(context, '/add-plant', arguments: { 'plant': userPlant, 'userPlantImage': userPlantImage}); + Navigator.pushReplacementNamed(context, '/add-plant', arguments: { 'plant': userPlant, 'userPlantImage': await userPlantImage}); }, elevation: 2.0, fillColor: theme.accentColor, diff --git a/client/push.bat b/client/push.bat new file mode 100644 index 0000000..63695fb --- /dev/null +++ b/client/push.bat @@ -0,0 +1,2 @@ +C:\\Users\\pedro\\AppData\\Local\\Android\\Sdk\\platform-tools\\adb.exe install D:\\Files\\Dev\\GitHub\\ProjectD\\client\\build\\app\\outputs\\apk\\release\\app-release.apk +C:\\Users\\pedro\\AppData\\Local\\Android\\Sdk\\platform-tools\\adb.exe shell am start -n nl.bylivingart.plantexpert/.MainActivity \ No newline at end of file