MyGUI  3.0.1
Public Member Functions | Static Public Member Functions | Data Fields
MyGUI::InputManager Class Reference

#include <MyGUI_InputManager.h>

+ Inheritance diagram for MyGUI::InputManager:

Public Member Functions

 InputManager ()
 ~InputManager ()
void initialise ()
void shutdown ()
bool injectMouseMove (int _absx, int _absy, int _absz)
bool injectMousePress (int _absx, int _absy, MouseButton _id)
bool injectMouseRelease (int _absx, int _absy, MouseButton _id)
bool injectKeyPress (KeyCode _key, Char _text=0)
bool injectKeyRelease (KeyCode _key)
bool isFocusMouse ()
bool isFocusKey ()
bool isCaptureMouse ()
void setKeyFocusWidget (Widget *_widget)
void resetKeyFocusWidget (Widget *_widget)
void resetKeyFocusWidget ()
WidgetgetMouseFocusWidget ()
WidgetgetKeyFocusWidget ()
const IntPointgetLastLeftPressed ()
const IntPointgetMousePosition ()
IntPoint getMousePositionByLayer ()
void resetMouseFocusWidget ()
void addWidgetModal (Widget *_widget)
void removeWidgetModal (Widget *_widget)
bool isModalAny ()
bool isControlPressed ()
bool isShiftPressed ()
void resetMouseCaptureWidget ()
void unlinkWidget (Widget *_widget)

Static Public Member Functions

static InputManagergetInstance ()
static InputManagergetInstancePtr ()

Data Fields

delegates::CMultiDelegate1
< Widget * > 
eventChangeMouseFocus
delegates::CMultiDelegate1
< Widget * > 
eventChangeKeyFocus

Detailed Description

Definition at line 41 of file MyGUI_InputManager.h.


Constructor & Destructor Documentation


Member Function Documentation

Add modal widget - all other widgets inaccessible while modal widget exist

Definition at line 496 of file MyGUI_InputManager.cpp.

Get key focused widget

Definition at line 88 of file MyGUI_InputManager.h.

Get position of last left mouse button press

Definition at line 90 of file MyGUI_InputManager.h.

Get mouse focused widget

Definition at line 86 of file MyGUI_InputManager.h.

Get current mouse position

Definition at line 92 of file MyGUI_InputManager.h.

Definition at line 594 of file MyGUI_InputManager.cpp.

Definition at line 38 of file MyGUI_InputManager.cpp.

bool MyGUI::InputManager::injectKeyPress ( KeyCode  _key,
Char  _text = 0 
)

Inject KeyPress event

Returns:
true if event has been processed by GUI

Definition at line 338 of file MyGUI_InputManager.cpp.

Inject KeyRelease event

Returns:
true if event has been processed by GUI

Definition at line 357 of file MyGUI_InputManager.cpp.

bool MyGUI::InputManager::injectMouseMove ( int  _absx,
int  _absy,
int  _absz 
)

Inject MouseMove event

Returns:
true if event has been processed by GUI

Definition at line 74 of file MyGUI_InputManager.cpp.

bool MyGUI::InputManager::injectMousePress ( int  _absx,
int  _absy,
MouseButton  _id 
)

Inject MousePress event

Returns:
true if event has been processed by GUI

Definition at line 219 of file MyGUI_InputManager.cpp.

bool MyGUI::InputManager::injectMouseRelease ( int  _absx,
int  _absy,
MouseButton  _id 
)

Inject MouseRelease event

Returns:
true if event has been processed by GUI

Definition at line 292 of file MyGUI_InputManager.cpp.

Is any widget captured mouse

Definition at line 76 of file MyGUI_InputManager.h.

Is control button pressed

Definition at line 110 of file MyGUI_InputManager.h.

Is any widget have key focus

Definition at line 74 of file MyGUI_InputManager.h.

Is any widget have mouse focus

Definition at line 72 of file MyGUI_InputManager.h.

Return true if any modal widget exist

Definition at line 107 of file MyGUI_InputManager.h.

Is shift button pressed

Definition at line 112 of file MyGUI_InputManager.h.

Remove modal widget

Definition at line 509 of file MyGUI_InputManager.cpp.

Drop key focus for _widget

Definition at line 588 of file MyGUI_InputManager.cpp.

Drop any key focus

Definition at line 83 of file MyGUI_InputManager.h.

Reset mouse capture (for example when we dragging and application lost focus you should call this)

Definition at line 117 of file MyGUI_InputManager.h.

Drop any mouse focus

Definition at line 444 of file MyGUI_InputManager.cpp.

Set key focus for _widget

Definition at line 380 of file MyGUI_InputManager.cpp.

Definition at line 62 of file MyGUI_InputManager.cpp.

void MyGUI::InputManager::unlinkWidget ( Widget _widget) [inline]

Definition at line 119 of file MyGUI_InputManager.h.


Field Documentation

Event :
signature : void method(MyGUI::Widget* _widget)

Parameters:
_widget

Definition at line 133 of file MyGUI_InputManager.h.

Event :
signature : void method(MyGUI::Widget* _widget)

Parameters:
_widget

Definition at line 126 of file MyGUI_InputManager.h.


The documentation for this class was generated from the following files: