summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorChoe Hwanjin <choe.hwanjin@gmail.com>2011-10-13 07:58:02 +0900
committerJeremy Huddleston <jeremyhu@apple.com>2011-10-14 17:19:15 -0700
commit738f7b867341c1da87ee667d48815822715c3e75 (patch)
tree9d2fdcec62ec7a373aeb48121f79d8d015aabc6c /src
parent50e15379331c436851abb194251cde96999e67b3 (diff)
XIM: Make Xim handle NEED_SYNC_REPLY flag
NEED_SYNC_REPLY flag should be in Xim not in Xic. Because the focused Xic can be changed before sending sync reply. After focused Xic changed, the new Xic doesn't have NEED_SYNC_REPLY flag enabled, so libX11 doesn't send XIM_SYNC_REPLY packet. This patch adds sync reply flag to Xim and removes sync reply from Xic. Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=7869 Signed-off-by: Choe Hwanjin <choe.hwanjin@gmail.com> Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
Diffstat (limited to 'src')
-rw-r--r--src/xlibi18n/XimintP.h40
1 files changed, 16 insertions, 24 deletions
diff --git a/src/xlibi18n/XimintP.h b/src/xlibi18n/XimintP.h
index 0e384ab..14a7e6d 100644
--- a/src/xlibi18n/XimintP.h
+++ b/src/xlibi18n/XimintP.h
@@ -161,6 +161,8 @@ typedef struct _XimProtoPrivateRec {
#define DELAYBINDABLE (1L << 3)
#define RECONNECTABLE (1L << 4)
#endif /* XIM_CONNECTABLE */
+#define FABRICATED (1L << 5)
+#define NEED_SYNC_REPLY (1L << 6)
/*
* macro for the flag of XIMPrivateRec
@@ -199,6 +201,20 @@ typedef struct _XimProtoPrivateRec {
(((Xim)im)->private.proto.flag &= ~(DELAYBINDABLE|RECONNECTABLE))
#endif /* XIM_CONNECTABLE */
+#define IS_FABRICATED(im) \
+ (((Xim)im)->private.proto.flag & FABRICATED)
+#define MARK_FABRICATED(im) \
+ (((Xim)im)->private.proto.flag |= FABRICATED)
+#define UNMARK_FABRICATED(im) \
+ (((Xim)im)->private.proto.flag &= ~FABRICATED)
+
+#define IS_NEED_SYNC_REPLY(im) \
+ (((Xim)im)->private.proto.flag & NEED_SYNC_REPLY)
+#define MARK_NEED_SYNC_REPLY(im) \
+ (((Xim)im)->private.proto.flag |= NEED_SYNC_REPLY)
+#define UNMARK_NEED_SYNC_REPLY(im) \
+ (((Xim)im)->private.proto.flag &= ~NEED_SYNC_REPLY)
+
/*
* bit mask for the register_filter_event of XIMPrivateRec/XICPrivateRec
*/
@@ -259,9 +275,6 @@ typedef struct _XicProtoPrivateRec {
* bit mask for the flag of XICPrivateRec
*/
#define IC_CONNECTED (1L)
-#define FABLICATED (1L << 1)
-#define NEED_SYNC_REPLY (1L << 2)
-#define FOCUSED (1L << 3)
/*
* macro for the flag of XICPrivateRec
@@ -273,27 +286,6 @@ typedef struct _XicProtoPrivateRec {
#define UNMARK_IC_CONNECTED(ic) \
(((Xic)ic)->private.proto.flag &= ~IC_CONNECTED)
-#define IS_FABLICATED(ic) \
- (((Xic)ic)->private.proto.flag & FABLICATED)
-#define MARK_FABLICATED(ic) \
- (((Xic)ic)->private.proto.flag |= FABLICATED)
-#define UNMARK_FABLICATED(ic) \
- (((Xic)ic)->private.proto.flag &= ~FABLICATED)
-
-#define IS_NEED_SYNC_REPLY(ic) \
- (((Xic)ic)->private.proto.flag & NEED_SYNC_REPLY)
-#define MARK_NEED_SYNC_REPLY(ic) \
- (((Xic)ic)->private.proto.flag |= NEED_SYNC_REPLY)
-#define UNMARK_NEED_SYNC_REPLY(ic) \
- (((Xic)ic)->private.proto.flag &= ~NEED_SYNC_REPLY)
-
-#define IS_FOCUSED(ic) \
- (((Xic)ic)->private.proto.flag & FOCUSED)
-#define MARK_FOCUSED(ic) \
- (((Xic)ic)->private.proto.flag |= FOCUSED)
-#define UNMARK_FOCUSED(ic) \
- (((Xic)ic)->private.proto.flag &= ~FOCUSED)
-
/*
* macro for the filter_event_mask of XICPrivateRec
*/