]> Pileus Git - ~andy/gtk/commitdiff
Bug 544684 - Win64 issue, window handles are assumed to be 32-bit
authorTor Lillqvist <tml@novell.com>
Mon, 4 Aug 2008 22:57:36 +0000 (22:57 +0000)
committerTor Lillqvist <tml@src.gnome.org>
Mon, 4 Aug 2008 22:57:36 +0000 (22:57 +0000)
2008-08-05  Tor Lillqvist  <tml@novell.com>

Bug 544684 - Win64 issue, window handles are assumed to be 32-bit

* gtk/gtkwindow.h
* gtk/gtkwindow.c: Change the type of the xid parameter of the
internal gtk_window_remove_embedded_xid() and
gtk_window_add_embedded_xid() functions from guint to
GdkNativeWindow.

* gtk/gtkwindow.c (send_client_message_to_embedded_windows):
Instead of GPOINTER_TO_UINT(), just cast the gpointer to
GdkNativeWindow. GPOINTER_TO_UINT() drops the upper 32 bits on
Win64.

svn path=/trunk/; revision=20992

ChangeLog
gtk/gtkwindow.c
gtk/gtkwindow.h

index 3667d216f4d9f7a536ff276524656afd978277bc..47b90abbece424e595da6558d054436a42533de2 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
        casts to get rid of gcc 4.4 warnings. Print GdkAtom values in
        debugging output using the %p format.
        
+       * gtk/gtkwindow.h
+       * gtk/gtkwindow.c: Change the type of the xid parameter of the
+       internal gtk_window_remove_embedded_xid() and
+       gtk_window_add_embedded_xid() functions from guint to
+       GdkNativeWindow.
+
+       * gtk/gtkwindow.c (send_client_message_to_embedded_windows):
+       Instead of GPOINTER_TO_UINT(), just cast the gpointer to
+       GdkNativeWindow. GPOINTER_TO_UINT() drops the upper 32 bits on
+       Win64.
+
 2008-08-05  Tor Lillqvist  <tml@novell.com>
 
        * gdk/gdkrgb.c: Cast pointers to guintptr, not unsigned long,
index b1ffd959ca8a225dbdbc5057544a69bc32be8f72..c020354c25ac8a43fbfc122945669e449bc9e35c 100644 (file)
@@ -1936,7 +1936,7 @@ gtk_window_list_toplevels (void)
 }
 
 void
-gtk_window_add_embedded_xid (GtkWindow *window, guint xid)
+gtk_window_add_embedded_xid (GtkWindow *window, GdkNativeWindow xid)
 {
   GList *embedded_windows;
 
@@ -1955,7 +1955,7 @@ gtk_window_add_embedded_xid (GtkWindow *window, guint xid)
 }
 
 void
-gtk_window_remove_embedded_xid (GtkWindow *window, guint xid)
+gtk_window_remove_embedded_xid (GtkWindow *window, GdkNativeWindow xid)
 {
   GList *embedded_windows;
   GList *node;
@@ -5140,7 +5140,7 @@ send_client_message_to_embedded_windows (GtkWidget *widget,
       
       while (embedded_windows)
        {
-         guint xid = GPOINTER_TO_UINT (embedded_windows->data);
+         GdkNativeWindow xid = (GdkNativeWindow) embedded_windows->data;
          gdk_event_send_client_message_for_display (gtk_widget_get_display (widget), send_event, xid);
          embedded_windows = embedded_windows->next;
        }
index a399e267c3fbcc9c307b6c9cca81489815887e0d..20829eca4e4f4ec759d98a02eaf0bb698c93da0a 100644 (file)
@@ -398,10 +398,10 @@ GList *          gtk_window_group_list_windows  (GtkWindowGroup     *window_grou
 /* --- internal functions --- */
 void            _gtk_window_internal_set_focus (GtkWindow *window,
                                                GtkWidget *focus);
-void            gtk_window_remove_embedded_xid (GtkWindow *window,
-                                               guint      xid);
-void            gtk_window_add_embedded_xid    (GtkWindow *window,
-                                               guint      xid);
+void            gtk_window_remove_embedded_xid (GtkWindow       *window,
+                                               GdkNativeWindow  xid);
+void            gtk_window_add_embedded_xid    (GtkWindow       *window,
+                                               GdkNativeWindow  xid);
 void            _gtk_window_reposition         (GtkWindow *window,
                                                gint       x,
                                                gint       y);