summaryrefslogtreecommitdiff
path: root/indra/llwindow/llwindowwin32.h
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llwindow/llwindowwin32.h')
-rw-r--r--indra/llwindow/llwindowwin32.h17
1 files changed, 16 insertions, 1 deletions
diff --git a/indra/llwindow/llwindowwin32.h b/indra/llwindow/llwindowwin32.h
index 66647459b2..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)
@@ -93,8 +94,13 @@ public:
/*virtual*/ BOOL setSizeImpl(LLCoordScreen size);
/*virtual*/ BOOL setSizeImpl(LLCoordWindow size);
/*virtual*/ BOOL switchContext(BOOL fullscreen, const LLCoordScreen &size, BOOL disable_vsync, const LLCoordScreen * const posp = NULL);
+ /*virtual*/ void setTitle(const std::string title);
+ void* createSharedContext() override;
+ void makeContextCurrent(void* context) override;
+ 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();
@@ -218,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?
@@ -228,7 +242,6 @@ protected:
BOOL mCustomGammaSet;
LPWSTR mIconResource;
- BOOL mMousePositionModified;
BOOL mInputProcessingPaused;
// The following variables are for Language Text Input control.
@@ -258,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;