mirror of
https://github.com/Such-Software/hash-wallet.git
synced 2026-10-17 05:41:29 +02:00
keep sign/verify pages loaded (#1703)
This commit is contained in:
@@ -20,7 +20,7 @@ class SignForm extends StatefulWidget {
|
||||
SignFormState createState() => SignFormState();
|
||||
}
|
||||
|
||||
class SignFormState extends State<SignForm> {
|
||||
class SignFormState extends State<SignForm> with AutomaticKeepAliveClientMixin {
|
||||
SignFormState()
|
||||
: formKey = GlobalKey<FormState>(),
|
||||
messageController = TextEditingController(),
|
||||
@@ -42,8 +42,12 @@ class SignFormState extends State<SignForm> {
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
@override
|
||||
bool get wantKeepAlive => true;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
super.build(context);
|
||||
return Container(
|
||||
padding: EdgeInsets.only(left: 24, right: 24),
|
||||
child: Column(
|
||||
|
||||
@@ -15,7 +15,7 @@ class VerifyForm extends StatefulWidget {
|
||||
VerifyFormState createState() => VerifyFormState();
|
||||
}
|
||||
|
||||
class VerifyFormState extends State<VerifyForm> {
|
||||
class VerifyFormState extends State<VerifyForm> with AutomaticKeepAliveClientMixin {
|
||||
VerifyFormState()
|
||||
: formKey = GlobalKey<FormState>(),
|
||||
messageController = TextEditingController(),
|
||||
@@ -36,9 +36,13 @@ class VerifyFormState extends State<VerifyForm> {
|
||||
void dispose() {
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
@override
|
||||
bool get wantKeepAlive => true;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
super.build(context);
|
||||
return Container(
|
||||
padding: EdgeInsets.only(left: 24, right: 24),
|
||||
child: Form(
|
||||
|
||||
Reference in New Issue
Block a user