001// License: GPL. For details, see LICENSE file. 002package org.openstreetmap.josm.gui.util; 003 004import java.awt.event.KeyEvent; 005 006/** 007 * Interface that is used to detect key pressing and releasing. 008 * @since 7219 009 */ 010public interface KeyPressReleaseListener { 011 /** 012 * This is called when key press event is actually pressed 013 * (no fake events while holding key) 014 * @param e key event 015 */ 016 void doKeyPressed(KeyEvent e); 017 018 /** 019 * This is called when key press event is actually released 020 * (no fake events while holding key) 021 * @param e key event 022 */ 023 void doKeyReleased(KeyEvent e); 024}