diff options
author | Vir Linden <vir@lindenlab.com> | 2021-10-25 15:55:06 +0000 |
---|---|---|
committer | Vir Linden <vir@lindenlab.com> | 2021-10-25 15:55:06 +0000 |
commit | ba3459f77fc9b93c8dd79bc3ac7c59ba792da27f (patch) | |
tree | 6267b828141028889894be919263c6d19c6e54c1 /indra/llwindow/llwindowwin32.h | |
parent | a42b5d680935f08310de69f240435a7b67227a4d (diff) | |
parent | 3efd4c50a031ce0c1cb3d2fcc43e403136277e1f (diff) |
Merged DRTVWR-546 into SL-15999
Diffstat (limited to 'indra/llwindow/llwindowwin32.h')
-rw-r--r-- | indra/llwindow/llwindowwin32.h | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/indra/llwindow/llwindowwin32.h b/indra/llwindow/llwindowwin32.h index ea1c103bcd..7a9a30ccea 100644 --- a/indra/llwindow/llwindowwin32.h +++ b/indra/llwindow/llwindowwin32.h @@ -35,6 +35,7 @@ #include "lldragdropwin32.h" #include "llthread.h" #include "llthreadsafequeue.h" +#include "llmutex.h" // Hack for async host by name #define LL_WM_HOST_RESOLVED (WM_APP + 1) @@ -99,6 +100,7 @@ public: void destroySharedContext(void* context) override; /*virtual*/ BOOL setCursorPosition(LLCoordWindow position); /*virtual*/ BOOL getCursorPosition(LLCoordWindow *position); + /*virtual*/ BOOL getCursorDelta(LLCoordCommon* delta); /*virtual*/ void showCursor(); /*virtual*/ void hideCursor(); /*virtual*/ void showCursorFromMouseMove(); @@ -222,6 +224,14 @@ protected: F32 mNativeAspectRatio; HCURSOR mCursor[ UI_CURSOR_COUNT ]; // Array of all mouse cursors + LLCoordWindow mCursorPosition; // mouse cursor position, should only be mutated on main thread + LLMutex mRawMouseMutex; + RAWINPUTDEVICE mRawMouse; + LLCoordWindow mLastCursorPosition; // mouse cursor position from previous frame + LLCoordCommon mRawMouseDelta; // raw mouse delta according to window thread + LLCoordCommon mMouseFrameDelta; // how much the mouse moved between the last two calls to gatherInput + + MASK mMouseMask; static BOOL sIsClassRegistered; // has the window class been registered? @@ -232,7 +242,6 @@ protected: BOOL mCustomGammaSet; LPWSTR mIconResource; - BOOL mMousePositionModified; BOOL mInputProcessingPaused; // The following variables are for Language Text Input control. @@ -262,7 +271,9 @@ protected: LLWindowWin32Thread* mWindowThread = nullptr; LLThreadSafeQueue<std::function<void()>> mFunctionQueue; + LLThreadSafeQueue<std::function<void()>> mMouseQueue; void post(const std::function<void()>& func); + void postMouseButtonEvent(const std::function<void()>& func); friend class LLWindowManager; friend class LLWindowWin32Thread; |