WT1.1.0+42 error fixes
This commit is contained in:
parent
2aecb9d431
commit
14b5b44347
@ -52,14 +52,14 @@ android {
|
|||||||
multiDexEnabled true
|
multiDexEnabled true
|
||||||
}
|
}
|
||||||
|
|
||||||
/*signingConfigs {
|
signingConfigs {
|
||||||
release {
|
release {
|
||||||
keyAlias keystoreProperties['keyAlias']
|
keyAlias keystoreProperties['keyAlias']
|
||||||
keyPassword keystoreProperties['keyPassword']
|
keyPassword keystoreProperties['keyPassword']
|
||||||
storeFile keystoreProperties['storeFile'] ? file(keystoreProperties['storeFile']) : null
|
storeFile keystoreProperties['storeFile'] ? file(keystoreProperties['storeFile']) : null
|
||||||
storePassword keystoreProperties['storePassword']
|
storePassword keystoreProperties['storePassword']
|
||||||
}
|
}
|
||||||
}*/
|
}
|
||||||
|
|
||||||
buildTypes {
|
buildTypes {
|
||||||
release {
|
release {
|
||||||
@ -79,3 +79,4 @@ dependencies {
|
|||||||
implementation 'com.facebook.android:facebook-login:5.15.3'
|
implementation 'com.facebook.android:facebook-login:5.15.3'
|
||||||
implementation 'com.android.support:multidex:1.0.3'
|
implementation 'com.android.support:multidex:1.0.3'
|
||||||
}
|
}
|
||||||
|
sourceCompatibility = '1.8'
|
@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
|
|||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
zipStorePath=wrapper/dists
|
zipStorePath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-6.4-bin.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-6.5-bin.zip
|
||||||
|
@ -128,8 +128,8 @@
|
|||||||
"2nd Control": "2nd Control",
|
"2nd Control": "2nd Control",
|
||||||
"3rd Control": "3rd Control",
|
"3rd Control": "3rd Control",
|
||||||
|
|
||||||
"My Development":"My Development",
|
"My Development":"Development",
|
||||||
"My Training Plan":"My Training Plan",
|
"My Training Plan":"Training Plan",
|
||||||
|
|
||||||
"Please add an exercise plan": "Please add an exercise plan",
|
"Please add an exercise plan": "Please add an exercise plan",
|
||||||
"Serie": "Serie",
|
"Serie": "Serie",
|
||||||
@ -183,7 +183,7 @@
|
|||||||
|
|
||||||
"Persistence!": "Persistence!",
|
"Persistence!": "Persistence!",
|
||||||
"Greetings!": "Greetings!",
|
"Greetings!": "Greetings!",
|
||||||
"The purpose is to measure you physical condition": "The purpose is to measure you physical condition.",
|
"The purpose is to measure you physical condition": "The purpose is to measure your physical condition.",
|
||||||
"The suggested order of the exercises: chest - biceps - triceps - back - shoulders - core - tigh - calf.": "The suggested order of the exercises: chest - biceps - triceps - back - shoulders - core - tigh - calf.",
|
"The suggested order of the exercises: chest - biceps - triceps - back - shoulders - core - tigh - calf.": "The suggested order of the exercises: chest - biceps - triceps - back - shoulders - core - tigh - calf.",
|
||||||
"Go to the menu Strength - One Rep Max - Chest, and select your favourite exercise.": "Go to the menu Strength - One Rep Max - Chest, and select your favourite exercise.",
|
"Go to the menu Strength - One Rep Max - Chest, and select your favourite exercise.": "Go to the menu Strength - One Rep Max - Chest, and select your favourite exercise.",
|
||||||
"Please continue your tests with a": "Please continue your tests with a",
|
"Please continue your tests with a": "Please continue your tests with a",
|
||||||
|
@ -366,7 +366,7 @@
|
|||||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||||
CLANG_ENABLE_MODULES = YES;
|
CLANG_ENABLE_MODULES = YES;
|
||||||
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
|
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
|
||||||
CURRENT_PROJECT_VERSION = 41;
|
CURRENT_PROJECT_VERSION = 42;
|
||||||
DEVELOPMENT_TEAM = SFJJBDCU6Z;
|
DEVELOPMENT_TEAM = SFJJBDCU6Z;
|
||||||
ENABLE_BITCODE = NO;
|
ENABLE_BITCODE = NO;
|
||||||
FRAMEWORK_SEARCH_PATHS = (
|
FRAMEWORK_SEARCH_PATHS = (
|
||||||
@ -509,7 +509,7 @@
|
|||||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||||
CLANG_ENABLE_MODULES = YES;
|
CLANG_ENABLE_MODULES = YES;
|
||||||
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
|
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
|
||||||
CURRENT_PROJECT_VERSION = 41;
|
CURRENT_PROJECT_VERSION = 42;
|
||||||
DEVELOPMENT_TEAM = SFJJBDCU6Z;
|
DEVELOPMENT_TEAM = SFJJBDCU6Z;
|
||||||
ENABLE_BITCODE = NO;
|
ENABLE_BITCODE = NO;
|
||||||
FRAMEWORK_SEARCH_PATHS = (
|
FRAMEWORK_SEARCH_PATHS = (
|
||||||
@ -544,7 +544,7 @@
|
|||||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||||
CLANG_ENABLE_MODULES = YES;
|
CLANG_ENABLE_MODULES = YES;
|
||||||
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
|
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
|
||||||
CURRENT_PROJECT_VERSION = 41;
|
CURRENT_PROJECT_VERSION = 42;
|
||||||
DEVELOPMENT_TEAM = SFJJBDCU6Z;
|
DEVELOPMENT_TEAM = SFJJBDCU6Z;
|
||||||
ENABLE_BITCODE = NO;
|
ENABLE_BITCODE = NO;
|
||||||
FRAMEWORK_SEARCH_PATHS = (
|
FRAMEWORK_SEARCH_PATHS = (
|
||||||
|
@ -70,7 +70,7 @@ class Cache with Logging {
|
|||||||
String authToken = "";
|
String authToken = "";
|
||||||
Customer userLoggedIn;
|
Customer userLoggedIn;
|
||||||
String firebaseUid;
|
String firebaseUid;
|
||||||
Purchase purchased;
|
bool hasPurchased = false;
|
||||||
|
|
||||||
bool firstLoad = true;
|
bool firstLoad = true;
|
||||||
|
|
||||||
@ -81,7 +81,7 @@ class Cache with Logging {
|
|||||||
ExercisePlan _myExercisePlan;
|
ExercisePlan _myExercisePlan;
|
||||||
List<Property> _properties;
|
List<Property> _properties;
|
||||||
List<Product> _products;
|
List<Product> _products;
|
||||||
List<Purchase> _purchases;
|
List<Purchase> _purchases = List();
|
||||||
List<ProductTest> _productTests;
|
List<ProductTest> _productTests;
|
||||||
|
|
||||||
List<ExerciseDevice> _devices;
|
List<ExerciseDevice> _devices;
|
||||||
@ -436,5 +436,7 @@ class Cache with Logging {
|
|||||||
CustomerRepository customerRepository = CustomerRepository(customer: this.userLoggedIn);
|
CustomerRepository customerRepository = CustomerRepository(customer: this.userLoggedIn);
|
||||||
await customerRepository.getPurchase();
|
await customerRepository.getPurchase();
|
||||||
await customerRepository.getProductTests();
|
await customerRepository.getProductTests();
|
||||||
|
|
||||||
|
this.hasPurchased = this._purchases.isNotEmpty;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -245,6 +245,10 @@ class ExerciseRepository {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void sortByDate() {
|
void sortByDate() {
|
||||||
|
if (exerciseList.isEmpty) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
exerciseList.sort((a, b) => b.dateAdd.compareTo(a.dateAdd));
|
exerciseList.sort((a, b) => b.dateAdd.compareTo(a.dateAdd));
|
||||||
|
|
||||||
this.exerciseLogList = List();
|
this.exerciseLogList = List();
|
||||||
|
@ -209,15 +209,17 @@ class _ExerciseLogPage extends State<ExerciseLogPage> with Trans, Common {
|
|||||||
evaluation();
|
evaluation();
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
GestureDetector(
|
Cache().hasPurchased
|
||||||
child: Image.asset(
|
? Offstage()
|
||||||
'asset/image/lock.png',
|
: GestureDetector(
|
||||||
height: 25,
|
child: Image.asset(
|
||||||
width: 25,
|
'asset/image/lock.png',
|
||||||
),
|
height: 25,
|
||||||
onTap: () {
|
width: 25,
|
||||||
evaluation();
|
),
|
||||||
}),
|
onTap: () {
|
||||||
|
evaluation();
|
||||||
|
}),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
IconButton(
|
IconButton(
|
||||||
|
@ -26,24 +26,26 @@ class _MyDevelopmentBodyPage extends State<MyDevelopmentBodyPage> with Trans, Co
|
|||||||
@override
|
@override
|
||||||
void initState() {
|
void initState() {
|
||||||
super.initState();
|
super.initState();
|
||||||
Timer(
|
if (!Cache().hasPurchased) {
|
||||||
Duration(milliseconds: 2000),
|
Timer(
|
||||||
() => {
|
Duration(milliseconds: 2000),
|
||||||
showDialog(
|
() => {
|
||||||
context: context,
|
showDialog(
|
||||||
barrierDismissible: false,
|
context: context,
|
||||||
builder: (BuildContext context) {
|
barrierDismissible: false,
|
||||||
setContext(context);
|
builder: (BuildContext context) {
|
||||||
return DialogPremium(
|
setContext(context);
|
||||||
unlocked: false,
|
return DialogPremium(
|
||||||
unlockRound: 2,
|
unlocked: false,
|
||||||
function: "My Whole Body Development",
|
unlockRound: 2,
|
||||||
unlockedText: "",
|
function: "My Whole Body Development",
|
||||||
onTap: () => {Navigator.of(context).pop(), Navigator.of(context).pop()},
|
unlockedText: "",
|
||||||
onCancel: () => {Navigator.of(context).pop(), Navigator.of(context).pop()},
|
onTap: () => {Navigator.of(context).pop(), Navigator.of(context).pop()},
|
||||||
);
|
onCancel: () => {Navigator.of(context).pop(), Navigator.of(context).pop()},
|
||||||
})
|
);
|
||||||
});
|
})
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
/// We require the initializers to run after the loading screen is rendered
|
/// We require the initializers to run after the loading screen is rendered
|
||||||
SchedulerBinding.instance.addPostFrameCallback((_) {
|
SchedulerBinding.instance.addPostFrameCallback((_) {
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
import 'dart:async';
|
import 'dart:async';
|
||||||
import 'dart:collection';
|
import 'dart:collection';
|
||||||
|
import 'package:aitrainer_app/model/cache.dart';
|
||||||
import 'package:aitrainer_app/util/trans.dart';
|
import 'package:aitrainer_app/util/trans.dart';
|
||||||
import 'package:aitrainer_app/widgets/app_bar.dart';
|
import 'package:aitrainer_app/widgets/app_bar.dart';
|
||||||
import 'package:aitrainer_app/widgets/dialog_premium.dart';
|
import 'package:aitrainer_app/widgets/dialog_premium.dart';
|
||||||
@ -30,23 +31,25 @@ class _MyDevelopmentMuscleState extends State<MyDevelopmentMusclePage> with Comm
|
|||||||
@override
|
@override
|
||||||
void initState() {
|
void initState() {
|
||||||
super.initState();
|
super.initState();
|
||||||
Timer(
|
if (!Cache().hasPurchased) {
|
||||||
Duration(milliseconds: 2000),
|
Timer(
|
||||||
() => {
|
Duration(milliseconds: 2000),
|
||||||
showDialog(
|
() => {
|
||||||
context: context,
|
showDialog(
|
||||||
barrierDismissible: false,
|
context: context,
|
||||||
builder: (BuildContext context) {
|
barrierDismissible: false,
|
||||||
return DialogPremium(
|
builder: (BuildContext context) {
|
||||||
unlocked: false,
|
return DialogPremium(
|
||||||
unlockRound: 1,
|
unlocked: false,
|
||||||
function: "Development Of Muscles",
|
unlockRound: 1,
|
||||||
unlockedText: "",
|
function: "Development Of Muscles",
|
||||||
onTap: () => {Navigator.of(context).pop(), Navigator.of(context).pop()},
|
unlockedText: "",
|
||||||
onCancel: () => {Navigator.of(context).pop(), Navigator.of(context).pop()},
|
onTap: () => {Navigator.of(context).pop(), Navigator.of(context).pop()},
|
||||||
);
|
onCancel: () => {Navigator.of(context).pop(), Navigator.of(context).pop()},
|
||||||
})
|
);
|
||||||
});
|
})
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
/// We require the initializers to run after the loading screen is rendered
|
/// We require the initializers to run after the loading screen is rendered
|
||||||
SchedulerBinding.instance.addPostFrameCallback((_) {
|
SchedulerBinding.instance.addPostFrameCallback((_) {
|
||||||
@ -166,6 +169,7 @@ class _MyDevelopmentMuscleState extends State<MyDevelopmentMusclePage> with Comm
|
|||||||
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
||||||
children: [
|
children: [
|
||||||
ChoiceChip(
|
ChoiceChip(
|
||||||
|
labelPadding: EdgeInsets.only(right: 5),
|
||||||
avatar: Icon(Icons.timer),
|
avatar: Icon(Icons.timer),
|
||||||
label: Text(t('Detailed')),
|
label: Text(t('Detailed')),
|
||||||
labelStyle: TextStyle(fontSize: 9, color: Colors.black),
|
labelStyle: TextStyle(fontSize: 9, color: Colors.black),
|
||||||
@ -175,6 +179,7 @@ class _MyDevelopmentMuscleState extends State<MyDevelopmentMusclePage> with Comm
|
|||||||
onSelected: (value) => {bloc.add(DevelopmentByMuscleDateRateChange(dateRate: DateRate.daily))},
|
onSelected: (value) => {bloc.add(DevelopmentByMuscleDateRateChange(dateRate: DateRate.daily))},
|
||||||
),
|
),
|
||||||
ChoiceChip(
|
ChoiceChip(
|
||||||
|
labelPadding: EdgeInsets.only(right: 5),
|
||||||
avatar: Icon(Icons.timer),
|
avatar: Icon(Icons.timer),
|
||||||
label: Text(t('Weekly')),
|
label: Text(t('Weekly')),
|
||||||
labelStyle: TextStyle(fontSize: 9, color: Colors.black),
|
labelStyle: TextStyle(fontSize: 9, color: Colors.black),
|
||||||
@ -185,6 +190,7 @@ class _MyDevelopmentMuscleState extends State<MyDevelopmentMusclePage> with Comm
|
|||||||
onSelected: (value) => {bloc.add(DevelopmentByMuscleDateRateChange(dateRate: DateRate.weekly))},
|
onSelected: (value) => {bloc.add(DevelopmentByMuscleDateRateChange(dateRate: DateRate.weekly))},
|
||||||
),
|
),
|
||||||
ChoiceChip(
|
ChoiceChip(
|
||||||
|
labelPadding: EdgeInsets.only(right: 5),
|
||||||
avatar: Icon(Icons.timer),
|
avatar: Icon(Icons.timer),
|
||||||
label: Text(t('Monthly')),
|
label: Text(t('Monthly')),
|
||||||
labelStyle: TextStyle(fontSize: 9, color: Colors.black),
|
labelStyle: TextStyle(fontSize: 9, color: Colors.black),
|
||||||
@ -194,6 +200,7 @@ class _MyDevelopmentMuscleState extends State<MyDevelopmentMusclePage> with Comm
|
|||||||
onSelected: (value) => {bloc.add(DevelopmentByMuscleDateRateChange(dateRate: DateRate.monthly))},
|
onSelected: (value) => {bloc.add(DevelopmentByMuscleDateRateChange(dateRate: DateRate.monthly))},
|
||||||
),
|
),
|
||||||
ChoiceChip(
|
ChoiceChip(
|
||||||
|
labelPadding: EdgeInsets.only(right: 5),
|
||||||
avatar: Icon(Icons.timer),
|
avatar: Icon(Icons.timer),
|
||||||
label: Text(t('Yearly')),
|
label: Text(t('Yearly')),
|
||||||
labelStyle: TextStyle(fontSize: 9, color: Colors.black),
|
labelStyle: TextStyle(fontSize: 9, color: Colors.black),
|
||||||
|
@ -48,7 +48,7 @@ class _MyDevelopmentPage extends State<MyDevelopmentPage> with Trans {
|
|||||||
style: GoogleFonts.robotoMono(
|
style: GoogleFonts.robotoMono(
|
||||||
textStyle: TextStyle(
|
textStyle: TextStyle(
|
||||||
fontSize: 14,
|
fontSize: 14,
|
||||||
color: Colors.orange,
|
color: Colors.white,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
backgroundColor: Colors.black54.withOpacity(0.4))),
|
backgroundColor: Colors.black54.withOpacity(0.4))),
|
||||||
image: "asset/image/edzesnaplom400400.jpg",
|
image: "asset/image/edzesnaplom400400.jpg",
|
||||||
@ -62,10 +62,7 @@ class _MyDevelopmentPage extends State<MyDevelopmentPage> with Trans {
|
|||||||
text: t("My Whole Body Development"),
|
text: t("My Whole Body Development"),
|
||||||
style: GoogleFonts.robotoMono(
|
style: GoogleFonts.robotoMono(
|
||||||
textStyle: TextStyle(
|
textStyle: TextStyle(
|
||||||
fontSize: 14,
|
fontSize: 14, color: Colors.white, fontWeight: FontWeight.bold, backgroundColor: Colors.black54.withOpacity(0.4)),
|
||||||
color: Colors.orange,
|
|
||||||
fontWeight: FontWeight.bold,
|
|
||||||
backgroundColor: Colors.black54.withOpacity(0.4)),
|
|
||||||
),
|
),
|
||||||
image: "asset/image/testemfejl400x400.jpg",
|
image: "asset/image/testemfejl400x400.jpg",
|
||||||
left: 5,
|
left: 5,
|
||||||
@ -82,7 +79,7 @@ class _MyDevelopmentPage extends State<MyDevelopmentPage> with Trans {
|
|||||||
style: GoogleFonts.robotoMono(
|
style: GoogleFonts.robotoMono(
|
||||||
textStyle: TextStyle(
|
textStyle: TextStyle(
|
||||||
fontSize: 14,
|
fontSize: 14,
|
||||||
color: Colors.orange,
|
color: Colors.white,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
backgroundColor: Colors.black54.withOpacity(0.4))),
|
backgroundColor: Colors.black54.withOpacity(0.4))),
|
||||||
image: "asset/image/izomcsop400400.jpg",
|
image: "asset/image/izomcsop400400.jpg",
|
||||||
@ -98,7 +95,7 @@ class _MyDevelopmentPage extends State<MyDevelopmentPage> with Trans {
|
|||||||
style: GoogleFonts.robotoMono(
|
style: GoogleFonts.robotoMono(
|
||||||
textStyle: TextStyle(
|
textStyle: TextStyle(
|
||||||
fontSize: 14,
|
fontSize: 14,
|
||||||
color: Colors.orange,
|
color: Colors.white,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
backgroundColor: Colors.black54.withOpacity(0.4))),
|
backgroundColor: Colors.black54.withOpacity(0.4))),
|
||||||
image: "asset/image/predictions.jpg",
|
image: "asset/image/predictions.jpg",
|
||||||
|
@ -47,7 +47,7 @@ class _MyExercisePlanPage extends State<MyExercisePlanPage> with Trans, Logging
|
|||||||
style: GoogleFonts.robotoMono(
|
style: GoogleFonts.robotoMono(
|
||||||
textStyle: TextStyle(
|
textStyle: TextStyle(
|
||||||
fontSize: 14,
|
fontSize: 14,
|
||||||
color: Colors.orange,
|
color: Colors.white,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
backgroundColor: Colors.black54.withOpacity(0.4))),
|
backgroundColor: Colors.black54.withOpacity(0.4))),
|
||||||
image: "asset/image/exercise_plan_execute.jpg",
|
image: "asset/image/exercise_plan_execute.jpg",
|
||||||
@ -66,7 +66,7 @@ class _MyExercisePlanPage extends State<MyExercisePlanPage> with Trans, Logging
|
|||||||
style: GoogleFonts.robotoMono(
|
style: GoogleFonts.robotoMono(
|
||||||
textStyle: TextStyle(
|
textStyle: TextStyle(
|
||||||
fontSize: 14,
|
fontSize: 14,
|
||||||
color: Colors.orange,
|
color: Colors.white,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
backgroundColor: Colors.black54.withOpacity(0.4))),
|
backgroundColor: Colors.black54.withOpacity(0.4))),
|
||||||
image: "asset/image/exercise_plan_custom.jpg",
|
image: "asset/image/exercise_plan_custom.jpg",
|
||||||
@ -85,11 +85,11 @@ class _MyExercisePlanPage extends State<MyExercisePlanPage> with Trans, Logging
|
|||||||
style: GoogleFonts.robotoMono(
|
style: GoogleFonts.robotoMono(
|
||||||
textStyle: TextStyle(
|
textStyle: TextStyle(
|
||||||
fontSize: 14,
|
fontSize: 14,
|
||||||
color: Colors.orange,
|
color: Colors.white,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
backgroundColor: Colors.black54.withOpacity(0.4))),
|
backgroundColor: Colors.black54.withOpacity(0.4))),
|
||||||
image: "asset/image/exercise_plan_suggested.jpg",
|
image: "asset/image/exercise_plan_suggested.jpg",
|
||||||
left: 5,
|
left: 2,
|
||||||
onTap: () => {
|
onTap: () => {
|
||||||
showDialog(
|
showDialog(
|
||||||
context: context,
|
context: context,
|
||||||
@ -113,7 +113,7 @@ class _MyExercisePlanPage extends State<MyExercisePlanPage> with Trans, Logging
|
|||||||
style: GoogleFonts.robotoMono(
|
style: GoogleFonts.robotoMono(
|
||||||
textStyle: TextStyle(
|
textStyle: TextStyle(
|
||||||
fontSize: 14,
|
fontSize: 14,
|
||||||
color: Colors.orange,
|
color: Colors.white,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
backgroundColor: Colors.black54.withOpacity(0.4))),
|
backgroundColor: Colors.black54.withOpacity(0.4))),
|
||||||
image: "asset/image/exercise_plan_special.jpg",
|
image: "asset/image/exercise_plan_special.jpg",
|
||||||
@ -141,7 +141,7 @@ class _MyExercisePlanPage extends State<MyExercisePlanPage> with Trans, Logging
|
|||||||
style: GoogleFonts.robotoMono(
|
style: GoogleFonts.robotoMono(
|
||||||
textStyle: TextStyle(
|
textStyle: TextStyle(
|
||||||
fontSize: 14,
|
fontSize: 14,
|
||||||
color: Colors.orange,
|
color: Colors.white,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
backgroundColor: Colors.black54.withOpacity(0.4))),
|
backgroundColor: Colors.black54.withOpacity(0.4))),
|
||||||
image: "asset/image/exercise_plan_stars.jpg",
|
image: "asset/image/exercise_plan_stars.jpg",
|
||||||
|
@ -7,12 +7,14 @@ class DialogCommon extends StatefulWidget {
|
|||||||
final String title, descriptions, text;
|
final String title, descriptions, text;
|
||||||
final VoidCallback onTap;
|
final VoidCallback onTap;
|
||||||
final VoidCallback onCancel;
|
final VoidCallback onCancel;
|
||||||
String description2;
|
String description2, description3;
|
||||||
final Image img;
|
final Image img;
|
||||||
|
|
||||||
DialogCommon({Key key, this.title, this.descriptions, this.description2, this.text, this.img, this.onTap, this.onCancel})
|
DialogCommon(
|
||||||
|
{Key key, this.title, this.descriptions, this.description2, this.description3, this.text, this.img, this.onTap, this.onCancel})
|
||||||
: super(key: key) {
|
: super(key: key) {
|
||||||
description2 = description2 ?? "";
|
description2 = description2 ?? "";
|
||||||
|
description3 = description3 ?? "";
|
||||||
}
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
@ -129,7 +131,30 @@ class _DialogPremiumState extends State<DialogCommon> with Trans {
|
|||||||
textAlign: TextAlign.center,
|
textAlign: TextAlign.center,
|
||||||
),
|
),
|
||||||
SizedBox(
|
SizedBox(
|
||||||
height: 62,
|
height: 15,
|
||||||
|
),
|
||||||
|
Text(
|
||||||
|
widget.description3,
|
||||||
|
style: GoogleFonts.inter(
|
||||||
|
fontSize: 14,
|
||||||
|
color: Colors.white,
|
||||||
|
shadows: <Shadow>[
|
||||||
|
Shadow(
|
||||||
|
offset: Offset(5.0, 5.0),
|
||||||
|
blurRadius: 12.0,
|
||||||
|
color: Colors.black54,
|
||||||
|
),
|
||||||
|
Shadow(
|
||||||
|
offset: Offset(-3.0, 3.0),
|
||||||
|
blurRadius: 12.0,
|
||||||
|
color: Colors.black54,
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
textAlign: TextAlign.center,
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 52,
|
||||||
),
|
),
|
||||||
Align(
|
Align(
|
||||||
alignment: Alignment.center,
|
alignment: Alignment.center,
|
||||||
|
@ -50,7 +50,7 @@ class ImageButton extends StatelessWidget {
|
|||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
if (top == null) {
|
if (top == null) {
|
||||||
top = height - (style.fontSize - 5) * text.length - 2 * left < 0 ? height - 2 * style.fontSize - 22 : height - style.fontSize - 17;
|
top = height - (style.fontSize - 5) * text.length - 2 * left < 0 ? height - 2 * style.fontSize - 22 : height - style.fontSize - 37;
|
||||||
//print("Top: " + top.toStringAsFixed(0) + " length: " + ((style.fontSize - 5) * text.length).toString());
|
//print("Top: " + top.toStringAsFixed(0) + " length: " + ((style.fontSize - 5) * text.length).toString());
|
||||||
}
|
}
|
||||||
return Stack(
|
return Stack(
|
||||||
@ -99,31 +99,33 @@ class ImageButton extends StatelessWidget {
|
|||||||
color: Colors.transparent,
|
color: Colors.transparent,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Stack(alignment: Alignment.topLeft, children: [
|
Cache().hasPurchased
|
||||||
Positioned(
|
? Offstage()
|
||||||
top: height / 2 - 30,
|
: Stack(alignment: Alignment.topLeft, children: [
|
||||||
left: width / 2 - 30,
|
Positioned(
|
||||||
child: this.isLocked
|
top: height / 2 - 30,
|
||||||
? GestureDetector(
|
left: width / 2 - 30,
|
||||||
child: Image.asset(
|
child: this.isLocked
|
||||||
'asset/image/lock.png',
|
? GestureDetector(
|
||||||
height: 60,
|
child: Image.asset(
|
||||||
width: 60,
|
'asset/image/lock.png',
|
||||||
),
|
height: 60,
|
||||||
onTap: onTap ?? onTap,
|
width: 60,
|
||||||
)
|
),
|
||||||
: isMarked
|
onTap: onTap ?? onTap,
|
||||||
? GestureDetector(
|
)
|
||||||
child: Image.asset(
|
: isMarked
|
||||||
'asset/image/haken.png',
|
? GestureDetector(
|
||||||
height: 70,
|
child: Image.asset(
|
||||||
width: 70,
|
'asset/image/haken.png',
|
||||||
),
|
height: 70,
|
||||||
onTap: onTap ?? onTap,
|
width: 70,
|
||||||
)
|
),
|
||||||
: Container(),
|
onTap: onTap ?? onTap,
|
||||||
)
|
)
|
||||||
]),
|
: Container(),
|
||||||
|
)
|
||||||
|
]),
|
||||||
]
|
]
|
||||||
//)
|
//)
|
||||||
// )
|
// )
|
||||||
|
@ -221,8 +221,9 @@ class _MenuPageWidgetState extends State<MenuPageWidget> with Trans, Logging {
|
|||||||
builder: (BuildContext context) {
|
builder: (BuildContext context) {
|
||||||
return DialogCommon(
|
return DialogCommon(
|
||||||
title: menuBloc.infoTitle,
|
title: menuBloc.infoTitle,
|
||||||
descriptions: menuBloc.infoText2,
|
descriptions: menuBloc.infoText,
|
||||||
description2: menuBloc.infoText3,
|
description2: menuBloc.infoText2,
|
||||||
|
description3: menuBloc.infoText3,
|
||||||
text: "OK",
|
text: "OK",
|
||||||
onTap: () => {Navigator.of(context).pop()},
|
onTap: () => {Navigator.of(context).pop()},
|
||||||
onCancel: () => {Navigator.of(context).pop()},
|
onCancel: () => {Navigator.of(context).pop()},
|
||||||
|
Loading…
Reference in New Issue
Block a user