mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2025-02-02 03:06:35 +00:00
CAKE-114 | removed disclaimer alert
This commit is contained in:
parent
f6e099eb0a
commit
f42e398c80
1 changed files with 2 additions and 19 deletions
|
@ -20,9 +20,8 @@ class DisclaimerPage extends BasePage {
|
|||
String get title => 'Terms of Use';
|
||||
|
||||
@override
|
||||
Widget leading(BuildContext context) {
|
||||
return isReadOnly ? super.leading(context) : null;
|
||||
}
|
||||
Widget leading(BuildContext context) =>
|
||||
isReadOnly ? super.leading(context) : null;
|
||||
|
||||
@override
|
||||
Widget body(BuildContext context) => DisclaimerPageBody(isReadOnly: isReadOnly);
|
||||
|
@ -55,26 +54,10 @@ class DisclaimerBodyState extends State<DisclaimerPageBody> {
|
|||
setState(() {});
|
||||
}
|
||||
|
||||
Future<void> _showAlertDialog(BuildContext context) async {
|
||||
await showPopUp<void>(
|
||||
context: context,
|
||||
builder: (BuildContext context) {
|
||||
return AlertWithOneAction(
|
||||
alertTitle: 'Terms and conditions',
|
||||
alertContent: 'By using this app, you agree to the Terms of Agreement set forth to below',
|
||||
buttonText: S.of(context).ok,
|
||||
buttonAction: () => Navigator.of(context).pop()
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
void _afterLayout(Duration _) => _showAlertDialog(context);
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
getFileLines();
|
||||
if (!widget.isReadOnly) WidgetsBinding.instance.addPostFrameCallback(_afterLayout);
|
||||
}
|
||||
|
||||
@override
|
||||
|
|
Loading…
Reference in a new issue