diff options
author | oliver <oliver@FreeBSD.org> | 2007-10-26 19:23:22 +0800 |
---|---|---|
committer | oliver <oliver@FreeBSD.org> | 2007-10-26 19:23:22 +0800 |
commit | 7f25f18c55f3966fcf344b4246ef06035aa65679 (patch) | |
tree | a7053850e4964e4b053479b364e3f414282752de /x11-wm/xfce4-wm/files | |
parent | c2a355b57393fd86e7612d8f5c621eeb1cad9891 (diff) | |
download | freebsd-ports-gnome-7f25f18c55f3966fcf344b4246ef06035aa65679.tar.gz freebsd-ports-gnome-7f25f18c55f3966fcf344b4246ef06035aa65679.tar.zst freebsd-ports-gnome-7f25f18c55f3966fcf344b4246ef06035aa65679.zip |
fix a problem with gtk 2.12 which caused the wm to freeze
more info: http://bugzilla.xfce.org/show_bug.cgi?id=3346
PR: 117511
Submitted by: Jimmie James <jimmiejaz@gmail.com>
Diffstat (limited to 'x11-wm/xfce4-wm/files')
-rw-r--r-- | x11-wm/xfce4-wm/files/patch-client.c | 26 | ||||
-rw-r--r-- | x11-wm/xfce4-wm/files/patch-display.c | 40 | ||||
-rw-r--r-- | x11-wm/xfce4-wm/files/patch-display.h | 10 | ||||
-rw-r--r-- | x11-wm/xfce4-wm/files/patch-hint.c | 61 | ||||
-rw-r--r-- | x11-wm/xfce4-wm/files/patch-hint.h | 10 |
5 files changed, 147 insertions, 0 deletions
diff --git a/x11-wm/xfce4-wm/files/patch-client.c b/x11-wm/xfce4-wm/files/patch-client.c new file mode 100644 index 000000000000..337570fccaf1 --- /dev/null +++ b/x11-wm/xfce4-wm/files/patch-client.c @@ -0,0 +1,26 @@ +--- src/client.c.orig 2007-04-02 21:48:20.000000000 +0200 ++++ src/client.c 2007-10-25 22:26:36.000000000 +0200 +@@ -4868,21 +4868,19 @@ + + if (passdata.c) + { +- GdkPixbuf *icon; +- + TRACE ("entering cycle loop"); + passdata.wireframe = wireframeCreate (passdata.c); +- icon = getAppIcon (display_info, passdata.c->window, 32, 32); + passdata.tabwin = tabwinCreate (passdata.c->screen_info->gscr, c, + passdata.c, passdata.cycle_range, + screen_info->params->cycle_workspaces); + eventFilterPush (display_info->xfilter, clientCycleEventFilter, &passdata); + gtk_main (); + eventFilterPop (display_info->xfilter); +- wireframeDelete (screen_info, passdata.wireframe); + TRACE ("leaving cycle loop"); + tabwinDestroy (passdata.tabwin); + g_free (passdata.tabwin); ++ wireframeDelete (screen_info, passdata.wireframe); ++ updateXserverTime (display_info); + } + + if (passdata.c) diff --git a/x11-wm/xfce4-wm/files/patch-display.c b/x11-wm/xfce4-wm/files/patch-display.c new file mode 100644 index 000000000000..ccb01816167a --- /dev/null +++ b/x11-wm/xfce4-wm/files/patch-display.c @@ -0,0 +1,40 @@ +--- src/display.c.orig 2007-04-02 21:32:01.000000000 +0200 ++++ src/display.c 2007-10-25 22:26:36.000000000 +0200 +@@ -178,6 +178,19 @@ + FALSE, display_info->atoms) != 0); + } + ++static void ++myDisplayCreateTimestampWin (DisplayInfo *display_info) ++{ ++ XSetWindowAttributes attributes; ++ ++ attributes.event_mask = PropertyChangeMask; ++ attributes.override_redirect = TRUE; ++ display_info->timestamp_win = ++ XCreateWindow (display_info->dpy, DefaultRootWindow (display_info->dpy), ++ -100, -100, 10, 10, 0, 0, CopyFromParent, CopyFromParent, ++ CWEventMask | CWOverrideRedirect, &attributes); ++} ++ + DisplayInfo * + myDisplayInit (GdkDisplay *gdisplay) + { +@@ -309,6 +322,8 @@ + display->resize_cursor[CORNER_COUNT + SIDE_BOTTOM] = + XCreateFontCursor (display->dpy, XC_bottom_side); + ++ myDisplayCreateTimestampWin (display); ++ + display->xfilter = NULL; + display->screens = NULL; + display->clients = NULL; +@@ -340,6 +355,8 @@ + display->move_cursor = None; + XFreeCursor (display->dpy, display->root_cursor); + display->root_cursor = None; ++ XDestroyWindow (display->dpy, display->timestamp_win); ++ display->timestamp_win = None; + + if (display->hostname) + { diff --git a/x11-wm/xfce4-wm/files/patch-display.h b/x11-wm/xfce4-wm/files/patch-display.h new file mode 100644 index 000000000000..a893a3069628 --- /dev/null +++ b/x11-wm/xfce4-wm/files/patch-display.h @@ -0,0 +1,10 @@ +--- src/display.h.orig 2007-04-02 21:32:01.000000000 +0200 ++++ src/display.h 2007-10-25 22:26:36.000000000 +0200 +@@ -226,6 +226,7 @@ + gboolean quit; + gboolean reload; + ++ Window timestamp_win; + Cursor busy_cursor; + Cursor move_cursor; + Cursor root_cursor; diff --git a/x11-wm/xfce4-wm/files/patch-hint.c b/x11-wm/xfce4-wm/files/patch-hint.c new file mode 100644 index 000000000000..fbdc0ada8324 --- /dev/null +++ b/x11-wm/xfce4-wm/files/patch-hint.c @@ -0,0 +1,61 @@ +--- src/hints.c.orig 2007-03-11 14:44:43.000000000 +0100 ++++ src/hints.c 2007-10-25 22:26:36.000000000 +0200 +@@ -1167,27 +1167,18 @@ + return setXAtomManagerOwner(display_info, display_info->atoms[atom_id], root, w); + } + +- +-static Bool +-checkPropEvent (Display *display, XEvent *xevent, XPointer arg) ++void ++updateXserverTime (DisplayInfo *display_info) + { +- DisplayInfo *display_info; + ScreenInfo *screen_info; ++ char c = '\0'; + +- display_info = (DisplayInfo *) arg; +- g_return_val_if_fail (display_info, FALSE); +- +- screen_info = myDisplayGetDefaultScreen (display_info); +- g_return_val_if_fail (screen_info, FALSE); ++ g_return_if_fail (display_info); + +- if ((xevent->type == PropertyNotify) && +- (xevent->xproperty.window == screen_info->xfwm4_win) && +- (xevent->xproperty.atom == display_info->atoms[XFWM4_TIMESTAMP_PROP])) +- { +- return TRUE; +- } +- +- return FALSE; ++ XChangeProperty (display_info->dpy, display_info->timestamp_win, ++ display_info->atoms[XFWM4_TIMESTAMP_PROP], ++ display_info->atoms[XFWM4_TIMESTAMP_PROP], ++ 8, PropModeReplace, (unsigned char *) &c, 1); + } + + Time +@@ -1196,7 +1187,6 @@ + ScreenInfo *screen_info; + XEvent xevent; + Time timestamp; +- char c = '\0'; + + g_return_val_if_fail (display_info, (Time) CurrentTime); + timestamp = myDisplayGetCurrentTime (display_info); +@@ -1206,12 +1196,8 @@ + g_return_val_if_fail (screen_info, (Time) CurrentTime); + + TRACE ("getXServerTime: Using X server roundtrip"); +- XChangeProperty (display_info->dpy, screen_info->xfwm4_win, +- display_info->atoms[XFWM4_TIMESTAMP_PROP], +- display_info->atoms[XFWM4_TIMESTAMP_PROP], +- 8, PropModeReplace, (unsigned char *) &c, 1); +- XIfEvent (display_info->dpy, &xevent, checkPropEvent, (XPointer) display_info); +- ++ updateXserverTime (display_info); ++ XWindowEvent (display_info->dpy, display_info->timestamp_win, PropertyChangeMask, &xevent); + timestamp = (Time) myDisplayUpdateCurrentTime (display_info, &xevent); + } + diff --git a/x11-wm/xfce4-wm/files/patch-hint.h b/x11-wm/xfce4-wm/files/patch-hint.h new file mode 100644 index 000000000000..fd7931597545 --- /dev/null +++ b/x11-wm/xfce4-wm/files/patch-hint.h @@ -0,0 +1,10 @@ +--- src/hints.h.orig 2007-03-11 14:44:43.000000000 +0100 ++++ src/hints.h 2007-10-25 22:26:36.000000000 +0200 +@@ -269,6 +269,7 @@ + int, + Window , + Window); ++void updateXserverTime (DisplayInfo *); + Time getXServerTime (DisplayInfo *); + + #ifdef ENABLE_KDE_SYSTRAY_PROXY |