aboutsummaryrefslogtreecommitdiffstats
path: root/src/xterm.c
diff options
context:
space:
mode:
authorJan Djärv <[email protected]>2002-03-10 16:15:20 +0000
committerJan Djärv <[email protected]>2002-03-10 16:15:20 +0000
commit5f30b9577a64efb90b13e18cc158dd06eae8612c (patch)
treef6d2cb779057a9fc81a2ccdcf2a559bdf462c9b1 /src/xterm.c
parent3cf9b89ee6287a30a762f6c448ef66d6bcf8ffbb (diff)
Added calls to x_session_check_input () and x_session_initialize ().
Diffstat (limited to 'src/xterm.c')
-rw-r--r--src/xterm.c20
1 files changed, 18 insertions, 2 deletions
diff --git a/src/xterm.c b/src/xterm.c
index 58a60b5914..41331326ad 100644
--- a/src/xterm.c
+++ b/src/xterm.c
@@ -10032,6 +10032,12 @@ XTread_socket (sd, bufp, numchars, expected)
x_io_error_quitter (dpyinfo->display);
}
+#ifdef HAVE_X_SM
+ BLOCK_INPUT;
+ count += x_session_check_input (bufp, &numchars);
+ UNBLOCK_INPUT;
+#endif
+
while (XPending (dpyinfo->display))
{
XNextEvent (dpyinfo->display, &event);
@@ -10114,11 +10120,17 @@ XTread_socket (sd, bufp, numchars, expected)
the session manager, who's looking for such a
PropertyNotify. Can restart processing when
a keyboard or mouse event arrives. */
- if (numchars > 0)
+ /* If we have a session manager, don't set this.
+ KDE will then start two Emacsen, one for the
+ session manager and one for this. */
+ if (numchars > 0
+#ifdef HAVE_X_SM
+ && ! x_session_have_connection ()
+#endif
+ )
{
f = x_top_window_to_frame (dpyinfo,
event.xclient.window);
-
/* This is just so we only give real data once
for a single Emacs process. */
if (f == SELECTED_FRAME ())
@@ -15056,6 +15068,10 @@ x_initialize ()
#endif /* ! defined (SIGWINCH) */
signal (SIGPIPE, x_connection_signal);
+
+#ifdef HAVE_X_SM
+ x_session_initialize ();
+#endif
}