MyGUI_InputManager.cpp
Go to the documentation of this file.
/*
* This source file is part of MyGUI. For the latest info, see http://mygui.info/
* Distributed under the MIT License
* (See accompanying file COPYING.MIT or copy at http://opensource.org/licenses/MIT)
*/
#include "MyGUI_Precompiled.h"
#include "MyGUI_InputManager.h"
#include "MyGUI_Widget.h"
#include "MyGUI_WidgetManager.h"
#include "MyGUI_Gui.h"
#include "MyGUI_Constants.h"
namespace MyGUI
{
// In seconds
const float INPUT_TIME_DOUBLE_CLICK = 0.25f;
const float INPUT_DELAY_FIRST_KEY = 0.4f;
const float INPUT_INTERVAL_KEY = 0.05f;
MYGUI_SINGLETON_DEFINITION(InputManager);
InputManager::InputManager() :
mTimerDoubleClick(INPUT_TIME_DOUBLE_CLICK),
mSingletonHolder(this)
{
resetMouseCaptureWidget();
}
void InputManager::initialise()
{
MYGUI_ASSERT(!mIsInitialise, getClassTypeName() << " initialised twice");
MYGUI_LOG(Info, "* Initialise: " << getClassTypeName());
mWidgetMouseFocus = nullptr;
mWidgetKeyFocus = nullptr;
mLayerMouseFocus = nullptr;
for (int i = MouseButton::Button0; i < MouseButton::MAX; ++i)
{
mMouseCapture[i] = false;
}
mIsShiftPressed = false;
mIsControlPressed = false;
mIsAltPressed = false;
mIsMetaPressed = false;
mHoldKey = KeyCode::None;
mHoldChar = 0;
mFirstPressKey = true;
mTimerKey = 0.0f;
mOldAbsZ = 0;
WidgetManager::getInstance().registerUnlinker(this);
Gui::getInstance().eventFrameStart += newDelegate(this, &InputManager::frameEntered);
MYGUI_LOG(Info, getClassTypeName() << " successfully initialized");
mIsInitialise = true;
}
void InputManager::shutdown()
{
MYGUI_ASSERT(mIsInitialise, getClassTypeName() << " is not initialised");
MYGUI_LOG(Info, "* Shutdown: " << getClassTypeName());
Gui::getInstance().eventFrameStart -= newDelegate(this, &InputManager::frameEntered);
WidgetManager::getInstance().unregisterUnlinker(this);
MYGUI_LOG(Info, getClassTypeName() << " successfully shutdown");
mIsInitialise = false;
}
bool InputManager::injectMouseMove(int _absx, int _absy, int _absz)
{
// запоминаем позицию
mMousePosition.set(_absx, _absy);
// вычисляем прирост по колеса
int relz = _absz - mOldAbsZ;
mOldAbsZ = _absz;
// проверка на скролл
if (relz != 0)
{
bool isFocus = isFocusMouse();
if (isFocusMouse())
mWidgetMouseFocus->_riseMouseWheel(relz);
return isFocus;
}
if (isCaptureMouse())
{
bool isFocus = isFocusMouse();
if (isFocus)
{
if (mLayerMouseFocus != nullptr)
{
IntPoint point = mLayerMouseFocus->getPosition(_absx, _absy);
for (int i = MouseButton::Button0; i < MouseButton::MAX; ++i)
{
if (mMouseCapture[i])
mWidgetMouseFocus->_riseMouseDrag(point.left, point.top, MouseButton::Enum(i));
}
}
}
return isFocus;
}
Widget* old_mouse_focus = mWidgetMouseFocus;
// ищем активное окно
Widget* item = LayerManager::getInstance().getWidgetFromPoint(_absx, _absy);
// ничего не изменилось
if (mWidgetMouseFocus == item)
{
bool isFocus = isFocusMouse();
if (isFocusMouse())
{
if (mLayerMouseFocus != nullptr)
{
IntPoint point = mLayerMouseFocus->getPosition(_absx, _absy);
mWidgetMouseFocus->_riseMouseMove(point.left, point.top);
}
}
return isFocus;
}
if (item)
{
// поднимаемся до рута
Widget* root = item;
while (root->getParent())
root = root->getParent();
// проверяем на модальность
if (!mVectorModalRootWidget.empty())
{
if (root != mVectorModalRootWidget.back())
{
item = nullptr;
}
}
if (item != nullptr)
{
mLayerMouseFocus = root->getLayer();
}
}
//-------------------------------------------------------------------------------------//
// новый вид рутового фокуса мыши
Widget* save_widget = nullptr;
// спускаемся по новому виджету и устанавливаем рутовый фокус
Widget* root_focus = item;
while (root_focus != nullptr)
{
if (root_focus->getRootMouseFocus())
{
save_widget = root_focus;
break;
}
root_focus->_setRootMouseFocus(true);
root_focus->_riseMouseChangeRootFocus(true);
root_focus = root_focus->getParent();
}
// спускаемся по старому виджету и сбрасываем фокус
root_focus = mWidgetMouseFocus;
while (root_focus != nullptr)
{
if (root_focus == save_widget)
break;
root_focus->_setRootMouseFocus(false);
root_focus->_riseMouseChangeRootFocus(false);
root_focus = root_focus->getParent();
}
//-------------------------------------------------------------------------------------//
// смена фокуса, проверяем на доступность виджета
if (isFocusMouse() && mWidgetMouseFocus->getInheritedEnabled())
{
mWidgetMouseFocus->_riseMouseLostFocus(item);
}
if ((item != nullptr) && (item->getInheritedEnabled()))
{
MyGUI::IntPoint point(_absx, _absy);
if (mLayerMouseFocus != nullptr)
point = mLayerMouseFocus->getPosition(_absx, _absy);
item->_riseMouseMove(point.left, point.top);
item->_riseMouseSetFocus(mWidgetMouseFocus);
}
// запоминаем текущее окно
mWidgetMouseFocus = item;
if (old_mouse_focus != mWidgetMouseFocus)
{
// Reset double click timer, double clicks should only work when clicking on the *same* item twice
mTimerDoubleClick = INPUT_TIME_DOUBLE_CLICK;
eventChangeMouseFocus(mWidgetMouseFocus);
}
return isFocusMouse();
}
bool InputManager::injectMousePress(int _absx, int _absy, MouseButton _id)
{
injectMouseMove(_absx, _absy, mOldAbsZ);
if (MouseButton::None != _id && MouseButton::MAX != _id)
{
// start capture
mMouseCapture[_id.getValue()] = true;
}
// если мы щелкнули не на гуй
if (!isFocusMouse())
{
resetKeyFocusWidget();
return false;
}
// если активный элемент заблокирован
//FIXME
if (!mWidgetMouseFocus->getInheritedEnabled())
return true;
if (MouseButton::None != _id && MouseButton::MAX != _id)
{
// remember last pressed position
if (mLayerMouseFocus != nullptr)
{
IntPoint point = mLayerMouseFocus->getPosition(_absx, _absy);
mLastPressed[_id.getValue()] = point;
}
}
// ищем вверх тот виджет который может принимать фокус
Widget* item = mWidgetMouseFocus;
while ((item != nullptr) && (!item->getNeedKeyFocus()))
item = item->getParent();
// устанавливаем перед вызовом т.к. возможно внутри ктонить поменяет фокус под себя
setKeyFocusWidget(item);
if (isFocusMouse())
{
IntPoint point(_absx, _absy);
if (mLayerMouseFocus != nullptr)
point = mLayerMouseFocus->getPosition(_absx, _absy);
mWidgetMouseFocus->_riseMouseButtonPressed(point.left, point.top, _id);
// после пресса может сброситься
if (mWidgetMouseFocus)
{
// поднимаем виджет, надо подумать что делать если поменялся фокус клавы
LayerManager::getInstance().upLayerItem(mWidgetMouseFocus);
// поднимаем пикинг Overlapped окон
Widget* pick = mWidgetMouseFocus;
do
{
// если оверлаппед, то поднимаем пикинг
if (pick->getWidgetStyle() == WidgetStyle::Overlapped)
{
if (pick->getParent())
pick->getParent()->_forcePick(pick);
}
pick = pick->getParent();
} while (pick);
}
}
return true;
}
bool InputManager::injectMouseRelease(int _absx, int _absy, MouseButton _id)
{
if (_id != MouseButton::None && _id != MouseButton::MAX)
{
if (mMouseCapture[_id.getValue()])
{
// drop capture
mMouseCapture[_id.getValue()] = false;
}
}
if (isFocusMouse())
{
// если активный элемент заблокирован
if (!mWidgetMouseFocus->getInheritedEnabled())
return true;
IntPoint point(_absx, _absy);
if (mLayerMouseFocus != nullptr)
point = mLayerMouseFocus->getPosition(_absx, _absy);
mWidgetMouseFocus->_riseMouseButtonReleased(point.left, point.top, _id);
// после вызова, виджет может быть сброшен
if (nullptr != mWidgetMouseFocus)
{
if (MouseButton::Left == _id)
{
if (mTimerDoubleClick < INPUT_TIME_DOUBLE_CLICK)
{
mWidgetMouseFocus->_riseMouseButtonClick();
// might be reset in the call above, so check again
if (nullptr != mWidgetMouseFocus)
mWidgetMouseFocus->_riseMouseButtonDoubleClick();
}
else
{
// проверяем над тем ли мы окном сейчас что и были при нажатии
Widget* item = LayerManager::getInstance().getWidgetFromPoint(_absx, _absy);
if (item == mWidgetMouseFocus)
{
mWidgetMouseFocus->_riseMouseButtonClick();
}
mTimerDoubleClick = 0;
}
}
}
// для корректного отображения
injectMouseMove(_absx, _absy, mOldAbsZ);
return true;
}
return false;
}
bool InputManager::injectKeyPress(KeyCode _key, Char _text)
{
// проверка на переключение языков
firstEncoding(_key, true);
// запоминаем клавишу
storeKey(_key, _text);
bool wasFocusKey = isFocusKey();
//Pass keystrokes to the current active text widget
if (isFocusKey())
{
mWidgetKeyFocus->_riseKeyButtonPressed(_key, _text);
}
return wasFocusKey;
}
bool InputManager::injectKeyRelease(KeyCode _key)
{
// проверка на переключение языков
firstEncoding(_key, false);
// сбрасываем клавишу
resetKey();
bool wasFocusKey = isFocusKey();
if (isFocusKey())
mWidgetKeyFocus->_riseKeyButtonReleased(_key);
return wasFocusKey;
}
void InputManager::firstEncoding(KeyCode _key, bool bIsKeyPressed)
{
if ((_key == KeyCode::LeftShift) || (_key == KeyCode::RightShift))
mIsShiftPressed = bIsKeyPressed;
if ((_key == KeyCode::LeftControl) || (_key == KeyCode::RightControl))
mIsControlPressed = bIsKeyPressed;
if ((_key == KeyCode::LeftAlt) || (_key == KeyCode::RightAlt))
mIsAltPressed = bIsKeyPressed;
if ((_key == KeyCode::LeftWindows) || (_key == KeyCode::RightWindows))
mIsMetaPressed = bIsKeyPressed;
}
void InputManager::setKeyFocusWidget(Widget* _widget)
{
if (_widget == mWidgetKeyFocus)
return;
Widget* oldKeyFocus = mWidgetKeyFocus;
mWidgetKeyFocus = nullptr;
Widget* sharedRootFocus = nullptr; // possible shared parent for both old and new widget
// recursively set root key focus
Widget* rootFocus = _widget;
while (rootFocus != nullptr)
{
if (rootFocus->getRootKeyFocus())
{
sharedRootFocus = rootFocus;
break;
}
rootFocus->_setRootKeyFocus(true);
rootFocus->_riseKeyChangeRootFocus(true);
rootFocus = rootFocus->getParent();
}
// recursively reset root key focus
rootFocus = oldKeyFocus;
while (rootFocus != nullptr)
{
if (rootFocus == sharedRootFocus)
break;
rootFocus->_setRootKeyFocus(false);
rootFocus->_riseKeyChangeRootFocus(false);
rootFocus = rootFocus->getParent();
}
//-------------------------------------------------------------------------------------//
mWidgetKeyFocus = _widget;
if (oldKeyFocus)
{
oldKeyFocus->_riseKeyLostFocus(_widget);
}
if (_widget)
{
_widget->_riseKeySetFocus(mWidgetKeyFocus);
}
eventChangeKeyFocus(mWidgetKeyFocus);
}
void InputManager::_resetMouseFocusWidget()
{
Widget* mouseFocus = mWidgetMouseFocus;
mWidgetMouseFocus = nullptr;
// recursively reset old widget focus
Widget* root_focus = mouseFocus;
while (root_focus != nullptr)
{
root_focus->_setRootMouseFocus(false);
root_focus->_riseMouseChangeRootFocus(false);
root_focus = root_focus->getParent();
}
for (int i = MouseButton::Button0; i < MouseButton::MAX; ++i)
{
if (mMouseCapture[i])
{
mMouseCapture[i] = false;
if (nullptr != mouseFocus)
{
mouseFocus->_riseMouseButtonReleased(
mLastPressed[i].left,
mLastPressed[i].top,
MouseButton::Enum(i));
}
}
}
if (nullptr != mouseFocus)
{
mouseFocus->_riseMouseLostFocus(nullptr);
}
if (mouseFocus != mWidgetMouseFocus)
eventChangeMouseFocus(mWidgetMouseFocus);
}
// удаляем данный виджет из всех возможных мест
void InputManager::_unlinkWidget(Widget* _widget)
{
if (nullptr == _widget)
return;
if (mWidgetMouseFocus == _widget)
_resetMouseFocusWidget();
if (_widget == mWidgetKeyFocus)
resetKeyFocusWidget();
// ручками сбрасываем, чтобы не менять фокусы
for (VectorWidgetPtr::iterator iter = mVectorModalRootWidget.begin(); iter != mVectorModalRootWidget.end();
++iter)
{
if (*iter == _widget)
{
mVectorModalRootWidget.erase(iter);
break;
}
}
}
void InputManager::addWidgetModal(Widget* _widget)
{
if (nullptr == _widget)
return;
MYGUI_ASSERT(nullptr == _widget->getParent(), "Modal widget must be root");
_resetMouseFocusWidget();
removeWidgetModal(_widget);
mVectorModalRootWidget.push_back(_widget);
setKeyFocusWidget(_widget);
LayerManager::getInstance().upLayerItem(_widget);
}
void InputManager::removeWidgetModal(Widget* _widget)
{
resetKeyFocusWidget(_widget);
_resetMouseFocusWidget();
for (VectorWidgetPtr::iterator iter = mVectorModalRootWidget.begin(); iter != mVectorModalRootWidget.end();
++iter)
{
if (*iter == _widget)
{
mVectorModalRootWidget.erase(iter);
break;
}
}
// если еще есть модальные то их фокусируем и поднимаем
if (!mVectorModalRootWidget.empty())
{
setKeyFocusWidget(mVectorModalRootWidget.back());
LayerManager::getInstance().upLayerItem(mVectorModalRootWidget.back());
}
}
void InputManager::storeKey(KeyCode _key, Char _text)
{
mHoldKey = KeyCode::None;
mHoldChar = 0;
if (!isFocusKey())
return;
if ((_key == KeyCode::LeftShift) || (_key == KeyCode::RightShift) || (_key == KeyCode::LeftControl) ||
(_key == KeyCode::RightControl) || (_key == KeyCode::LeftAlt) || (_key == KeyCode::RightAlt))
return;
mFirstPressKey = true;
mHoldKey = _key;
mHoldChar = _text;
mTimerKey = 0.0f;
}
void InputManager::resetKey()
{
mHoldKey = KeyCode::None;
mHoldChar = 0;
}
void InputManager::frameEntered(float _frame)
{
mTimerDoubleClick += _frame;
if (mHoldKey == KeyCode::None)
return;
if (!isFocusKey())
{
mHoldKey = KeyCode::None;
mHoldChar = 0;
return;
}
mTimerKey += _frame;
if (mFirstPressKey)
{
if (mTimerKey > INPUT_DELAY_FIRST_KEY)
{
mFirstPressKey = false;
mTimerKey = 0.0f;
}
}
else
{
if (mTimerKey > INPUT_INTERVAL_KEY)
{
while (mTimerKey > INPUT_INTERVAL_KEY)
mTimerKey -= INPUT_INTERVAL_KEY;
mWidgetKeyFocus->_riseKeyButtonPressed(mHoldKey, mHoldChar);
// focus can be dropped in onKeyButtonPressed
if (isFocusKey())
mWidgetKeyFocus->_riseKeyButtonReleased(mHoldKey);
}
}
}
void InputManager::resetKeyFocusWidget(Widget* _widget)
{
if (mWidgetKeyFocus == _widget)
setKeyFocusWidget(nullptr);
}
IntPoint InputManager::getMousePositionByLayer() const
{
if (mLayerMouseFocus != nullptr)
return mLayerMouseFocus->getPosition(mMousePosition.left, mMousePosition.top);
return mMousePosition;
}
bool InputManager::isFocusMouse() const
{
return mWidgetMouseFocus != nullptr;
}
bool InputManager::isFocusKey() const
{
return mWidgetKeyFocus != nullptr;
}
bool InputManager::isCaptureMouse() const
{
for (int i = MouseButton::Button0; i < MouseButton::MAX; ++i)
{
if (mMouseCapture[i])
return true;
}
return false;
}
void InputManager::resetKeyFocusWidget()
{
setKeyFocusWidget(nullptr);
}
Widget* InputManager::getMouseFocusWidget() const
{
return mWidgetMouseFocus;
}
Widget* InputManager::getKeyFocusWidget() const
{
return mWidgetKeyFocus;
}
const IntPoint& InputManager::getLastPressedPosition(MouseButton _id) const
{
if (_id != MouseButton::None && _id != MouseButton::MAX)
{
return mLastPressed[_id.getValue()];
}
return Constants::getZeroIntPoint();
}
const IntPoint& InputManager::getMousePosition() const
{
return mMousePosition;
}
bool InputManager::isModalAny() const
{
return !mVectorModalRootWidget.empty();
}
bool InputManager::isControlPressed() const
{
return mIsControlPressed;
}
bool InputManager::isShiftPressed() const
{
return mIsShiftPressed;
}
bool InputManager::isAltPressed() const
{
return mIsAltPressed;
}
bool InputManager::isMetaPressed() const
{
return mIsMetaPressed;
}
void InputManager::resetMouseCaptureWidget()
{
for (int i = MouseButton::Button0; i < MouseButton::MAX; ++i)
{
mMouseCapture[i] = false;
}
}
void InputManager::unlinkWidget(Widget* _widget)
{
_unlinkWidget(_widget);
}
} // namespace MyGUI
MyGUI_Constants.h
MYGUI_ASSERT
#define MYGUI_ASSERT(exp, dest)
Definition MyGUI_Diagnostic.h:31
MYGUI_LOG
#define MYGUI_LOG(level, text)
Definition MyGUI_Diagnostic.h:17
MyGUI_Gui.h
MyGUI_InputManager.h
MyGUI_Precompiled.h
MYGUI_SINGLETON_DEFINITION
#define MYGUI_SINGLETON_DEFINITION(ClassName)
Definition MyGUI_Singleton.h:126
MyGUI_Widget.h
MyGUI_WidgetManager.h
MyGUI::Constants::getZeroIntPoint
static const IntPoint & getZeroIntPoint()
Definition MyGUI_Constants.h:32
MyGUI::Gui::getInstance
static Gui & getInstance()
Definition MyGUI_Gui.cpp:34
MyGUI::Gui::eventFrameStart
EventHandle_FrameEventDelegate eventFrameStart
Definition MyGUI_Gui.h:215
MyGUI::InputManager
Definition MyGUI_InputManager.h:27
MyGUI::InputManager::isAltPressed
bool isAltPressed() const
Definition MyGUI_InputManager.cpp:677
MyGUI::InputManager::getLastPressedPosition
const IntPoint & getLastPressedPosition(MouseButton _id) const
Definition MyGUI_InputManager.cpp:648
MyGUI::InputManager::unlinkWidget
void unlinkWidget(Widget *_widget)
Definition MyGUI_InputManager.cpp:695
MyGUI::InputManager::isShiftPressed
bool isShiftPressed() const
Definition MyGUI_InputManager.cpp:672
MyGUI::InputManager::injectMousePress
bool injectMousePress(int _absx, int _absy, MouseButton _id)
Definition MyGUI_InputManager.cpp:212
MyGUI::InputManager::injectMouseMove
bool injectMouseMove(int _absx, int _absy, int _absz)
Definition MyGUI_InputManager.cpp:73
MyGUI::InputManager::isFocusMouse
bool isFocusMouse() const
Definition MyGUI_InputManager.cpp:613
MyGUI::InputManager::getMousePosition
const IntPoint & getMousePosition() const
Definition MyGUI_InputManager.cpp:657
MyGUI::InputManager::getKeyFocusWidget
Widget * getKeyFocusWidget() const
Definition MyGUI_InputManager.cpp:643
MyGUI::InputManager::initialise
void initialise()
Definition MyGUI_InputManager.cpp:31
MyGUI::InputManager::setKeyFocusWidget
void setKeyFocusWidget(Widget *_widget)
Definition MyGUI_InputManager.cpp:388
MyGUI::InputManager::shutdown
void shutdown()
Definition MyGUI_InputManager.cpp:61
MyGUI::InputManager::isMetaPressed
bool isMetaPressed() const
Definition MyGUI_InputManager.cpp:682
MyGUI::InputManager::isControlPressed
bool isControlPressed() const
Definition MyGUI_InputManager.cpp:667
MyGUI::InputManager::resetKeyFocusWidget
void resetKeyFocusWidget()
Definition MyGUI_InputManager.cpp:633
MyGUI::InputManager::eventChangeMouseFocus
delegates::MultiDelegate< Widget * > eventChangeMouseFocus
Definition MyGUI_InputManager.h:121
MyGUI::InputManager::isCaptureMouse
bool isCaptureMouse() const
Definition MyGUI_InputManager.cpp:623
MyGUI::InputManager::_resetMouseFocusWidget
void _resetMouseFocusWidget()
Definition MyGUI_InputManager.cpp:441
MyGUI::InputManager::getMouseFocusWidget
Widget * getMouseFocusWidget() const
Definition MyGUI_InputManager.cpp:638
MyGUI::InputManager::resetMouseCaptureWidget
void resetMouseCaptureWidget()
Definition MyGUI_InputManager.cpp:687
MyGUI::InputManager::isModalAny
bool isModalAny() const
Definition MyGUI_InputManager.cpp:662
MyGUI::InputManager::eventChangeKeyFocus
delegates::MultiDelegate< Widget * > eventChangeKeyFocus
Definition MyGUI_InputManager.h:127
MyGUI::InputManager::injectMouseRelease
bool injectMouseRelease(int _absx, int _absy, MouseButton _id)
Definition MyGUI_InputManager.cpp:285
MyGUI::InputManager::isFocusKey
bool isFocusKey() const
Definition MyGUI_InputManager.cpp:618
MyGUI::InputManager::getClassTypeName
static std::string_view getClassTypeName()
MyGUI::InputManager::injectKeyPress
bool injectKeyPress(KeyCode _key, Char _text=0)
Definition MyGUI_InputManager.cpp:341
MyGUI::InputManager::injectKeyRelease
bool injectKeyRelease(KeyCode _key)
Definition MyGUI_InputManager.cpp:360
MyGUI::InputManager::addWidgetModal
void addWidgetModal(Widget *_widget)
Definition MyGUI_InputManager.cpp:503
MyGUI::InputManager::removeWidgetModal
void removeWidgetModal(Widget *_widget)
Definition MyGUI_InputManager.cpp:517
MyGUI::InputManager::getMousePositionByLayer
IntPoint getMousePositionByLayer() const
Definition MyGUI_InputManager.cpp:606
MyGUI::InputManager::InputManager
InputManager()
Definition MyGUI_InputManager.cpp:24
MyGUI::LayerItem::getLayer
ILayer * getLayer() const
Definition MyGUI_LayerItem.cpp:191
MyGUI::LayerManager::upLayerItem
void upLayerItem(Widget *_item)
Definition MyGUI_LayerManager.cpp:151
MyGUI::LayerManager::getInstance
static LayerManager & getInstance()
MyGUI::LayerManager::getWidgetFromPoint
Widget * getWidgetFromPoint(int _left, int _top) const
Definition MyGUI_LayerManager.cpp:211
MyGUI::Widget
widget description should be here.
Definition MyGUI_Widget.h:40
MyGUI::Widget::getParent
Widget * getParent() const
Definition MyGUI_Widget.cpp:1352
MyGUI::Widget::getInheritedEnabled
bool getInheritedEnabled() const
Definition MyGUI_Widget.cpp:1412
MyGUI::Widget::getWidgetStyle
WidgetStyle getWidgetStyle() const
Definition MyGUI_Widget.cpp:1377
MyGUI::Widget::_forcePick
void _forcePick(Widget *_widget)
Definition MyGUI_Widget.cpp:547
MyGUI::WidgetInput::_riseMouseMove
void _riseMouseMove(int _left, int _top)
Definition MyGUI_WidgetInput.cpp:50
MyGUI::WidgetInput::getRootKeyFocus
bool getRootKeyFocus() const
Definition MyGUI_WidgetInput.cpp:177
MyGUI::WidgetInput::_riseKeySetFocus
void _riseKeySetFocus(Widget *_old)
Definition MyGUI_WidgetInput.cpp:92
MyGUI::WidgetInput::_riseMouseButtonReleased
void _riseMouseButtonReleased(int _left, int _top, MouseButton _id)
Definition MyGUI_WidgetInput.cpp:68
MyGUI::WidgetInput::_riseMouseSetFocus
void _riseMouseSetFocus(Widget *_old)
Definition MyGUI_WidgetInput.cpp:38
MyGUI::WidgetInput::_riseMouseLostFocus
void _riseMouseLostFocus(Widget *_new)
Definition MyGUI_WidgetInput.cpp:32
MyGUI::WidgetInput::_riseKeyChangeRootFocus
void _riseKeyChangeRootFocus(bool _focus)
Definition MyGUI_WidgetInput.cpp:116
MyGUI::WidgetInput::getNeedKeyFocus
bool getNeedKeyFocus() const
Definition MyGUI_WidgetInput.cpp:147
MyGUI::WidgetInput::_riseKeyLostFocus
void _riseKeyLostFocus(Widget *_new)
Definition MyGUI_WidgetInput.cpp:86
MyGUI::WidgetInput::_setRootKeyFocus
void _setRootKeyFocus(bool _value)
Definition MyGUI_WidgetInput.cpp:187
MyGUI::WidgetInput::_setRootMouseFocus
void _setRootMouseFocus(bool _value)
Definition MyGUI_WidgetInput.cpp:182
MyGUI::WidgetInput::_riseMouseChangeRootFocus
void _riseMouseChangeRootFocus(bool _focus)
Definition MyGUI_WidgetInput.cpp:110
MyGUI::WidgetInput::getRootMouseFocus
bool getRootMouseFocus() const
Definition MyGUI_WidgetInput.cpp:172
MyGUI::WidgetManager::unregisterUnlinker
void unregisterUnlinker(IUnlinkWidget *_unlink)
Definition MyGUI_WidgetManager.cpp:144
MyGUI::WidgetManager::getInstance
static WidgetManager & getInstance()
MyGUI::WidgetManager::registerUnlinker
void registerUnlinker(IUnlinkWidget *_unlink)
Definition MyGUI_WidgetManager.cpp:138
MyGUI
Definition MyGUI_ActionController.h:15
MyGUI::INPUT_TIME_DOUBLE_CLICK
const float INPUT_TIME_DOUBLE_CLICK
Definition MyGUI_InputManager.cpp:18
MyGUI::IntPoint
types::TPoint< int > IntPoint
Definition MyGUI_Types.h:27
MyGUI::Char
unsigned int Char
Definition MyGUI_Types.h:50
MyGUI::newDelegate
delegates::DelegateFunction< Args... > * newDelegate(void(*_func)(Args... args))
Definition MyGUI_Delegate.h:100
MyGUI::INPUT_INTERVAL_KEY
const float INPUT_INTERVAL_KEY
Definition MyGUI_InputManager.cpp:20
MyGUI::INPUT_DELAY_FIRST_KEY
const float INPUT_DELAY_FIRST_KEY
Definition MyGUI_InputManager.cpp:19
MyGUI::KeyCode
Definition MyGUI_KeyCode.h:16
MyGUI::KeyCode::RightAlt
@ RightAlt
Definition MyGUI_KeyCode.h:137
MyGUI::KeyCode::LeftWindows
@ LeftWindows
Definition MyGUI_KeyCode.h:149
MyGUI::KeyCode::LeftAlt
@ LeftAlt
Definition MyGUI_KeyCode.h:75
MyGUI::KeyCode::LeftShift
@ LeftShift
Definition MyGUI_KeyCode.h:61
MyGUI::KeyCode::RightWindows
@ RightWindows
Definition MyGUI_KeyCode.h:151
MyGUI::KeyCode::RightShift
@ RightShift
Definition MyGUI_KeyCode.h:73
MyGUI::KeyCode::LeftControl
@ LeftControl
Definition MyGUI_KeyCode.h:48
MyGUI::KeyCode::None
@ None
Definition MyGUI_KeyCode.h:19
MyGUI::KeyCode::RightControl
@ RightControl
Definition MyGUI_KeyCode.h:126
MyGUI::MouseButton
Definition MyGUI_MouseButton.h:16
MyGUI::MouseButton::Enum
Enum
Definition MyGUI_MouseButton.h:18
MyGUI::MouseButton::Button0
@ Button0
Definition MyGUI_MouseButton.h:25
MyGUI::MouseButton::Left
@ Left
Definition MyGUI_MouseButton.h:21
MyGUI::MouseButton::None
@ None
Definition MyGUI_MouseButton.h:19
MyGUI::MouseButton::MAX
@ MAX
Definition MyGUI_MouseButton.h:33
MyGUI::MouseButton::getValue
int getValue() const
Definition MyGUI_MouseButton.h:51
MyGUI::WidgetStyle::Overlapped
@ Overlapped
Definition MyGUI_WidgetStyle.h:24
MyGUI::types::TPoint::empty
bool empty() const
Definition MyGUI_TPoint.h:90
MyGUI::types::TPoint::left
T left
Definition MyGUI_TPoint.h:19
MyGUI::types::TPoint::top
T top
Definition MyGUI_TPoint.h:20