コード例 #1
0
        private void button2_Click(object sender, EventArgs e)
        {
            GoogleAPIHandler.developer_mode = false;
            this.Close();
            WhitelistForm whitelist = new WhitelistForm();

            whitelist.Show();
        }
コード例 #2
0
        private void button1_Click(object sender, EventArgs e)
        {
            if (button1.Text.ToString() == "Activate")
            {
                if ((textBox2.Text == "") || (textBox1.Text == ""))
                {
                    MessageBox.Show("Please enter a valid api key and engine ID.");
                    return;
                }
                GoogleAPIHandler.search_engine_id = textBox2.Text;
                GoogleAPIHandler.api_key          = textBox1.Text;
                GoogleAPIHandler.developer_mode   = true;
            }
            else
            {
                GoogleAPIHandler.developer_mode = false;
            }

            this.Close();
            WhitelistForm whitelist = new WhitelistForm();

            whitelist.Show();
        }