From 10359304b1502d3c3227f74cd646af7a26003cab Mon Sep 17 00:00:00 2001 From: Joe Marcus Clarke Date: Mon, 9 Jun 2008 23:02:55 +0000 Subject: Fix a problem where the window position would not be remembered. Reported by: Alexander Loginov Obtained from: http://bugzilla.gnome.org/show_bug.cgi?id=536757 --- x11-toolkits/gtk20/Makefile | 2 +- .../gtk20/files/patch-gdk_x11_gdkwindow-x11.c | 31 ++++++++++++++++++++++ 2 files changed, 32 insertions(+), 1 deletion(-) create mode 100644 x11-toolkits/gtk20/files/patch-gdk_x11_gdkwindow-x11.c (limited to 'x11-toolkits/gtk20') diff --git a/x11-toolkits/gtk20/Makefile b/x11-toolkits/gtk20/Makefile index e6bde051e963..d5550666f786 100644 --- a/x11-toolkits/gtk20/Makefile +++ b/x11-toolkits/gtk20/Makefile @@ -8,7 +8,7 @@ PORTNAME= gtk PORTVERSION= 2.12.10 -PORTREVISION?= 1 +PORTREVISION?= 2 CATEGORIES= x11-toolkits MASTER_SITES= ${MASTER_SITE_GNOME:S,%SUBDIR%,sources/gtk+/${PORTVERSION:C/^([0-9]+\.[0-9]+).*/\1/}/,} \ ftp://ftp.gtk.org/pub/gtk/%SUBDIR%/ \ diff --git a/x11-toolkits/gtk20/files/patch-gdk_x11_gdkwindow-x11.c b/x11-toolkits/gtk20/files/patch-gdk_x11_gdkwindow-x11.c new file mode 100644 index 000000000000..d9ce8c811ed2 --- /dev/null +++ b/x11-toolkits/gtk20/files/patch-gdk_x11_gdkwindow-x11.c @@ -0,0 +1,31 @@ +Index: gdk/x11/gdkwindow-x11.c +=================================================================== +--- gdk/x11/gdkwindow-x11.c (revision 20280) ++++ gdk/x11/gdkwindow-x11.c (working copy) +@@ -3412,6 +3412,7 @@ + Window xwindow; + Window xparent; + Window root; ++ Window child; + Window *children; + guchar *data; + Window *vroots; +@@ -3470,13 +3471,15 @@ + if ((type_return == XA_CARDINAL) && (format_return == 32) && + (nitems_return == 4) && (data)) + { +- guint32 *ldata = (guint32 *) data; ++ gulong *ldata = (gulong *) data; + got_frame_extents = TRUE; + + /* try to get the real client window geometry */ + if (XGetGeometry (GDK_DISPLAY_XDISPLAY (display), xwindow, +- &root, &wx, &wy, &ww, &wh, &wb, &wd)) +- { ++ &root, &wx, &wy, &ww, &wh, &wb, &wd) && ++ XTranslateCoordinates (GDK_DISPLAY_XDISPLAY (display), ++ xwindow, root, 0, 0, &wx, &wy, &child)) ++ { + rect->x = wx; + rect->y = wy; + rect->width = ww; -- cgit v1.2.3