summaryrefslogtreecommitdiff
path: root/platform/x11/os_x11.cpp
diff options
context:
space:
mode:
authorGuilherme Felipe <guilhermefelipecgs@gmail.com>2018-04-08 21:59:51 -0300
committerGuilherme Felipe <guilhermefelipecgs@gmail.com>2018-04-09 10:28:20 -0300
commit62b835a2cdc1216753229ddb3ebd0fcdcc988eb9 (patch)
treea4f863394195b0d99f19951ffecd462a494e5e79 /platform/x11/os_x11.cpp
parentb67bfa3328baf8bbc4174a3facbceb1cccdea4ec (diff)
Fix custom cursor when it's hidden
[Linux] Ensures that the custom cursor will be used when changing to MOUSE_MODE_VISIBLE. Fix #3086 [Windows] Fix cursor flickering when MOUSE_MODE_HIDDEN. [Mac] Fix possible cursor flicker when MOUSE_MODE_HIDDEN.
Diffstat (limited to 'platform/x11/os_x11.cpp')
-rw-r--r--platform/x11/os_x11.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/platform/x11/os_x11.cpp b/platform/x11/os_x11.cpp
index 338d13410f..1928800d8c 100644
--- a/platform/x11/os_x11.cpp
+++ b/platform/x11/os_x11.cpp
@@ -634,7 +634,7 @@ void OS_X11::set_mouse_mode(MouseMode p_mode) {
bool showCursor = (p_mode == MOUSE_MODE_VISIBLE || p_mode == MOUSE_MODE_CONFINED);
if (showCursor) {
- XUndefineCursor(x11_display, x11_window); // show cursor
+ XDefineCursor(x11_display, x11_window, cursors[current_cursor]); // show cursor
} else {
XDefineCursor(x11_display, x11_window, null_cursor); // hide cursor
}