mirror of
https://github.com/Such-Software/hash-wallet.git
synced 2026-10-23 06:38:35 +02:00
Fixes
This commit is contained in:
@@ -65,7 +65,7 @@ class RootState extends State<Root> with WidgetsBindingObserver {
|
||||
});
|
||||
}
|
||||
|
||||
return widget.child;
|
||||
return WillPopScope(onWillPop: () async => false, child: widget.child);
|
||||
}
|
||||
|
||||
void _reset() {
|
||||
|
||||
@@ -425,8 +425,10 @@ class SendPage extends BasePage {
|
||||
EdgeInsets.only(left: 24, right: 24, bottom: 24),
|
||||
bottomSection: Observer(builder: (_) {
|
||||
return LoadingPrimaryButton(
|
||||
onPressed: () {
|
||||
if (_formKey.currentState.validate()) {}
|
||||
onPressed: () async {
|
||||
if (_formKey.currentState.validate()) {
|
||||
await sendViewModel.createTransaction();
|
||||
}
|
||||
},
|
||||
text: S.of(context).send,
|
||||
color: Theme.of(context).accentTextTheme.body2.color,
|
||||
@@ -445,6 +447,18 @@ class SendPage extends BasePage {
|
||||
return;
|
||||
}
|
||||
|
||||
_cryptoAmountController.addListener(() {
|
||||
final amount = _cryptoAmountController.text;
|
||||
|
||||
if (sendViewModel.sendAll && amount != S.current.all) {
|
||||
sendViewModel.sendAll = false;
|
||||
}
|
||||
|
||||
if (amount != sendViewModel.cryptoAmount) {
|
||||
sendViewModel.setCryptoAmount(amount);
|
||||
}
|
||||
});
|
||||
|
||||
reaction((_) => sendViewModel.sendAll, (bool all) {
|
||||
if (all) {
|
||||
_cryptoAmountController.text = S.current.all;
|
||||
|
||||
Reference in New Issue
Block a user