feat:登录协议窗样式修改

This commit is contained in:
anfe 2024-04-28 09:45:16 +08:00
parent fcac101e72
commit 86159775a8
5 changed files with 174 additions and 70 deletions

View File

@ -792,5 +792,14 @@
"全选":"Select all",
"请选择要删除的视频":"Please select the video you want to delete",
"请选择要下载的视频":"Please select the video you want to download",
"欢迎使用":"Welcome to use"
"欢迎使用":"Welcome to use",
"用户协议和隐私政策概要": "Summary of User Agreement and Privacy Policy",
"协议概要": "Protocol Summary",
"感谢您使用本应用。我们非常重视您的个人信息和隐私保护,在使用本产品之前,请认真阅读":"Thank you for using this application. We attach great importance to your personal information and privacy protection. Before using this product, please read it carefully",
"《用户协议》":"《User Agreement》",
"和":"and",
"《隐私政策》": "《Privacy Policy》",
"的全部内容。点击“同意”即表示您同意并接受全部条款。若选择不同意,将无法使用我们的产品和服务,并会退出应用。": "The entire content of. By clicking \"Agree\", you agree and accept all terms. If you choose not to agree, you will not be able to use our products and services and will exit the application.",
"不同意":"Disagree",
"同意":"agree"
}

View File

@ -791,5 +791,14 @@
"全选":"全选",
"请选择要删除的视频":"请选择要删除的视频",
"请选择要下载的视频":"请选择要下载的视频",
"欢迎使用":"欢迎使用"
"欢迎使用":"欢迎使用",
"用户协议和隐私政策概要": "用户协议和隐私政策概要",
"协议概要": "协议概要",
"感谢您使用本应用。我们非常重视您的个人信息和隐私保护,在使用本产品之前,请认真阅读":"感谢您使用本应用。我们非常重视您的个人信息和隐私保护,在使用本产品之前,请认真阅读",
"《用户协议》":"《用户协议》",
"和":"和",
"《隐私政策》": "《隐私政策》",
"的全部内容。点击“同意”即表示您同意并接受全部条款。若选择不同意,将无法使用我们的产品和服务,并会退出应用。": "的全部内容。点击“同意”即表示您同意并接受全部条款。若选择不同意,将无法使用我们的产品和服务,并会退出应用。",
"不同意":"不同意",
"同意":"同意"
}

View File

@ -794,5 +794,15 @@
"全选":"全选",
"请选择要删除的视频":"请选择要删除的视频",
"请选择要下载的视频":"请选择要下载的视频",
"欢迎使用":"欢迎使用"
"欢迎使用":"欢迎使用",
"用户协议和隐私政策概要": "用户协议和隐私政策概要",
"协议概要": "协议概要",
"感谢您使用本应用。我们非常重视您的个人信息和隐私保护,在使用本产品之前,请认真阅读":"感谢您使用本应用。我们非常重视您的个人信息和隐私保护,在使用本产品之前,请认真阅读",
"《用户协议》":"《用户协议》",
"和":"和",
"《隐私政策》": "《隐私政策》",
"的全部内容。点击“同意”即表示您同意并接受全部条款。若选择不同意,将无法使用我们的产品和服务,并会退出应用。": "的全部内容。点击“同意”即表示您同意并接受全部条款。若选择不同意,将无法使用我们的产品和服务,并会退出应用。",
"不同意":"不同意",
"同意":"同意"
}

View File

@ -6,7 +6,7 @@ class AppLog {
static bool _onlyError = false;
static showLog({required bool printLog, bool? onlyError}){
_printLog = printLog ?? false;
_printLog = printLog;
_onlyError = onlyError ?? false;
}
static log(String msg,{bool? error}){

View File

@ -6,7 +6,9 @@ import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:get/get.dart';
import 'package:star_lock/appRouters.dart';
import 'package:star_lock/app_settings/app_colors.dart';
import 'package:star_lock/common/XSConstantMacro/XSConstantMacro.dart';
import 'package:star_lock/flavors.dart';
import 'package:star_lock/tools/storage.dart';
import '../versionUndate/versionUndateTool.dart';
@ -37,7 +39,6 @@ class AppFirstEnterHandle {
}
break;
default:
break;
}
}
@ -49,75 +50,150 @@ class AppFirstEnterHandle {
builder: (context) {
return PopScope(
canPop: false,
child: CupertinoAlertDialog(
title: const Text('用户协议和隐私政策概要\n'),
content: Text.rich(
TextSpan(
text: '感谢您使用本应用。我们非常重视您的个人信息和隐私保护,在使用本产品之前,请认真阅读',
style: const TextStyle(fontSize: 16.0),
children: [
TextSpan(
text: '《用户协议》',
style: const TextStyle(
color: Colors.blue,
decoration: TextDecoration.underline),
recognizer: TapGestureRecognizer()
..onTap = () {
//
Get.toNamed(Routers.webviewShowPage, arguments: {
"url": XSConstantMacro.userAgreementURL,
"title": '用户协议'
});
},
),
const TextSpan(text: ''),
TextSpan(
text: '《隐私政策》',
style: const TextStyle(
color: Colors.blue,
decoration: TextDecoration.underline),
recognizer: TapGestureRecognizer()
..onTap = () {
//
Get.toNamed(Routers.webviewShowPage, arguments: {
"url": XSConstantMacro.privacyPolicyURL,
"title": '隐私政策'
});
},
),
const TextSpan(
text:
'的全部内容。点击“同意”即表示您同意并接受全部条款。若选择不同意,将无法使用我们的产品和服务,并会退出应用。'),
],
),
),
actions: [
CupertinoDialogAction(
child: const Text(
'不同意',
style: TextStyle(color: Colors.black),
),
onPressed: () {
_exitApp();
},
),
CupertinoDialogAction(
child: const Text(
'同意',
style: TextStyle(color: Colors.blue),
),
onPressed: () {
Storage.setString(isAgreePrivacy, isAgreePrivacy);
Navigator.of(context).pop();
getAppFirstEnter(context, isShowUpdateVersion);
},
),
],
));
child: F.sw(
defaultCall: () => _defaultPrivacyAgreementAlert(context),
xhjCall: () => _xhjPrivacyAgreementAlert(context)));
},
);
}
//
Widget _defaultPrivacyAgreementAlert(BuildContext context) {
return CupertinoAlertDialog(
title: Text('${'用户协议和隐私政策概要'.tr}\n'),
content: Text.rich(
TextSpan(
text: '感谢您使用本应用。我们非常重视您的个人信息和隐私保护,在使用本产品之前,请认真阅读'.tr,
style: const TextStyle(fontSize: 16.0),
children: [
TextSpan(
text: '《用户协议》'.tr,
style: const TextStyle(
color: Colors.blue, decoration: TextDecoration.underline),
recognizer: TapGestureRecognizer()
..onTap = () {
//
Get.toNamed(Routers.webviewShowPage, arguments: {
"url": XSConstantMacro.userAgreementURL,
"title": '用户协议'.tr
});
},
),
TextSpan(text: ''.tr),
TextSpan(
text: '《隐私政策》'.tr,
style: const TextStyle(
color: Colors.blue, decoration: TextDecoration.underline),
recognizer: TapGestureRecognizer()
..onTap = () {
//
Get.toNamed(Routers.webviewShowPage, arguments: {
"url": XSConstantMacro.privacyPolicyURL,
"title": '隐私政策'.tr
});
},
),
TextSpan(
text: '的全部内容。点击“同意”即表示您同意并接受全部条款。若选择不同意,将无法使用我们的产品和服务,并会退出应用。'
.tr),
],
),
),
actions: [
CupertinoDialogAction(
child: Text(
'不同意'.tr,
style: TextStyle(color: Colors.black),
),
onPressed: () {
_exitApp();
},
),
CupertinoDialogAction(
child: Text(
'同意'.tr,
style: TextStyle(color: Colors.blue),
),
onPressed: () {
Storage.setString(isAgreePrivacy, isAgreePrivacy);
Navigator.of(context).pop();
getAppFirstEnter(context, isShowUpdateVersion);
},
),
],
);
}
//xhj
Widget _xhjPrivacyAgreementAlert(BuildContext context) {
return AlertDialog(
title: Text('协议概要'.tr),
backgroundColor: Colors.white,
content: Text.rich(
TextSpan(
text: '感谢您使用本应用。我们非常重视您的个人信息和隐私保护,在使用本产品之前,请认真阅读'.tr,
style: const TextStyle(fontSize: 16.0),
children: [
TextSpan(
text: '《用户协议》'.tr,
style: TextStyle(
color: AppColors.mainColor,
),
recognizer: TapGestureRecognizer()
..onTap = () {
//
Get.toNamed(Routers.webviewShowPage, arguments: {
"url": XSConstantMacro.userAgreementURL,
"title": '用户协议'.tr
});
},
),
TextSpan(text: ''.tr),
TextSpan(
text: '《隐私政策》'.tr,
style: TextStyle(
color: AppColors.mainColor,
),
recognizer: TapGestureRecognizer()
..onTap = () {
//
Get.toNamed(Routers.webviewShowPage, arguments: {
"url": XSConstantMacro.privacyPolicyURL,
"title": '隐私政策'.tr
});
},
),
TextSpan(
text: '的全部内容。点击“同意”即表示您同意并接受全部条款。若选择不同意,将无法使用我们的产品和服务,并会退出应用。'
.tr),
],
),
),
actions: [
CupertinoDialogAction(
child: Text(
'不同意'.tr,
style: TextStyle(color: Colors.black),
),
onPressed: () {
_exitApp();
},
),
CupertinoDialogAction(
child: Text(
'同意'.tr,
style: TextStyle(color: AppColors.mainColor),
),
onPressed: () {
Storage.setString(isAgreePrivacy, isAgreePrivacy);
Navigator.of(context).pop();
getAppFirstEnter(context, isShowUpdateVersion);
},
),
],
);
}
//
void showPositionAlert(BuildContext widgetContext) {
showCupertinoDialog(