Esempio n. 1
0
        private void About_Form_Shown(object sender, System.EventArgs e)
        {
            Translate_Class.Translate(this);
            thTextBox_Animate = new Thread(() => AnimateTxtBox(textBox2));
            thTextBox_Animate.Start();

            thTextBox_Animate2 = new Thread(() => AnimateTxtBox(textBox3));
            thTextBox_Animate2.Start();

            thTextBox_Animate3 = new Thread(() => AnimateTxtBox(textBox4));
            thTextBox_Animate3.Start();
        }
Esempio n. 2
0
        private void Main_Form_Shown(object sender, EventArgs e)
        {
            thCheck_Clipboard = new Thread(Check_Clipboard);
            thCheck_Clipboard.SetApartmentState(ApartmentState.STA);

            Load_Languages();

            if (File.Exists(AmiiBomb_Config_File))
            {
                Config = JsonConvert.DeserializeObject <Config_Class>(File.ReadAllText(AmiiBomb_Config_File));
                if (Config.Bin_Folder_Path == null)
                {
                    AskBinFolder();
                }
                if (Config.KeyFile_Path == null)
                {
                    AskAmiiboKey();
                }
                if (Config.Locale == null)
                {
                    Config.Locale = I18n.GetLocale();
                }
            }
            else
            {
                AskBinFolder();
                AskAmiiboKey();
            }

            if (Config.Locale != null)
            {
                I18n.SetLocale(Config.Locale);
                Translate_Class.Translate(this);
            }

            if (!thCheck_Clipboard.IsAlive)
            {
                thCheck_Clipboard.Start();
            }

            if (Config.Bin_Folder_Path != null)
            {
                LoadAmiiboBinFolder();
                FileWatcher();
            }

            if (Config.KeyFile_Path != null)
            {
                LoadAmiiboKey();
            }

            Controls_Size();
        }
Esempio n. 3
0
        private void Editor_TPWolf_Form_Load(object sender, EventArgs e)
        {
            Translate_Class.Translate(this);

            AppData = Amiibo_Class.Dump_AppData(File.ReadAllBytes(Current_File_Bin));

            if (AppData[0x11] < 1 || AppData[0x11] > 40)
            {
                AppData[0x11] = 1;
            }
            if (AppData[0x12] < 1 || AppData[0x12] > 80)
            {
                AppData[0x12] = 0;
            }

            trackBar1.Value = AppData[0x11]; //Level
            trackBar2.Value = AppData[0x12]; //Heart
        }
Esempio n. 4
0
        private void Arduino_Form_Load(object sender, EventArgs e)
        {
            Translate_Class.Translate(this);

            comboBox1.DataSource    = COMPortInfo.GetCOMPortsInfo();
            comboBox1.DisplayMember = "Description";
            comboBox1.ValueMember   = "Name";

            if (comboBox1.Items.Count > 0)
            {
                comboBox1.SelectedIndex = 0;
                comboBox2.SelectedIndex = 3;
                this.Opacity            = 100;
            }
            else
            {
                MessageBox.Show(i18n.__("AmiiBombuino_No_Com_Port"), this.Text, MessageBoxButtons.OK, MessageBoxIcon.Information);
                this.Close();
            }
        }
Esempio n. 5
0
        private void Flash_Form_Load(object sender, EventArgs e)
        {
            Translate_Class.Translate(this);

            comboBox2.SelectedIndex = 1;

            comboBox1.DataSource    = COMPortInfo.GetCOMPortsInfo();
            comboBox1.DisplayMember = "Description";
            comboBox1.ValueMember   = "Name";

            if (comboBox1.Items.Count > 0)
            {
                Com_Loaded = true;
                comboBox1.SelectedIndex = 0;
                comboBox1_SelectedIndexChanged(this, EventArgs.Empty);
                this.Opacity = 100;
            }
            else
            {
                MessageBox.Show(i18n.__("NFC_No_Com_Port"), this.Text, MessageBoxButtons.OK, MessageBoxIcon.Information);
                this.Close();
            }

            if (Action_Write)
            {
                if (!Action_Restore)
                {
                    button2.Text = i18n.__("NFC_Create_Amiibo_Tag");
                }
                else
                {
                    button2.Text = i18n.__("NFC_Restore_Amiibo_Tag");
                }
            }
            if (!Action_Write || Action_Restore)
            {
                checkBox1.Visible = false;
            }
        }
Esempio n. 6
0
        private void Main_Form_Shown(object sender, EventArgs e)
        {
            thCheck_Clipboard = new Thread(Check_Clipboard);
            thCheck_Clipboard.SetApartmentState(ApartmentState.STA);

            Load_Languages();

            if (File.Exists(AmiiBomb_Config_File))
            {
                Config = JsonConvert.DeserializeObject <Config_Class>(File.ReadAllText(AmiiBomb_Config_File));
                if (Config.Bin_Folder_Path == null)
                {
                    AskBinFolder();
                }
                if (Config.KeyFile_Path == null)
                {
                    AskAmiiboKey();
                }
                if (Config.Locale == null)
                {
                    Config.Locale = I18n.GetLocale();
                }

                switch (Config.Database)
                {
                case 1:
                    amiibolifeToolStripMenuItem.Checked = false;
                    amiiboAPIToolStripMenuItem.Checked  = true;
                    break;

                default:
                    amiibolifeToolStripMenuItem.Checked = true;
                    amiiboAPIToolStripMenuItem.Checked  = false;
                    break;
                }

                activeFilesCachingToolStripMenuItem.Checked = Config.Cache;
            }
            else
            {
                AskBinFolder();
                AskAmiiboKey();
            }

            if (Config.Locale != null)
            {
                I18n.SetLocale(Config.Locale);
                Translate_Class.Translate(this);
            }

            if (!thCheck_Clipboard.IsAlive)
            {
                thCheck_Clipboard.Start();
            }

            if (Config.Bin_Folder_Path != null)
            {
                LoadAmiiboBinFolder();
                treeView1.Nodes[0].Expand();
                treeView1.SelectedNode = treeView1.Nodes[0];
                FolderWatcher();
            }

            if (Config.KeyFile_Path != null)
            {
                LoadAmiiboKey();
            }

            Controls_Size();
        }
Esempio n. 7
0
 private void About_Form_Shown(object sender, System.EventArgs e)
 {
     Translate_Class.Translate(this);
 }