public class ModeSupport extends Object implements org.eclipse.swt.events.KeyListener, org.eclipse.swt.events.MouseListener, org.eclipse.swt.events.MouseMoveListener, org.eclipse.swt.events.FocusListener
Constructor and Description |
---|
ModeSupport(NatTable natTable) |
Modifier and Type | Method and Description |
---|---|
void |
focusGained(org.eclipse.swt.events.FocusEvent event) |
void |
focusLost(org.eclipse.swt.events.FocusEvent event) |
void |
keyPressed(org.eclipse.swt.events.KeyEvent event) |
void |
keyReleased(org.eclipse.swt.events.KeyEvent event) |
void |
mouseDoubleClick(org.eclipse.swt.events.MouseEvent event) |
void |
mouseDown(org.eclipse.swt.events.MouseEvent event) |
void |
mouseMove(org.eclipse.swt.events.MouseEvent event) |
void |
mouseUp(org.eclipse.swt.events.MouseEvent event) |
void |
registerModeEventHandler(String mode,
IModeEventHandler modeEventHandler)
Register an event handler to handle events for a given mode.
|
void |
switchMode(IModeEventHandler modeEventHandler) |
void |
switchMode(String mode)
Switch to the given mode.
|
public ModeSupport(NatTable natTable)
public void registerModeEventHandler(String mode, IModeEventHandler modeEventHandler)
mode
- The mode.modeEventHandler
- An IModeEventHandler instance that will handle events in the
given mode.IModeEventHandler
public void switchMode(String mode)
mode
- The target mode to switch to.public void switchMode(IModeEventHandler modeEventHandler)
public void keyPressed(org.eclipse.swt.events.KeyEvent event)
keyPressed
in interface org.eclipse.swt.events.KeyListener
public void keyReleased(org.eclipse.swt.events.KeyEvent event)
keyReleased
in interface org.eclipse.swt.events.KeyListener
public void mouseDoubleClick(org.eclipse.swt.events.MouseEvent event)
mouseDoubleClick
in interface org.eclipse.swt.events.MouseListener
public void mouseDown(org.eclipse.swt.events.MouseEvent event)
mouseDown
in interface org.eclipse.swt.events.MouseListener
public void mouseUp(org.eclipse.swt.events.MouseEvent event)
mouseUp
in interface org.eclipse.swt.events.MouseListener
public void mouseMove(org.eclipse.swt.events.MouseEvent event)
mouseMove
in interface org.eclipse.swt.events.MouseMoveListener
public void focusGained(org.eclipse.swt.events.FocusEvent event)
focusGained
in interface org.eclipse.swt.events.FocusListener
public void focusLost(org.eclipse.swt.events.FocusEvent event)
focusLost
in interface org.eclipse.swt.events.FocusListener
Copyright © 2013. All Rights Reserved.