List of usage examples for java.awt.event KeyEvent VK_F7
int VK_F7
To view the source code for java.awt.event KeyEvent VK_F7.
Click Source Link
From source file:vista.ventas.DialogEntregas.java
private void eventosDeTeclas() { KeyboardFocusManager manager = KeyboardFocusManager.getCurrentKeyboardFocusManager(); manager.addKeyEventDispatcher(new KeyEventDispatcher() { public boolean dispatchKeyEvent(KeyEvent e) { if (KeyboardFocusManager.getCurrentKeyboardFocusManager().getActiveWindow().getClass() .getSimpleName().equals("DialogEntregas")) { if (e.getID() == KeyEvent.KEY_PRESSED) { if (e.getKeyCode() == KeyEvent.VK_F3) { agregarArticulo(); calcularSubtotalGral(); }//w ww . java 2 s .co m if (e.getKeyCode() == KeyEvent.VK_F7) { realizarVenta(); } if (e.getKeyCode() == KeyEvent.VK_F4) { cerrar(); } } } return false; } }); }