All pastes #370930 Raw Edit

Anonymous

public text v1 · immutable
#370930 ·published 2007-02-25 00:16 UTC
rendered paste body
		pane = new JFrame().getContentPane();
                
                /**
		 * Define some key bindings, for altering the orientation of this player!
		 */
		InputMap paneInputM = pane.getInputMap();
		ActionMap paneActionM = pane.getActionMap();
		paneInputM.put(KeyStroke.getKeyStroke(KeyEvent.VK_B, Event.CTRL_MASK), "SetLeft");
		paneActionM.put("SetLeft", new AbstractAction()
		{
			private static final long serialVersionUID = 1L;

			public void actionPerformed(ActionEvent arg0) 
			{
				System.out.println("Action!");
				// Alter orientation here
			}
			
		});