|
|
|
@ -274,7 +274,12 @@ class _LoginPageState extends State<LoginByName3> {
|
|
|
|
g_userInfo.username = value;
|
|
|
|
g_userInfo.username = value;
|
|
|
|
},
|
|
|
|
},
|
|
|
|
endBtn: 'ClearBtn',
|
|
|
|
endBtn: 'ClearBtn',
|
|
|
|
controller: TextEditingController(text: g_userInfo.username),
|
|
|
|
// controller: TextEditingController(text: g_userInfo.username),
|
|
|
|
|
|
|
|
controller: TextEditingController.fromValue(TextEditingValue(
|
|
|
|
|
|
|
|
text: g_userInfo.username,
|
|
|
|
|
|
|
|
// 保持光标在最后,https://blog.csdn.net/weixin_38025168/article/details/103185466
|
|
|
|
|
|
|
|
selection: TextSelection.fromPosition(TextPosition(
|
|
|
|
|
|
|
|
affinity: TextAffinity.downstream, offset: g_userInfo.username.length)))),
|
|
|
|
onEndBtn: () {
|
|
|
|
onEndBtn: () {
|
|
|
|
if (g_users.isNotEmpty) {
|
|
|
|
if (g_users.isNotEmpty) {
|
|
|
|
//如果个数大于1个或者唯一一个账号跟当前账号不一样才弹出历史账号
|
|
|
|
//如果个数大于1个或者唯一一个账号跟当前账号不一样才弹出历史账号
|
|
|
|
@ -318,7 +323,13 @@ class _LoginPageState extends State<LoginByName3> {
|
|
|
|
g_userInfo.password = value;
|
|
|
|
g_userInfo.password = value;
|
|
|
|
},
|
|
|
|
},
|
|
|
|
endBtn: 'ShowHiddenBtn',
|
|
|
|
endBtn: 'ShowHiddenBtn',
|
|
|
|
controller: TextEditingController(text: g_userInfo.password),
|
|
|
|
// controller: TextEditingController(text: g_userInfo.password),
|
|
|
|
|
|
|
|
controller: TextEditingController.fromValue(TextEditingValue(
|
|
|
|
|
|
|
|
text: g_userInfo.password,
|
|
|
|
|
|
|
|
// 保持光标在最后,https://blog.csdn.net/weixin_38025168/article/details/103185466
|
|
|
|
|
|
|
|
selection: TextSelection.fromPosition(TextPosition(
|
|
|
|
|
|
|
|
affinity: TextAffinity.downstream,
|
|
|
|
|
|
|
|
offset: g_userInfo.password.length)))),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
|