Пример #1
0
        /** When closed we open up the search engine app.
         */
        private void Form4_FormClosed(object sender, FormClosedEventArgs e)
        {
            PrivacyForm privacy = new PrivacyForm
            {
                StartPosition = FormStartPosition.CenterScreen
            };

            privacy.Show();
            GraphsAPIHandler.LoadCategories();
            Program.LoadWhitelist();
        }
Пример #2
0
        //Whichever item on the menu toolbar is clicked it does the appropriate action
        private void menu_strip_ItemClicked(object sender, ToolStripItemClickedEventArgs e)
        {
            switch (e.ClickedItem.Name)
            {
            case "history":
            {
                if (historyResults.Count == 0)
                {
                    MessageBox.Show("No history");
                    return;
                }
                HistoryForm historyForm = new HistoryForm();
                historyForm.loadResults(historyResults);
                historyForm.Show();
                break;
            }

            case "whitelist":
            {
                WhitelistForm whitelist = new WhitelistForm();
                whitelist.Show();
                break;
            }

            case "privacy":
            {
                PrivacyForm privacy = new PrivacyForm();
                privacy.Show();
                break;
            }

            case "dashboard":
            {
                Program.OpenUrl("https://consultationplus.herokuapp.com");
                break;
            }

            case "about":
            {
                Program.OpenUrl("https://reflect.ucl.ac.uk/uclcomp00162020team33/");
                break;
            }

            case "help":
            {
                break;
            }
            }
        }