public void KeysPressed(KeyEvent evt) { if (evt.ChangedKeys.Contains(Keys.Escape)) { this.Exit(); } if (evt.ChangedKeys.Contains(Keys.D)) { if (World.IsNight) World.IsNight = false; } if (evt.ChangedKeys.Contains(Keys.N)) { if (!World.IsNight) World.IsNight = true; } if (evt.ChangedKeys.Contains(Keys.F12)) { this.graphics.ToggleFullScreen(); } }
public void KeysReleased(KeyEvent evt) { /* Ignore */ }
private static void FireKeyReleased(KeyEvent evt) { foreach (KeyListener kl in keyListeners) { kl.KeysReleased(evt); } }