[gtk+/gtk-2-24] Fix problems with sticky handling (backport of 01320e57737).
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/gtk-2-24] Fix problems with sticky handling (backport of 01320e57737).
- Date: Thu, 12 Mar 2015 21:31:03 +0000 (UTC)
commit ba48b465741ce49518e51942983832a96288d896
Author: John Lindgren <john lindgren aol com>
Date: Wed Mar 11 22:12:38 2015 -0400
Fix problems with sticky handling (backport of 01320e57737).
Reading a card32 property into a long may lead to undefined high bits, so mask
them off. Also, make the conditions for setting and unsetting the stick flag
opposites, to avoid unintended changes.
https://bugzilla.gnome.org/show_bug.cgi?id=746064
gdk/x11/gdkevents-x11.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/gdk/x11/gdkevents-x11.c b/gdk/x11/gdkevents-x11.c
index 07c24b0..186a8f5 100644
--- a/gdk/x11/gdkevents-x11.c
+++ b/gdk/x11/gdkevents-x11.c
@@ -462,7 +462,7 @@ do_net_wm_state_changes (GdkWindow *window)
}
else
{
- if (toplevel->have_sticky || toplevel->on_all_desktops)
+ if (toplevel->have_sticky && toplevel->on_all_desktops)
gdk_synthesize_window_state (window,
0,
GDK_WINDOW_STATE_STICKY);
@@ -543,7 +543,7 @@ gdk_check_wm_desktop_changed (GdkWindow *window)
if (type != None)
{
desktop = (gulong *)data;
- toplevel->on_all_desktops = (*desktop == 0xFFFFFFFF);
+ toplevel->on_all_desktops = ((*desktop & 0xFFFFFFFF) == 0xFFFFFFFF);
XFree (desktop);
}
else
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]