| | |
| | | /// 0:手机 |
| | | /// 1:邮箱 |
| | | /// </summary> |
| | | int logintType = 0; |
| | | int loginType = 0; |
| | | /// <summary> |
| | | /// 登录方式 |
| | | /// 0:密码 |
| | | /// 1:验证码 |
| | | /// </summary> |
| | | int logintMode = 0; |
| | | string account; |
| | | string password; |
| | | string account = ""; |
| | | string password = ""; |
| | | #endregion |
| | | |
| | | #region 控件列表 |
| | |
| | | /// <summary> |
| | | /// 加载视图 |
| | | /// </summary> |
| | | public void LoadView() |
| | | public void LoadView(string account = "") |
| | | { |
| | | var btnIcon = new Button() |
| | | { |
| | |
| | | }; |
| | | bodyView.AddChidren(btnIcon); |
| | | |
| | | var btnIcon_bg = new Button() { |
| | | var btnIcon_bg = new Button() |
| | | { |
| | | X = Application.GetRealWidth(171), |
| | | Y = Application.GetRealHeight(69), |
| | | Width = Application.GetMinRealAverage(254), |
| | |
| | | btnIcon.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | #if DEBUG |
| | | UserConfig.Instance.SkinCode = UserConfig.Instance.SkinCode > 1 ? 0 : 1; |
| | | SharedMethod.SharedMethod.ChangeSkin(); |
| | | MainPage.Log($"UserConfig.skincode{UserConfig.Instance.SkinCode}"); |
| | | etAccount.Text = "464027401@qq.com"; |
| | | etPassword.Text = "qqqqqq"; |
| | | btnLogin.IsSelected = true; |
| | | #endif |
| | | }; |
| | | |
| | |
| | | Y = Application.GetRealHeight(177), |
| | | Width = Application.GetRealWidth(120), |
| | | Height = Application.GetRealHeight(40), |
| | | TextID = R.InternationalizationString.LoginByPhone, |
| | | TextID = StringId.LoginByPhone, |
| | | TextColor = CSS_Color.MainColor, |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | TextSize = CSS_FontSize.EmphasisFontSize_Secondary, |
| | |
| | | Y = Application.GetRealHeight(177), |
| | | Width = Application.GetRealWidth(100), |
| | | Height = Application.GetRealHeight(40), |
| | | TextID = R.InternationalizationString.LoginByEmail, |
| | | TextID = StringId.LoginByEmail, |
| | | TextColor = CSS_Color.PromptingColor1, |
| | | TextAlignment = TextAlignment.Center, |
| | | TextSize = CSS_FontSize.TextFontSize, |
| | |
| | | Text = "+86", |
| | | TextSize = CSS_FontSize.TextFontSize, |
| | | }; |
| | | if (logintType == 0) |
| | | if (loginType == 0) |
| | | accountView.AddChidren(btnGlobalRoaming); |
| | | |
| | | btnDividingLineVertical_AccountView = new Button() |
| | |
| | | { |
| | | X = Application.GetRealWidth(78), |
| | | Width = Application.GetRealWidth(319 - 78), |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | TextSize = CSS_FontSize.TextFontSize, |
| | | PlaceholderTextColor = CSS_Color.PromptingColor1, |
| | | PlaceholderText = Language.StringByID(R.InternationalizationString.PlsEntryAccount), |
| | | PlaceholderText = Language.StringByID(StringId.PlsEntryPhoneNumber), |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | }; |
| | | accountView.AddChidren(etAccount); |
| | | |
| | | if (account != "") |
| | | { |
| | | etAccount.Text = account; |
| | | } |
| | | |
| | | btnAccountViewBottomLine = new Button() |
| | | { |
| | |
| | | Height = Application.GetMinRealAverage(20), |
| | | UnSelectedImagePath = "LoginIcon/AccountIcon.png", |
| | | }; |
| | | if (logintType == 1) |
| | | if (loginType == 1) |
| | | { |
| | | accountView.AddChidren(btnAccountIcon); |
| | | } |
| | |
| | | { |
| | | X = Application.GetRealWidth(78), |
| | | Width = Application.GetRealWidth(61 + 84), |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | TextSize = CSS_FontSize.TextFontSize, |
| | | PlaceholderTextColor = CSS_Color.PromptingColor1, |
| | | PlaceholderText = Language.StringByID(R.InternationalizationString.PlsEntryPassword), |
| | | PlaceholderText = Language.StringByID(StringId.PlsEntryPassword), |
| | | SecureTextEntry = true, |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | }; |
| | | passwordView.AddChidren(etPassword); |
| | | |
| | |
| | | Width = Application.GetRealWidth(56), |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | TextID = R.InternationalizationString.ForgetPassword, |
| | | TextID = StringId.ForgetPassword, |
| | | TextSize = 12, |
| | | }; |
| | | passwordView.AddChidren(btnForgetPassword); |
| | |
| | | { |
| | | X = Application.GetRealWidth(219), |
| | | Width = Application.GetRealWidth(100), |
| | | TextID = R.InternationalizationString.GetVerificationCode, |
| | | TextColor = CSS_Color.MainColor, |
| | | TextID = StringId.GetVerificationCode, |
| | | SelectedTextColor = CSS_Color.MainColor, |
| | | TextAlignment = TextAlignment.CenterRight, |
| | | TextSize = CSS_FontSize.PromptFontSize_FirstLevel, |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | }; |
| | | #endregion |
| | | |
| | |
| | | Height = Application.GetRealHeight(17 + 12 + 12), |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | TextSize = CSS_FontSize.PromptFontSize_FirstLevel, |
| | | TextID = R.InternationalizationString.SingUp, |
| | | TextID = StringId.SingUp, |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | }; |
| | | bodyView.AddChidren(btnRegister); |
| | |
| | | Height = Application.GetRealHeight(51), |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | TextSize = CSS_FontSize.PromptFontSize_FirstLevel, |
| | | TextID = R.InternationalizationString.VerificationCodeLogin, |
| | | TextID = StringId.VerificationCodeLogin, |
| | | TextAlignment = TextAlignment.CenterRight, |
| | | }; |
| | | bodyView.AddChidren(btnSwitchLoginMode); |
| | |
| | | Radius = (uint)Application.GetRealHeight(22), |
| | | SelectedBackgroundColor = CSS_Color.MainColor, |
| | | BackgroundColor = CSS_Color.PromptingColor1, |
| | | TextID = R.InternationalizationString.Login, |
| | | TextID = StringId.Login, |
| | | TextSize = CSS_FontSize.SubheadingFontSize, |
| | | TextColor = CSS_Color.MainBackgroundColor, |
| | | TextAlignment = TextAlignment.Center, |
| | |
| | | |
| | | |
| | | LoadEventList(); |
| | | account = etAccount.Text.Trim(); |
| | | } |
| | | } |
| | | } |