diff options
Diffstat (limited to 'src/desktop.cpp')
| -rw-r--r-- | src/desktop.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/desktop.cpp b/src/desktop.cpp index 47c82b6d9..dad60832d 100644 --- a/src/desktop.cpp +++ b/src/desktop.cpp @@ -1503,12 +1503,11 @@ void SPDesktop::disableInteraction() void SPDesktop::setWaitingCursor() { - GdkDisplay *display = gdk_display_get_default(); - GdkCursor *waiting = gdk_cursor_new_for_display(display, GDK_WATCH); - gdk_window_set_cursor(gtk_widget_get_window(GTK_WIDGET(getCanvas())), waiting); - g_object_unref(waiting); + Glib::RefPtr<Gdk::Display> display = Gdk::Display::get_default(); + Glib::RefPtr<Gdk::Cursor> waiting = Gdk::Cursor::create(display, Gdk::WATCH); + Glib::wrap(GTK_WIDGET(getCanvas()))->get_window()->set_cursor(waiting); // GDK needs the flush for the cursor change to take effect - gdk_flush(); + display->flush(); waiting_cursor = true; } |
