mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2025-02-02 11:16:26 +00:00
Set the curson position at the end of the value in the textfield.
This commit is contained in:
parent
2b7d798253
commit
f2ec887b3a
2 changed files with 11 additions and 2 deletions
|
@ -122,9 +122,13 @@ class _WalletNameFormState extends State<WalletNameForm> {
|
|||
setState(() {
|
||||
_controller.text = rName;
|
||||
_walletNewVM.name = rName;
|
||||
_controller.selection = TextSelection.fromPosition(
|
||||
TextPosition(offset: _controller.text.length));
|
||||
});
|
||||
},
|
||||
icon: Icon(Icons.refresh),
|
||||
icon: Image.asset(
|
||||
'assets/images/refresh_icon.png',
|
||||
),
|
||||
),
|
||||
hintStyle: TextStyle(
|
||||
fontSize: 18.0,
|
||||
|
|
|
@ -68,9 +68,14 @@ class WalletRestoreFromSeedFormState extends State<WalletRestoreFromSeedForm> {
|
|||
print(rName);
|
||||
setState(() {
|
||||
nameTextEditingController.text = rName;
|
||||
nameTextEditingController.selection =
|
||||
TextSelection.fromPosition(TextPosition(
|
||||
offset: nameTextEditingController.text.length));
|
||||
});
|
||||
},
|
||||
icon: Icon(Icons.refresh),
|
||||
icon: Image.asset(
|
||||
'assets/images/refresh_icon.png',
|
||||
),
|
||||
),
|
||||
),
|
||||
Container(height: 20),
|
||||
|
|
Loading…
Reference in a new issue