diff options
-rw-r--r-- | backends/x11/x11.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/backends/x11/x11.cpp b/backends/x11/x11.cpp index 7152ad490d..bd8a541e0f 100644 --- a/backends/x11/x11.cpp +++ b/backends/x11/x11.cpp @@ -71,6 +71,11 @@ public: // Set the position of the mouse cursor void set_mouse_pos(int x, int y); + // Warp the mouse cursor. Where set_mouse_pos() only informs the + // backend of the mouse cursor's current position, this function + // actually moves the cursor to the specified position. + void warp_mouse(int x, int y); + // Set the bitmap that's used when drawing the cursor. void set_mouse_cursor(const byte *buf, uint w, uint h, int hotspot_x, int hotspot_y); @@ -730,6 +735,11 @@ void OSystem_X11::set_mouse_pos(int x, int y) } } +void OSystem_X11::warp_mouse(int x, int y) +{ + set_mouse_pos(x, y); +} + void OSystem_X11::set_mouse_cursor(const byte *buf, uint w, uint h, int hotspot_x, int hotspot_y) { cur_state.w = w; |