aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoakim Verona2013-09-16 13:35:45 +0200
committerJoakim Verona2013-09-16 13:35:45 +0200
commit2f3ee26f12984352f2777cd51a00eceec196fd4c (patch)
treeb813a05b6b9acec8c1f49fda2271590e8cf8ff53
parent2676aa6d82f3b92f060daa088cffbfdb4c56904d (diff)
parent83a119f8d892a790b25bd0d856df82fb25b0ba72 (diff)
downloademacs-2f3ee26f12984352f2777cd51a00eceec196fd4c.tar.gz
emacs-2f3ee26f12984352f2777cd51a00eceec196fd4c.zip
merge from trunk
-rw-r--r--src/ChangeLog6
-rw-r--r--src/xterm.c7
2 files changed, 10 insertions, 3 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 4b862f27a02..d53f1414917 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,5 +1,11 @@
12013-09-16 Dmitry Antipov <dmantipov@yandex.ru> 12013-09-16 Dmitry Antipov <dmantipov@yandex.ru>
2 2
3 * xterm.c (toolkit_scroll_bar_interaction): Use bool for boolean.
4 (ignore_next_mouse_click_timeout): Use Time as X does.
5 (handle_one_xevent): Avoid cast and use unsigned comparison.
6
72013-09-16 Dmitry Antipov <dmantipov@yandex.ru>
8
3 Do not copy X event in handle_one_xevent except KeyPress case. 9 Do not copy X event in handle_one_xevent except KeyPress case.
4 Wnen XEvent is processed, it is unlikely to be changed except 10 Wnen XEvent is processed, it is unlikely to be changed except
5 KeyPress case, so we can avoid copying and use const pointer to 11 KeyPress case, so we can avoid copying and use const pointer to
diff --git a/src/xterm.c b/src/xterm.c
index c548443157d..6322ed0840d 100644
--- a/src/xterm.c
+++ b/src/xterm.c
@@ -163,20 +163,21 @@ Lisp_Object x_display_name_list;
163static struct frame *pending_autoraise_frame; 163static struct frame *pending_autoraise_frame;
164 164
165#ifdef USE_X_TOOLKIT 165#ifdef USE_X_TOOLKIT
166
166/* The application context for Xt use. */ 167/* The application context for Xt use. */
167XtAppContext Xt_app_con; 168XtAppContext Xt_app_con;
168static String Xt_default_resources[] = {0}; 169static String Xt_default_resources[] = {0};
169 170
170/* Non-zero means user is interacting with a toolkit scroll bar. */ 171/* Non-zero means user is interacting with a toolkit scroll bar. */
172static bool toolkit_scroll_bar_interaction;
171 173
172static int toolkit_scroll_bar_interaction;
173#endif /* USE_X_TOOLKIT */ 174#endif /* USE_X_TOOLKIT */
174 175
175/* Non-zero timeout value means ignore next mouse click if it arrives 176/* Non-zero timeout value means ignore next mouse click if it arrives
176 before that timeout elapses (i.e. as part of the same sequence of 177 before that timeout elapses (i.e. as part of the same sequence of
177 events resulting from clicking on a frame to select it). */ 178 events resulting from clicking on a frame to select it). */
178 179
179static unsigned long ignore_next_mouse_click_timeout; 180static Time ignore_next_mouse_click_timeout;
180 181
181/* Mouse movement. 182/* Mouse movement.
182 183
@@ -6902,7 +6903,7 @@ handle_one_xevent (struct x_display_info *dpyinfo,
6902 if (ignore_next_mouse_click_timeout) 6903 if (ignore_next_mouse_click_timeout)
6903 { 6904 {
6904 if (event->type == ButtonPress 6905 if (event->type == ButtonPress
6905 && (int)(event->xbutton.time - ignore_next_mouse_click_timeout) > 0) 6906 && event->xbutton.time > ignore_next_mouse_click_timeout)
6906 { 6907 {
6907 ignore_next_mouse_click_timeout = 0; 6908 ignore_next_mouse_click_timeout = 0;
6908 construct_mouse_click (&inev.ie, &event->xbutton, f); 6909 construct_mouse_click (&inev.ie, &event->xbutton, f);