keyboard.java
Posted in Text, on August 30, 2010 at 13:42
import java.awt.event.KeyEvent;
import java.awt.event.KeyListener;

public class Keyboard implements KeyListener
{
    public boolean escape = false;
    
    public void keyTyped(KeyEvent e)
    {
        
    }

    public void keyPressed(KeyEvent e)
    {
        if(e.getKeyCode()==KeyEvent.VK_ESCAPE)
            escape=true;
    }

    public void keyReleased(KeyEvent e)
    {
        
    }
}

Share this code

| More

Use the link below to share the code:
HTML
BBCode