@Test public void testOnKeyUp() { tested.onKeyUpEvent(new KeyUpEvent(KeyboardEvent.Key.ALT)); verify(shortcutCallback, times(1)).onKeyUp(eq(KeyboardEvent.Key.ALT)); }
private void onKeyUp(final KeyboardEvent.Key key) { if (!enabled) { return; } keys.remove(key); shortcutCallbacks.stream().forEach(s -> s.onKeyUp(key)); }
KeyEventHandlerImpl implements KeyEventHandler { private void onKeyUp(final KeyboardEvent.Key key) { if (!enabled) { return; } keys.remove(key); shortcutCallbacks.stream().forEach(s -> s.onKeyUp(key)); } }
KeyEventHandlerImpl implements KeyEventHandler { private void onKeyUp(final KeyboardEvent.Key key) { if (!enabled) { return; } keys.remove(key); shortcutCallbacks.stream().forEach(s -> s.onKeyUp(key)); }  }
KeyEventHandlerImpl implements KeyEventHandler { private void onKeyUp(final KeyboardEvent.Key key) { if (!enabled) { return; } keys.remove(key); shortcutCallbacks.stream().forEach(s -> s.onKeyUp(key)); }  @Override KeyEventHandler addKeyShortcutCallback(final KeyboardControl.KeyShortcutCallback shortcutCallback); @Override KeyEventHandler setTimerDelay(final int millis); @Override @PreDestroy void clear(); @Override void setEnabled(final boolean enabled); void onKeyUpEvent(final @Observes KeyUpEvent event); }
KeyEventHandlerImpl implements KeyEventHandler { private void onKeyUp(final KeyboardEvent.Key key) { if (!enabled) { return; } keys.remove(key); shortcutCallbacks.stream().forEach(s -> s.onKeyUp(key)); }  @Override KeyEventHandler addKeyShortcutCallback(final KeyboardControl.KeyShortcutCallback shortcutCallback); @Override KeyEventHandler setTimerDelay(final int millis); @Override @PreDestroy void clear(); @Override void setEnabled(final boolean enabled); void onKeyUpEvent(final @Observes KeyUpEvent event);  }