Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <campbell@blender.org>2022-06-08 06:01:31 +0300
committerCampbell Barton <campbell@blender.org>2022-06-08 06:16:14 +0300
commita1d2efd190038c7615bd3bb459dc86c8b3a8ecdc (patch)
tree2f709a3566c84d45ccd352104573626a445cdb41 /intern/ghost/GHOST_C-api.h
parentb3e0101a35b2885212aa199335564dca98dc50cd (diff)
GHOST/Wayland: draw a software-cursor when wrapping cursor motion
As Wayland doesn't support moving the cursor, draw a cross-hair cursor at the location used by Blender. Without this, the cursor was locked at the location where grab started, making some actions unusable since the cursor location was invisible. Resolves T77311.
Diffstat (limited to 'intern/ghost/GHOST_C-api.h')
-rw-r--r--intern/ghost/GHOST_C-api.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/intern/ghost/GHOST_C-api.h b/intern/ghost/GHOST_C-api.h
index ae749eb3b8c..57714083656 100644
--- a/intern/ghost/GHOST_C-api.h
+++ b/intern/ghost/GHOST_C-api.h
@@ -402,6 +402,10 @@ extern GHOST_TSuccess GHOST_SetCursorPosition(GHOST_SystemHandle systemhandle,
int32_t x,
int32_t y);
+GHOST_TSuccess GHOST_GetCursorGrabState(GHOST_WindowHandle windowhandle,
+ GHOST_TAxisFlag *r_wrap_axis,
+ int r_bounds[4]);
+
/**
* Grabs the cursor for a modal operation, to keep receiving
* events when the mouse is outside the window. X11 only, others
@@ -897,6 +901,11 @@ extern int setConsoleWindowState(GHOST_TConsoleWindowState action);
extern int GHOST_UseNativePixels(void);
/**
+ * Warp the cursor, if supported.
+ */
+extern int GHOST_SupportsCursorWarp(void);
+
+/**
* Focus window after opening, or put them in the background.
*/
extern void GHOST_UseWindowFocus(int use_focus);