| | |
| | | if ((sender as Button).IsSelected) |
| | | { |
| | | //判断是否选择了服务器,选择了才能发送验证码 |
| | | if (CheckIfSelectServer() == false) return; |
| | | //if (CheckIfSelectServer() == false) return; |
| | | |
| | | string account = etAccount.Text.Trim(); |
| | | int time = 60; |
| | |
| | | if (btnRegister.IsSelected) |
| | | { |
| | | //判断是否选择了服务器,选择了才能发送验证码 |
| | | if (CheckIfSelectServer() == false) return; |
| | | //if (CheckIfSelectServer() == false) return; |
| | | //检测账号 |
| | | if (!CheckAccount()) return; |
| | | //检测密码 |
| | |
| | | |
| | | }; |
| | | |
| | | btnServerGo.MouseUpEventHandler = eventHandler; |
| | | btnServerText.MouseUpEventHandler = eventHandler; |
| | | //btnServerGo.MouseUpEventHandler = eventHandler; |
| | | //btnServerText.MouseUpEventHandler = eventHandler; |
| | | } |
| | | |
| | | /// <summary> |
| | |
| | | /// <param name="isError"></param> |
| | | void ShowServerBottomLineState(bool isError) |
| | | { |
| | | if (isError) |
| | | { |
| | | HDLCommon.Current.BottomLineShowType(btnServerBottomLine, BottomLineType.Error); |
| | | } |
| | | else |
| | | { |
| | | HDLCommon.Current.BottomLineShowType(btnServerBottomLine, BottomLineType.Normal); |
| | | } |
| | | //if (isError) |
| | | //{ |
| | | // HDLCommon.Current.BottomLineShowType(btnServerBottomLine, BottomLineType.Error); |
| | | //} |
| | | //else |
| | | //{ |
| | | // HDLCommon.Current.BottomLineShowType(btnServerBottomLine, BottomLineType.Normal); |
| | | //} |
| | | } |
| | | |
| | | /// <summary> |
| | |
| | | //服务器选择过标记为true |
| | | isSelectServer = true; |
| | | ShowServerBottomLineState(false); |
| | | btnServerText.TextColor = CSS_Color.FirstLevelTitleColor; |
| | | btnServerText.Text = OnAppConfig.Instance.GlobalRegion.regionName; |
| | | //btnServerText.TextColor = CSS_Color.FirstLevelTitleColor; |
| | | //btnServerText.Text = OnAppConfig.Instance.GlobalRegion.regionName; |
| | | } |
| | | |
| | | |
| | |
| | | bool CheckPassword() |
| | | { |
| | | //校验密码是否符合要求 |
| | | if (etPassword.Text.Trim().Length < 6 || etPassword.Text.Trim().Length > 13) |
| | | if (etPassword.Text.Trim().Length < 6 || etPassword.Text.Trim().Length > 20) |
| | | { |
| | | Utlis.ShowTip(Language.StringByID(StringId.PasswordIsUnqualified)); |
| | | return false; |