Exemplo n.º 1
0
        protected override void OnFormClosing(FormClosingEventArgs e)
        {
            // Really close application if either control key is held
            if (Keyboard.IsKeyDown(Keys.LControlKey) || Keyboard.IsKeyDown(Keys.RControlKey))
            {
                base.OnFormClosing(e);
            }
            // Don't actually close the form - app is still on system tray
            else
            {
                e.Cancel = true;

                Hide();
                viewButtons     = ShowView(viewButtons, false);
                viewQueue       = ShowView(viewQueue, false);
                viewControllers = ShowView(viewControllers, false);

                base.OnFormClosing(e);
            }
        }
Exemplo n.º 2
0
 private void MenuItemViewGameControllers_Click(object sender, EventArgs e)
 {
     viewControllers = ShowView(viewControllers, true);
 }