]> git.saurik.com Git - wxWidgets.git/commitdiff
build fix for older gtk2
authorPaul Cornett <paulcor@bullseye.com>
Sat, 17 Jun 2006 21:09:53 +0000 (21:09 +0000)
committerPaul Cornett <paulcor@bullseye.com>
Sat, 17 Jun 2006 21:09:53 +0000 (21:09 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39768 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/gtk/cursor.cpp

index d02105ec8b92d052e6cce486cf6cd6b792df50a9..90d718db89d29417af1f5c77dc785f3932460d44 100644 (file)
@@ -144,7 +144,12 @@ wxCursor::wxCursor(const char bits[], int width, int  height,
 
     m_refData = new wxCursorRefData;
     M_CURSORDATA->m_cursor = gdk_cursor_new_from_pixmap(
-                 data, mask, fg->GetColor(), bg->GetColor(),
+                 data, mask,
+#if GTK_CHECK_VERSION(2, 6, 0)
+                 fg->GetColor(), bg->GetColor(),
+#else
+                 wx_const_cast(GdkColor*, fg->GetColor()), wx_const_cast(GdkColor*, bg->GetColor()),
+#endif
                  hotSpotX, hotSpotY );
 
     g_object_unref (data);
@@ -295,7 +300,11 @@ wxCursor::wxCursor( const wxImage & image )
                              (
                                 data,
                                 mask,
+#if GTK_CHECK_VERSION(2, 6, 0)
                                 fg.GetColor(), bg.GetColor(),
+#else
+                                wx_const_cast(GdkColor*, fg.GetColor()), wx_const_cast(GdkColor*, bg.GetColor()),
+#endif
                                 hotSpotX, hotSpotY
                              );