MCPcopy Create free account
hub / github.com/OGSR/OGSR-Engine / IR_OnMouseMove

Method IR_OnMouseMove

ogsr_engine/xrGame/ui/UIDialogWnd.cpp:144–170  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

142}
143
144bool CUIDialogWnd::IR_OnMouseMove(int dx, int dy)
145{
146 if (!IR_process())
147 return false;
148
149 if (GetUICursor()->IsVisible())
150 {
151 GetUICursor()->UpdateCursorPosition(dx, dy);
152 Fvector2 cPos = GetUICursor()->GetCursorPosition();
153
154 OnMouse(cPos.x, cPos.y, WINDOW_MOUSE_MOVE);
155 }
156 else if (!StopAnyMove() && g_pGameLevel)
157 {
158 CObject* O = Level().CurrentEntity();
159 if (O)
160 {
161 IInputReceiver* IR = smart_cast<IInputReceiver*>(smart_cast<CGameObject*>(O));
162 if (!IR)
163 return (false);
164
165 IR->IR_OnMouseMove(dx, dy);
166 }
167 };
168
169 return true;
170}
171
172bool CUIDialogWnd::OnKeyboardHold(int dik)
173{

Callers

nothing calls this directly

Calls 4

GetUICursorFunction · 0.85
UpdateCursorPositionMethod · 0.80
GetCursorPositionMethod · 0.80
IsVisibleMethod · 0.45

Tested by

no test coverage detected