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:
authorChristian Rauch <Rauch.Christian@gmx.de>2021-05-22 18:41:58 +0300
committerChristian Rauch <Rauch.Christian@gmx.de>2021-06-03 20:18:27 +0300
commit1fd653dd823e88fede039cc304341263642cec55 (patch)
tree051710682e8626d1883fd31eb3f44c0849d0ccc2 /intern/ghost/intern/GHOST_SystemWayland.cpp
parentd9aae38bc8377f4cb99a1fbd2d92e367fcfceac6 (diff)
GHOST/wayland: handle missing relative-pointer and pointer-constraints support
Diffstat (limited to 'intern/ghost/intern/GHOST_SystemWayland.cpp')
-rw-r--r--intern/ghost/intern/GHOST_SystemWayland.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/intern/ghost/intern/GHOST_SystemWayland.cpp b/intern/ghost/intern/GHOST_SystemWayland.cpp
index 97a2f7501a3..f1d867da884 100644
--- a/intern/ghost/intern/GHOST_SystemWayland.cpp
+++ b/intern/ghost/intern/GHOST_SystemWayland.cpp
@@ -1739,6 +1739,11 @@ GHOST_TSuccess GHOST_SystemWayland::setCursorVisibility(bool visible)
GHOST_TSuccess GHOST_SystemWayland::setCursorGrab(const GHOST_TGrabCursorMode mode,
wl_surface *surface)
{
+ /* ignore, if the required protocols are not supported */
+ if (!d->relative_pointer_manager || !d->pointer_constraints) {
+ return GHOST_kFailure;
+ }
+
if (d->inputs.empty()) {
return GHOST_kFailure;
}