| 
    Open Inventor Reference
    
   | 
 
Mouse button press and release events. More...
#include <Inventor/events/SoMouseButtonEvent.h>
  
Public Types | |
| enum | Button {  ANY = 0 , BUTTON1 = 1 , BUTTON2 = 2 , BUTTON3 = 3 , LEFT_BUTTON = BUTTON1 , MIDDLE_BUTTON = BUTTON2 , RIGHT_BUTTON = BUTTON3 }  | 
  Public Types inherited from SoButtonEvent | |
| enum | State { UP , DOWN , UNKNOWN } | 
  Public Types inherited from SoEvent | |
| enum | MouseButtonsMask {  NO_MOUSEBUTTON_MASK = 0 , LEFT_MOUSEBUTTON_MASK = 1 , MIDDLE_MOUSEBUTTON_MASK = 2 , RIGHT_MOUSEBUTTON_MASK = 4 , ALL_MOUSEBUTTONS_MASK = LEFT_MOUSEBUTTON_MASK + MIDDLE_MOUSEBUTTON_MASK + RIGHT_MOUSEBUTTON_MASK }  | 
| This describes the bit mask values of setButtonMask and getButtonMask.  More... | |
Public Member Functions | |
| SoMouseButtonEvent () | |
| Constructor.   | |
| virtual | ~SoMouseButtonEvent () | 
| void | setButton (SoMouseButtonEvent::Button b) | 
| set/get which button generated the event, either SO_MOUSE_BUTTON1, SO_MOUSE_BUTTON2, or SO_MOUSE_BUTTON3   | |
| SoMouseButtonEvent::Button | getButton () const | 
| void | setIsDoubleClick (bool b) | 
| set if the button press is a double click; MEVIS Inventor only   | |
| bool | isDoubleClick () const | 
| get if the button press is a double click; MEVIS Inventor only   | |
  Public Member Functions inherited from SoButtonEvent | |
| SoButtonEvent () | |
| Constructor.   | |
| virtual | ~SoButtonEvent () | 
| void | setState (SoButtonEvent::State s) | 
| get state of the button   | |
| SoButtonEvent::State | getState () const | 
  Public Member Functions inherited from SoEvent | |
| SoEvent () | |
| Constructor and destructor.   | |
| virtual | ~SoEvent () | 
| Constructor and destructor.   | |
| virtual SoType | getTypeId () const | 
| Return the type id for this event instance.   | |
| bool | isOfType (SoType type) const | 
| This returns TRUE if the event is an instance of or derived from an event of the passed type.   | |
| void | setTime (SbTime t) | 
| Set the time at which the event occurred.   | |
| SbTime | getTime () const | 
| Get the time at which the event occurred.   | |
| void | setPosition (const SbVec2s &p) | 
| Set the window pixel location of the cursor when the event occurred.   | |
| const SbVec2s & | getPosition () const | 
| Get position in pixel coodinates.   | |
| const SbVec2s & | getPosition (const SbViewportRegion &vpRgn) const | 
| Get position relative to the specified viewport bounds.   | |
| const SbVec2f & | getNormalizedPosition (const SbViewportRegion &vpRgn) const | 
| Get the normalized location of the cursor when the event occurred, relative to the specified viewport region.   | |
| void | setShiftDown (bool isDown) | 
| Set whether the modifier keys were down when the event occurred.   | |
| void | setCtrlDown (bool isDown) | 
| Set whether the modifier keys were down when the event occurred.   | |
| void | setAltDown (bool isDown) | 
| Set whether the modifier keys were down when the event occurred.   | |
| bool | wasShiftDown () const | 
| Get whether the modifier keys were down when the event occurred.   | |
| bool | wasCtrlDown () const | 
| Get whether the modifier keys were down when the event occurred.   | |
| bool | wasAltDown () const | 
| Get whether the modifier keys were down when the event occurred.   | |
| void | setMouseButtonMask (int mask) | 
| Get which mouse buttons are currently pressed (as bit mask)   | |
| int | getMouseButtonMask () const | 
| Set which mouse buttons are currently pressed.   | |
Static Public Member Functions | |
| static bool | isButtonPressEvent (const SoEvent *e, SoMouseButtonEvent::Button whichButton) | 
| convenience routines to see if an SoEvent is a press or release of the passed mouse button   | |
| static bool | isButtonReleaseEvent (const SoEvent *e, SoMouseButtonEvent::Button whichButton) | 
| static void | initClass () | 
  Static Public Member Functions inherited from SoButtonEvent | |
| static void | initClass () | 
  Static Public Member Functions inherited from SoEvent | |
| static SoType | getClassTypeId () | 
| Return the type id for the SoEvent class.   | |
| static void | initClass () | 
| Initializes base event class.   | |
| static void | initClasses () | 
| Initialize ALL Inventor event classes.   | |
SoMouseButtonEvent represents mouse button press and release events in the Inventor event model.
Definition at line 87 of file SoMouseButtonEvent.h.
| Enumerator | |
|---|---|
| ANY | |
| BUTTON1 | |
| BUTTON2 | |
| BUTTON3 | |
| LEFT_BUTTON | |
| MIDDLE_BUTTON | |
| RIGHT_BUTTON | |
Definition at line 92 of file SoMouseButtonEvent.h.
| SoMouseButtonEvent::SoMouseButtonEvent | ( | ) | 
      
  | 
  virtual | 
      
  | 
  inline | 
Definition at line 112 of file SoMouseButtonEvent.h.
      
  | 
  static | 
      
  | 
  static | 
      
  | 
  static | 
      
  | 
  inline | 
Definition at line 118 of file SoMouseButtonEvent.h.
      
  | 
  inline | 
Definition at line 111 of file SoMouseButtonEvent.h.
      
  | 
  inline | 
Definition at line 115 of file SoMouseButtonEvent.h.