migrate: material 3

This commit is contained in:
lollipopkit
2023-05-07 01:28:51 +08:00
parent e932241df0
commit 5afa543ba5
29 changed files with 438 additions and 480 deletions

View File

@@ -53,10 +53,9 @@ Future<void> doUpdate(BuildContext context, {bool force = false}) async {
if (update.build.min.current! > BuildData.build) {
showRoundDialog(
context,
s.attention,
Text(s.updateTipTooLow(newest)),
[
context: context,
child: Text(s.updateTipTooLow(newest)),
actions: [
TextButton(
onPressed: () => _doUpdate(url, context, s),
child: Text(s.ok),
@@ -84,11 +83,15 @@ Future<void> _doUpdate(String url, BuildContext context, S s) async {
} else if (isIOS) {
await RUpgrade.upgradeFromAppStore('1586449703');
} else {
showRoundDialog(context, s.attention, Text(s.platformNotSupportUpdate), [
TextButton(
onPressed: () => context.pop(),
child: Text(s.ok),
)
]);
showRoundDialog(
context: context,
child: Text(s.platformNotSupportUpdate),
actions: [
TextButton(
onPressed: () => context.pop(),
child: Text(s.ok),
)
],
);
}
}