[glom] BusyCursor: Use the non-deprecated Gdk::Cursor::create(), taking a Display.



commit c58cf14e35b67884f16449f30dc63ad8c5e9f4c4
Author: Murray Cumming <murrayc murrayc com>
Date:   Tue Dec 2 20:12:07 2014 +0100

    BusyCursor: Use the non-deprecated Gdk::Cursor::create(), taking a Display.

 glom/bakery/busy_cursor.cc |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)
---
diff --git a/glom/bakery/busy_cursor.cc b/glom/bakery/busy_cursor.cc
index 96d909e..84cff3c 100644
--- a/glom/bakery/busy_cursor.cc
+++ b/glom/bakery/busy_cursor.cc
@@ -9,18 +9,19 @@ namespace Glom
 BusyCursor::type_map_cursors BusyCursor::m_map_cursors;
 
 BusyCursor::BusyCursor(Gtk::Window& window, Gdk::CursorType cursor_type)
-: m_Cursor( Gdk::Cursor::create(cursor_type) ),
+: m_Cursor( Gdk::Cursor::create(window.get_display(), cursor_type) ),
   m_pWindow(&window) //If this is a nested cursor then remember the previously-set cursor, so we can restore 
it.
 {
   init();
 }
 
 BusyCursor::BusyCursor(Gtk::Window* window, Gdk::CursorType cursor_type)
-: m_Cursor( Gdk::Cursor::create(cursor_type) ),
-  m_pWindow(window) //If this is a nested cursor then remember the previously-set cursor, so we can restore 
it.
+:  m_pWindow(window) //If this is a nested cursor then remember the previously-set cursor, so we can restore 
it.
 {
-  if(m_pWindow)
+  if(m_pWindow) {
+    m_Cursor = Gdk::Cursor::create(m_pWindow->get_display(), cursor_type);
     init();
+  }
 }
 
 void BusyCursor::init()


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]