+2013-09-16 Dmitry Antipov <dmantipov@yandex.ru>
+
+ * xterm.c (toolkit_scroll_bar_interaction): Use bool for boolean.
+ (ignore_next_mouse_click_timeout): Use Time as X does.
+ (handle_one_xevent): Avoid cast and use unsigned comparison.
+
2013-09-16 Dmitry Antipov <dmantipov@yandex.ru>
Do not copy X event in handle_one_xevent except KeyPress case.
static struct frame *pending_autoraise_frame;
#ifdef USE_X_TOOLKIT
+
/* The application context for Xt use. */
XtAppContext Xt_app_con;
static String Xt_default_resources[] = {0};
/* Non-zero means user is interacting with a toolkit scroll bar. */
+static bool toolkit_scroll_bar_interaction;
-static int toolkit_scroll_bar_interaction;
#endif /* USE_X_TOOLKIT */
/* Non-zero timeout value means ignore next mouse click if it arrives
before that timeout elapses (i.e. as part of the same sequence of
events resulting from clicking on a frame to select it). */
-static unsigned long ignore_next_mouse_click_timeout;
+static Time ignore_next_mouse_click_timeout;
/* Mouse movement.
if (ignore_next_mouse_click_timeout)
{
if (event->type == ButtonPress
- && (int)(event->xbutton.time - ignore_next_mouse_click_timeout) > 0)
+ && event->xbutton.time > ignore_next_mouse_click_timeout)
{
ignore_next_mouse_click_timeout = 0;
construct_mouse_click (&inev.ie, &event->xbutton, f);