예제 #1
0
 private void tradLogin_CheckedChanged(object sender, RoutedEventArgs e)
 {
     if (App.MainWnd == null || App.MainWnd.accountList == null || App.MainWnd.accountList.panel_GetOtp == null || App.MainWnd.accountList.autoPaste == null)
     {
         return;
     }
     if ((bool)tradLogin.IsChecked)
     {
         App.MainWnd.accountList.panel_GetOtp.Visibility = Visibility.Visible;
         if (App.MainWnd.win_class_name != null && App.MainWnd.win_class_name != "" && App.MainWnd.game_exe != "" && App.MainWnd.login_action_type != 1)
         {
             App.MainWnd.accountList.autoPaste.Visibility = Visibility.Visible;
         }
         else
         {
             App.MainWnd.accountList.autoPaste.Visibility = Visibility.Collapsed;
         }
     }
     else
     {
         App.MainWnd.accountList.panel_GetOtp.Visibility = Visibility.Collapsed;
     }
     if (App.MainWnd.settingPage == null || bool.Parse(ConfigAppSettings.GetValue("tradLogin", "true")) == tradLogin.IsChecked)
     {
         return;
     }
     ConfigAppSettings.SetValue("tradLogin", Convert.ToString(tradLogin.IsChecked));
 }
예제 #2
0
 private void ask_update_CheckedChanged(object sender, RoutedEventArgs e)
 {
     if (App.MainWnd == null || App.MainWnd.settingPage == null || ask_update.IsChecked == bool.Parse(ConfigAppSettings.GetValue("ask_update", "true")))
     {
         return;
     }
     ConfigAppSettings.SetValue("ask_update", Convert.ToString((bool)ask_update.IsChecked));
 }
예제 #3
0
 private void cb_UpdateChannel_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if (App.MainWnd == null || App.MainWnd.settingPage == null || cb_UpdateChannel.SelectedIndex == (ConfigAppSettings.GetValue("updateChannel", "Stable").Equals("Stable") ? 0 : 1))
     {
         return;
     }
     ConfigAppSettings.SetValue("updateChannel", cb_UpdateChannel.SelectedIndex == 0 ? "Stable" : "Beta");
 }
예제 #4
0
 private void minimize_to_tray_CheckedChanged(object sender, RoutedEventArgs e)
 {
     if (App.MainWnd == null || App.MainWnd.settingPage == null || minimize_to_tray.IsChecked == bool.Parse(ConfigAppSettings.GetValue("minimize_to_tray", "false")))
     {
         return;
     }
     ConfigAppSettings.SetValue("minimize_to_tray", Convert.ToString((bool)minimize_to_tray.IsChecked));
 }
예제 #5
0
 private void autoKillPatcher_CheckedChanged(object sender, RoutedEventArgs e)
 {
     if (App.MainWnd == null || App.MainWnd.settingPage == null || autoKillPatcher.IsChecked == bool.Parse(ConfigAppSettings.GetValue("autoKillPatcher", "true")))
     {
         return;
     }
     ConfigAppSettings.SetValue("autoKillPatcher", Convert.ToString((bool)autoKillPatcher.IsChecked));
     App.MainWnd.checkPatcher.IsEnabled = (bool)autoKillPatcher.IsChecked;
 }
예제 #6
0
 private void skipPlayWnd_CheckedChanged(object sender, RoutedEventArgs e)
 {
     if (App.MainWnd == null || App.MainWnd.settingPage == null || App.MainWnd.checkPlayPage == null || skipPlayWnd.IsChecked == bool.Parse(ConfigAppSettings.GetValue("skipPlayWnd", "true")))
     {
         return;
     }
     ConfigAppSettings.SetValue("skipPlayWnd", Convert.ToString((bool)skipPlayWnd.IsChecked));
     App.MainWnd.checkPlayPage.IsEnabled = (bool)skipPlayWnd.IsChecked;
 }
예제 #7
0
 private void cb_ThemeColor_TextChanged(object sender, System.EventArgs e)
 {
     try
     {
         Color color = (Color)ColorConverter.ConvertFromString(cb_ThemeColor.Text);
         App.MainWnd.changeThemeColor(color);
         ConfigAppSettings.SetValue("ThemeColor", cb_ThemeColor.Text);
     } catch { }
 }
예제 #8
0
        private void useNewQRCode_CheckedChanged(object sender, RoutedEventArgs e)
        {
            if (App.MainWnd == null || App.MainWnd.loginPage == null || App.MainWnd.loginPage.qr == null || useNewQRCode.IsChecked == bool.Parse(ConfigAppSettings.GetValue("useNewQRCode", "true")))
            {
                return;
            }
            ConfigAppSettings.SetValue("useNewQRCode", Convert.ToString((bool)useNewQRCode.IsChecked));

            App.MainWnd.refreshQRCode();
        }
예제 #9
0
 private void autoPaste_CheckedChanged(object sender, RoutedEventArgs e)
 {
     if (bool.Parse(ConfigAppSettings.GetValue("autoPaste", "false")) == autoPaste.IsChecked)
     {
         return;
     }
     if (ConfigAppSettings.GetValue("autoPaste", "") == "")
     {
         MessageBox.Show("自動輸入需要滿足以下條件才能正常使用:\r\n1.遊戲需要在輸入帳密界面\r\n2.遊戲沒有選中記住帳號\r\n3.遊戲帳號密碼輸入欄為空\r\n4.輸入欄激活狀態為帳號欄位\r\n\r\n※ 自動輸入功能可能會由於遊戲限制出現偶爾無法正常進行的問題, 請斟酌使用");
     }
     ConfigAppSettings.SetValue("autoPaste", Convert.ToString(autoPaste.IsChecked));
 }
예제 #10
0
 private void Beanfun_HK_Click(object sender, RoutedEventArgs e)
 {
     if (!Beanfun_HK.IsEnabled)
     {
         return;
     }
     Beanfun_HK.IsEnabled = !Beanfun_HK.IsEnabled;
     Beanfun_TW.IsEnabled = !Beanfun_HK.IsEnabled;
     App.LoginRegion      = "HK";
     ConfigAppSettings.SetValue("loginRegion", App.LoginRegion);
     App.MainWnd.ddlAuthTypeItemsInit();
     App.MainWnd.reLoadGameInfo();
 }
예제 #11
0
        public LoginPage()
        {
            InitializeComponent();

            if (ConfigAppSettings.GetValue("loginRegion", "TW") == "TW")
            {
                Beanfun_TW.IsEnabled = false;
            }
            else
            {
                Beanfun_TW.IsEnabled = true;
            }
            Beanfun_HK.IsEnabled = !Beanfun_TW.IsEnabled;
        }
예제 #12
0
        public Settings()
        {
            InitializeComponent();

            autoStartGame.IsChecked    = bool.Parse(ConfigAppSettings.GetValue("autoStartGame", "false"));
            ask_update.IsChecked       = bool.Parse(ConfigAppSettings.GetValue("ask_update", "true"));
            minimize_to_tray.IsChecked = bool.Parse(ConfigAppSettings.GetValue("minimize_to_tray", "false"));

            tradLogin.IsChecked       = bool.Parse(ConfigAppSettings.GetValue("tradLogin", "true"));
            skipPlayWnd.IsChecked     = bool.Parse(ConfigAppSettings.GetValue("skipPlayWnd", "true"));
            autoKillPatcher.IsChecked = bool.Parse(ConfigAppSettings.GetValue("autoKillPatcher", "true"));

            cb_UpdateChannel.SelectedIndex = ConfigAppSettings.GetValue("updateChannel", "Stable").Equals("Stable") ? 0 : 1;

            cb_ThemeColor.Text = ConfigAppSettings.GetValue("ThemeColor", "#B6DE8E");
        }
예제 #13
0
        public qr_form()
        {
            InitializeComponent();

            useNewQRCode.IsChecked = bool.Parse(ConfigAppSettings.GetValue("useNewQRCode", "true"));
        }
예제 #14
0
        public AccountList()
        {
            InitializeComponent();

            autoPaste.IsChecked = bool.Parse(ConfigAppSettings.GetValue("autoPaste", "false"));
        }
예제 #15
0
 private void ButtonHK_Click(object sender, RoutedEventArgs e)
 {
     ConfigAppSettings.SetValue("loginRegion", "HK");
     this.Hide();
     App.MainWnd.Initialize();
 }