summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJon Turney <jon.turney@dronecode.org.uk>2014-05-08 11:40:39 +0100
committerAdam Jackson <ajax@redhat.com>2016-02-29 14:04:19 -0500
commita9e73131b6453e0fa2da5360e84af7a2eae3b205 (patch)
treebf9ad9e9766a27c854c0e2558e4676d63b2198c3
parentd7cef6fbe23381b31c163468f349feee2f1b1eba (diff)
xwin: Correctly interpret WM_HINTS, WM_NORMAL_HINTS properties on x86_64
Signed-off-by: Jon Turney <jon.turney@dronecode.org.uk> Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
-rw-r--r--hw/xwin/winmultiwindowclass.h28
1 files changed, 20 insertions, 8 deletions
diff --git a/hw/xwin/winmultiwindowclass.h b/hw/xwin/winmultiwindowclass.h
index 3244f78e3..37ee9fb13 100644
--- a/hw/xwin/winmultiwindowclass.h
+++ b/hw/xwin/winmultiwindowclass.h
@@ -31,11 +31,24 @@
*/
/*
+ * The next block of definitions are for window manager properties that
+ * clients and applications use for communication.
+ */
+
+/*
* Structures
*/
+/*
+ * WM_HINTS structure
+ *
+ * NOTE: this structure represents the internal format stored in the property
+ * after it is marshalled by libX11, converting the flags field from an
+ * arch-dependent long to a 32-bit int.
+ */
+
typedef struct {
- long flags; /* marks which fields in this structure are defined */
+ int flags; /* marks which fields in this structure are defined */
Bool input; /* does this application rely on the window manager to
get keyboard input? */
int initial_state; /* see below */
@@ -59,11 +72,15 @@ typedef struct {
#define AllHints (InputHint|StateHint|IconPixmapHint|IconWindowHint|IconPositionHint|IconMaskHint|WindowGroupHint)
/*
- * new version containing base_width, base_height, and win_gravity fields;
+ * ICCCM 1.0 version containing base_width, base_height, and win_gravity fields;
* used with WM_NORMAL_HINTS.
+ *
+ * NOTE: this structure represents the internal format stored in the property
+ * after it is marshalled by libX11, converting the flags field from an
+ * arch-dependent long to a 32-bit int.
*/
typedef struct {
- long flags; /* marks which fields in this structure are defined */
+ int flags; /* marks which fields in this structure are defined */
int x, y; /* obsolete for new window mgrs, but clients */
int width, height; /* should set so old wm's don't mess up */
int min_width, min_height;
@@ -77,11 +94,6 @@ typedef struct {
int win_gravity; /* added by ICCCM version 1 */
} WinXSizeHints;
-/*
- * The next block of definitions are for window manager properties that
- * clients and applications use for communication.
- */
-
/* flags argument in size hints */
#define USPosition (1L << 0) /* user specified x, y */
#define USSize (1L << 1) /* user specified width, height */