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
path: root/source
diff options
context:
space:
mode:
Diffstat (limited to 'source')
-rw-r--r--source/blender/windowmanager/intern/wm_cursors.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/source/blender/windowmanager/intern/wm_cursors.c b/source/blender/windowmanager/intern/wm_cursors.c
index 6145871f9d4..7decf7b2ed2 100644
--- a/source/blender/windowmanager/intern/wm_cursors.c
+++ b/source/blender/windowmanager/intern/wm_cursors.c
@@ -172,12 +172,13 @@ void WM_cursor_grab(wmWindow *win, int wrap, int hide, int *bounds)
if(hide) mode = GHOST_kGrabHide;
else if(wrap) mode = GHOST_kGrabWrap;
-
if ((G.f & G_DEBUG) == 0) {
if (win && win->ghostwin) {
const GHOST_TabletData *tabletdata= GHOST_GetTabletData(win->ghostwin);
-
- if ((tabletdata) && (tabletdata->Active == GHOST_kTabletModeNone))
+ // Note: There is no tabletdata on Windows if no tablet device is connected.
+ if (!tabletdata)
+ GHOST_SetCursorGrab(win->ghostwin, mode, bounds);
+ else if (tabletdata->Active == GHOST_kTabletModeNone)
GHOST_SetCursorGrab(win->ghostwin, mode, bounds);
}
}