Esempio n. 1
0
 private void Window_Loaded(object sender, RoutedEventArgs e)
 {
     if (ini.IniReadValue("Minecraft_updater", "AutoClose_AfterFinishd").ToLower() == "true")
     {
         AutoClose_AfterFinishd = true;
     }
     if (ini.IniReadValue("Minecraft_updater", "LogFile").ToLower() == "true")
     {
         Log.LogFile = true;
     }
     CheckUpdate();
     SpinWait.SpinUntil(() => HaveNewVersion > -1, 10000);
     if (updateMessage.HaveUpdate)
     {
         Window_UpdateSelf window_UpdateSelf = new Window_UpdateSelf(updateMessage);
         window_UpdateSelf.ShowDialog();
     }
     ThreadPool.QueueUserWorkItem(new WaitCallback(CheckPack));
 }
Esempio n. 2
0
        private void Window_Load(object sender, RoutedEventArgs e)
        {
            CheckUpdate();
            SpinWait.SpinUntil(() => HaveNewVersion > -1, 10000);
            if (updateMessage.HaveUpdate)
            {
                Window_UpdateSelf window_UpdateSelf = new Window_UpdateSelf(updateMessage);
                window_UpdateSelf.ShowDialog();
            }

            if (ini.IniReadValue("Minecraft_updater", "updatepackMaker_BaseURL") != "")
            {
                textBox.Text = ini.IniReadValue("Minecraft_updater", "updatepackMaker_BaseURL");
            }
            if (ini.IniReadValue("Minecraft_updater", "LogFile").ToLower() == "true")
            {
                Log.LogFile = true;
            }
            this.textBox.TextChanged += new System.Windows.Controls.TextChangedEventHandler(this.textbox_TextChange);
        }