Ejemplo n.º 1
0
 /**
  * Event handler helper-method. Actionable F2-key check
  *
  * @param evt User Keyboard Press
  */
 private void checkF2Key(KeyEvent evt) {
   if (evt.getKeyCode() == 113) {
     System.out.println(evt.getKeyCode());
     EasyButtonMouseReleased(null);
     // HardButtonMouseReleased(null);
     // FileMenuMouseClicked(null);
   }
 }
Ejemplo n.º 2
0
 /**
  * Event handler method. Frame checks for user keyboard presses
  *
  * @param evt User Keyboard Press
  */
 private void formKeyPressed(KeyEvent evt) {
   // TODO add your handling code here:
   checkF2Key(evt);
   // checkTestCMD(evt);
   System.out.println(
       "Form detected a key press: "
           + evt.getKeyLocation()
           + ": "
           + evt.getKeyCode()
           + " - "
           + evt.getKeyChar());
 }