summaryrefslogtreecommitdiff
path: root/src/Fl_win32.cxx
diff options
context:
space:
mode:
authorManolo Gouy <Manolo>2017-06-28 13:33:53 +0000
committerManolo Gouy <Manolo>2017-06-28 13:33:53 +0000
commit322b62a9f126987914193dedbc892b8e5c17f453 (patch)
tree2fefd2fb327f9caaed1f1d7798818767598db136 /src/Fl_win32.cxx
parent9041a3dc70aa376896f992c43ec1a6d63a9a8d1a (diff)
HiDPI support: keep window's cursor after rescaling.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12275 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_win32.cxx')
-rw-r--r--src/Fl_win32.cxx11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/Fl_win32.cxx b/src/Fl_win32.cxx
index 364a1c1ae..89d4d4685 100644
--- a/src/Fl_win32.cxx
+++ b/src/Fl_win32.cxx
@@ -2294,6 +2294,7 @@ int Fl_WinAPI_Window_Driver::set_cursor(Fl_Cursor c) {
custom_cursor = 0;
SetCursor(cursor);
+ current_cursor_ = c;
return 1;
}
@@ -2316,6 +2317,16 @@ int Fl_WinAPI_Window_Driver::set_cursor(const Fl_RGB_Image *image, int hotx, int
return 1;
}
+void Fl_WinAPI_Window_Driver::reuse_cursor(fl_uintptr_t c) {
+ // calling SetCursor(cursor) does not work, so we call the crossplatform API
+ pWindow->cursor((Fl_Cursor)c);
+}
+
+fl_uintptr_t Fl_WinAPI_Window_Driver::current_cursor() {
+ return (fl_uintptr_t)current_cursor_;
+}
+
+
////////////////////////////////////////////////////////////////
// Implement the virtual functions for the base Fl_Window class: