#include <C4Gui.h>
Public Types | |
enum | TooltipShowState { TTST_None = 0 , TTST_Immediate = 1 , TTST_All = 2 } |
Public Member Functions | |
CMouse (int32_t iX, int32_t iY) | |
~CMouse () | |
void | Draw (C4TargetFacet &cgo, TooltipShowState draw_tool_tips) |
void | Input (int32_t iButton, int32_t iX, int32_t iY, DWORD dwKeyParam) |
bool | IsLDown () |
void | GetLastXY (int32_t &rX, int32_t &rY, DWORD &rdwKeys) |
void | ResetElements () |
void | ReleaseElements () |
void | OnElementGetsInvisible (Element *pChild) |
void | RemoveElement (Element *pChild) |
void | SetOwnedMouse (bool fToVal) |
void | ResetToolTipTime () |
bool | IsMouseStill () |
void | ResetActiveInput () |
bool | IsActiveInput () |
void | ReleaseButtons () |
Public Attributes | |
int32_t | x |
int32_t | y |
bool | LDown |
bool | MDown |
bool | RDown |
int32_t | LDownX |
int32_t | LDownY |
DWORD | dwKeys |
bool | fActive |
C4TimeMilliseconds | tLastMovementTime |
bool | fActiveInput |
Element * | pMouseOverElement |
Element * | pPrevMouseOverElement |
Element * | pDragElement |
Enumerator | |
---|---|
TTST_None | |
TTST_Immediate | |
TTST_All |
Definition at line 2547 of file C4Gui.h.
C4GUI::CMouse::CMouse | ( | int32_t | iX, |
int32_t | iY | ||
) |
Definition at line 448 of file C4Gui.cpp.
References dwKeys, LDown, MDown, pDragElement, pMouseOverElement, pPrevMouseOverElement, RDown, ResetToolTipTime(), x, and y.
|
default |
void C4GUI::CMouse::Draw | ( | C4TargetFacet & | cgo, |
TooltipShowState | draw_tool_tips | ||
) |
Definition at line 485 of file C4Gui.cpp.
References C4GUI::Screen::DrawToolTip(), fActive, C4GUI::Element::GetToolTip(), C4Draw::GetZoom(), GfxR, C4Facet::Hgt, C4GUI::Element::IsImmediateToolTip(), pDraw, pMouseOverElement, C4TargetFacet::Set(), C4Draw::SetZoom(), C4Facet::Surface, TTST_All, TTST_None, C4Facet::Wdt, C4Facet::X, x, C4Facet::Y, y, and ZoomData::Zoom.
Referenced by C4GUI::Screen::RenderMouse().
|
inline |
void C4GUI::CMouse::Input | ( | int32_t | iButton, |
int32_t | iX, | ||
int32_t | iY, | ||
DWORD | dwKeyParam | ||
) |
Definition at line 463 of file C4Gui.cpp.
References C4MC_Button_LeftDown, C4MC_Button_LeftUp, C4MC_Button_RightDown, C4MC_Button_RightUp, dwKeys, fActiveInput, LDown, LDownX, LDownY, RDown, ResetToolTipTime(), x, and y.
Referenced by C4GUI::Screen::MouseInput().
|
inline |
Definition at line 2581 of file C4Gui.h.
References fActiveInput.
Referenced by C4Menu::Draw(), and C4GUI::Screen::RenderMouse().
|
inline |
Definition at line 2565 of file C4Gui.h.
References LDown.
Referenced by C4GUI::ScrollBar::MouseInput(), and C4GUI::Screen::MouseInput().
|
inline |
Definition at line 2579 of file C4Gui.h.
References C4GUI_ToolTipShowTime, C4TimeMilliseconds::Now(), and tLastMovementTime.
Referenced by C4GUI::Screen::RenderMouse().
void C4GUI::CMouse::OnElementGetsInvisible | ( | Element * | pChild | ) |
Definition at line 546 of file C4Gui.cpp.
References RemoveElement().
Referenced by C4GUI::Element::SetVisibility().
|
inline |
void C4GUI::CMouse::ReleaseElements | ( | ) |
Definition at line 519 of file C4Gui.cpp.
References dwKeys, GetLastXY(), C4GUI::Element::MouseLeave(), pDragElement, pMouseOverElement, pPrevMouseOverElement, C4GUI::Element::ScreenPos2ClientPos(), and C4GUI::Element::StopDragging().
Referenced by C4GUI::Screen::ActivateDialog(), C4GUI::Screen::CloseDialog(), and C4GUI::Screen::RecheckActiveDialog().
void C4GUI::CMouse::RemoveElement | ( | Element * | pChild | ) |
Definition at line 534 of file C4Gui.cpp.
References C4GUI::Element::MouseLeave(), pDragElement, pMouseOverElement, and pPrevMouseOverElement.
Referenced by OnElementGetsInvisible(), C4GUI::ContextMenu::RemoveElement(), and C4GUI::Screen::RemoveElement().
|
inline |
Definition at line 2580 of file C4Gui.h.
References fActiveInput.
Referenced by C4GUI::Screen::CharIn(), and C4GUI::Screen::KeyAny().
|
inline |
Definition at line 2569 of file C4Gui.h.
References pDragElement, pMouseOverElement, and pPrevMouseOverElement.
Referenced by C4GUI::Screen::RemoveElement().
|
inline |
Definition at line 2578 of file C4Gui.h.
References C4TimeMilliseconds::Now(), and tLastMovementTime.
Referenced by CMouse(), and Input().
|
inline |
Definition at line 2576 of file C4Gui.h.
References fActive.
Referenced by C4GUI::Screen::SetExclusive(), and C4GUI::Screen::SetMouseInGUI().
DWORD C4GUI::CMouse::dwKeys |
Definition at line 2538 of file C4Gui.h.
Referenced by CMouse(), GetLastXY(), Input(), C4GUI::Screen::RecheckMouseInput(), ReleaseElements(), and C4GUI::Screen::SetMouseInGUI().
bool C4GUI::CMouse::fActive |
Definition at line 2539 of file C4Gui.h.
Referenced by Draw(), and SetOwnedMouse().
bool C4GUI::CMouse::fActiveInput |
Definition at line 2545 of file C4Gui.h.
Referenced by Input(), IsActiveInput(), and ResetActiveInput().
bool C4GUI::CMouse::LDown |
Definition at line 2536 of file C4Gui.h.
Referenced by CMouse(), Input(), IsLDown(), C4ScriptGuiWindow::ProcessMouseInput(), and ReleaseButtons().
bool C4GUI::CMouse::MDown |
Definition at line 2536 of file C4Gui.h.
Referenced by CMouse(), and ReleaseButtons().
Element* C4GUI::CMouse::pDragElement |
Definition at line 2556 of file C4Gui.h.
Referenced by CMouse(), C4GUI::Button::MouseEnter(), C4GUI::Element::MouseInput(), C4GUI::ScrollBar::MouseInput(), C4GUI::Button::MouseInput(), C4GUI::Edit::MouseInput(), C4GUI::Screen::MouseInput(), C4GUI::Button::MouseLeave(), ReleaseElements(), RemoveElement(), ResetElements(), and C4GUI::Element::StartDragging().
Element* C4GUI::CMouse::pMouseOverElement |
Definition at line 2555 of file C4Gui.h.
Referenced by CMouse(), Draw(), C4GUI::Element::MouseInput(), C4GUI::Screen::MouseInput(), ReleaseElements(), RemoveElement(), and ResetElements().
Element * C4GUI::CMouse::pPrevMouseOverElement |
Definition at line 2555 of file C4Gui.h.
Referenced by CMouse(), C4GUI::Screen::MouseInput(), ReleaseElements(), RemoveElement(), and ResetElements().
bool C4GUI::CMouse::RDown |
Definition at line 2536 of file C4Gui.h.
Referenced by CMouse(), Input(), and ReleaseButtons().
C4TimeMilliseconds C4GUI::CMouse::tLastMovementTime |
Definition at line 2540 of file C4Gui.h.
Referenced by IsMouseStill(), and ResetToolTipTime().
int32_t C4GUI::CMouse::x |
Definition at line 2535 of file C4Gui.h.
Referenced by CMouse(), Draw(), GetLastXY(), C4GUI::Screen::Init(), Input(), C4GUI::Window::MouseInput(), C4GUI::Screen::RecheckMouseInput(), and C4GUI::Screen::SetMouseInGUI().
int32_t C4GUI::CMouse::y |
Definition at line 2535 of file C4Gui.h.
Referenced by CMouse(), Draw(), GetLastXY(), C4GUI::Screen::Init(), Input(), C4GUI::Screen::RecheckMouseInput(), and C4GUI::Screen::SetMouseInGUI().