diff options
| author | Paul Eggert | 2011-05-15 10:17:44 -0700 |
|---|---|---|
| committer | Paul Eggert | 2011-05-15 10:17:44 -0700 |
| commit | 067a69a2d38db30190997dc48dbf82988ffa3583 (patch) | |
| tree | f8ce54ac9c65d32d1349cb449485ed0ba1833d57 /src/xterm.c | |
| parent | 5e9e35cd1dd6e4fb47c6720991581508b89f87f7 (diff) | |
| parent | 9fbd68410f1680b5b9bc2d56c239183ea13c7d58 (diff) | |
| download | emacs-067a69a2d38db30190997dc48dbf82988ffa3583.tar.gz emacs-067a69a2d38db30190997dc48dbf82988ffa3583.zip | |
Merge: user-interface timestamps and other int overflow patches.
Diffstat (limited to 'src/xterm.c')
| -rw-r--r-- | src/xterm.c | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/src/xterm.c b/src/xterm.c index 2352f51cfb7..64030a3151d 100644 --- a/src/xterm.c +++ b/src/xterm.c | |||
| @@ -342,7 +342,7 @@ static struct scroll_bar *x_window_to_scroll_bar (Display *, Window); | |||
| 342 | static void x_scroll_bar_report_motion (struct frame **, Lisp_Object *, | 342 | static void x_scroll_bar_report_motion (struct frame **, Lisp_Object *, |
| 343 | enum scroll_bar_part *, | 343 | enum scroll_bar_part *, |
| 344 | Lisp_Object *, Lisp_Object *, | 344 | Lisp_Object *, Lisp_Object *, |
| 345 | unsigned long *); | 345 | Time *); |
| 346 | static void x_handle_net_wm_state (struct frame *, XPropertyEvent *); | 346 | static void x_handle_net_wm_state (struct frame *, XPropertyEvent *); |
| 347 | static void x_check_fullscreen (struct frame *); | 347 | static void x_check_fullscreen (struct frame *); |
| 348 | static void x_check_expected_move (struct frame *, int, int); | 348 | static void x_check_expected_move (struct frame *, int, int); |
| @@ -3637,23 +3637,23 @@ x_find_modifier_meanings (struct x_display_info *dpyinfo) | |||
| 3637 | /* Convert between the modifier bits X uses and the modifier bits | 3637 | /* Convert between the modifier bits X uses and the modifier bits |
| 3638 | Emacs uses. */ | 3638 | Emacs uses. */ |
| 3639 | 3639 | ||
| 3640 | unsigned int | 3640 | EMACS_INT |
| 3641 | x_x_to_emacs_modifiers (struct x_display_info *dpyinfo, unsigned int state) | 3641 | x_x_to_emacs_modifiers (struct x_display_info *dpyinfo, int state) |
| 3642 | { | 3642 | { |
| 3643 | EMACS_UINT mod_meta = meta_modifier; | 3643 | EMACS_INT mod_meta = meta_modifier; |
| 3644 | EMACS_UINT mod_alt = alt_modifier; | 3644 | EMACS_INT mod_alt = alt_modifier; |
| 3645 | EMACS_UINT mod_hyper = hyper_modifier; | 3645 | EMACS_INT mod_hyper = hyper_modifier; |
| 3646 | EMACS_UINT mod_super = super_modifier; | 3646 | EMACS_INT mod_super = super_modifier; |
| 3647 | Lisp_Object tem; | 3647 | Lisp_Object tem; |
| 3648 | 3648 | ||
| 3649 | tem = Fget (Vx_alt_keysym, Qmodifier_value); | 3649 | tem = Fget (Vx_alt_keysym, Qmodifier_value); |
| 3650 | if (! EQ (tem, Qnil)) mod_alt = XUINT (tem); | 3650 | if (INTEGERP (tem)) mod_alt = XINT (tem); |
| 3651 | tem = Fget (Vx_meta_keysym, Qmodifier_value); | 3651 | tem = Fget (Vx_meta_keysym, Qmodifier_value); |
| 3652 | if (! EQ (tem, Qnil)) mod_meta = XUINT (tem); | 3652 | if (INTEGERP (tem)) mod_meta = XINT (tem); |
| 3653 | tem = Fget (Vx_hyper_keysym, Qmodifier_value); | 3653 | tem = Fget (Vx_hyper_keysym, Qmodifier_value); |
| 3654 | if (! EQ (tem, Qnil)) mod_hyper = XUINT (tem); | 3654 | if (INTEGERP (tem)) mod_hyper = XINT (tem); |
| 3655 | tem = Fget (Vx_super_keysym, Qmodifier_value); | 3655 | tem = Fget (Vx_super_keysym, Qmodifier_value); |
| 3656 | if (! EQ (tem, Qnil)) mod_super = XUINT (tem); | 3656 | if (INTEGERP (tem)) mod_super = XINT (tem); |
| 3657 | 3657 | ||
| 3658 | 3658 | ||
| 3659 | return ( ((state & (ShiftMask | dpyinfo->shift_lock_mask)) ? shift_modifier : 0) | 3659 | return ( ((state & (ShiftMask | dpyinfo->shift_lock_mask)) ? shift_modifier : 0) |
| @@ -3664,24 +3664,24 @@ x_x_to_emacs_modifiers (struct x_display_info *dpyinfo, unsigned int state) | |||
| 3664 | | ((state & dpyinfo->hyper_mod_mask) ? mod_hyper : 0)); | 3664 | | ((state & dpyinfo->hyper_mod_mask) ? mod_hyper : 0)); |
| 3665 | } | 3665 | } |
| 3666 | 3666 | ||
| 3667 | static unsigned int | 3667 | static int |
| 3668 | x_emacs_to_x_modifiers (struct x_display_info *dpyinfo, unsigned int state) | 3668 | x_emacs_to_x_modifiers (struct x_display_info *dpyinfo, EMACS_INT state) |
| 3669 | { | 3669 | { |
| 3670 | EMACS_UINT mod_meta = meta_modifier; | 3670 | int mod_meta = meta_modifier; |
| 3671 | EMACS_UINT mod_alt = alt_modifier; | 3671 | int mod_alt = alt_modifier; |
| 3672 | EMACS_UINT mod_hyper = hyper_modifier; | 3672 | int mod_hyper = hyper_modifier; |
| 3673 | EMACS_UINT mod_super = super_modifier; | 3673 | int mod_super = super_modifier; |
| 3674 | 3674 | ||
| 3675 | Lisp_Object tem; | 3675 | Lisp_Object tem; |
| 3676 | 3676 | ||
| 3677 | tem = Fget (Vx_alt_keysym, Qmodifier_value); | 3677 | tem = Fget (Vx_alt_keysym, Qmodifier_value); |
| 3678 | if (! EQ (tem, Qnil)) mod_alt = XUINT (tem); | 3678 | if (INTEGERP (tem)) mod_alt = XINT (tem); |
| 3679 | tem = Fget (Vx_meta_keysym, Qmodifier_value); | 3679 | tem = Fget (Vx_meta_keysym, Qmodifier_value); |
| 3680 | if (! EQ (tem, Qnil)) mod_meta = XUINT (tem); | 3680 | if (INTEGERP (tem)) mod_meta = XINT (tem); |
| 3681 | tem = Fget (Vx_hyper_keysym, Qmodifier_value); | 3681 | tem = Fget (Vx_hyper_keysym, Qmodifier_value); |
| 3682 | if (! EQ (tem, Qnil)) mod_hyper = XUINT (tem); | 3682 | if (INTEGERP (tem)) mod_hyper = XINT (tem); |
| 3683 | tem = Fget (Vx_super_keysym, Qmodifier_value); | 3683 | tem = Fget (Vx_super_keysym, Qmodifier_value); |
| 3684 | if (! EQ (tem, Qnil)) mod_super = XUINT (tem); | 3684 | if (INTEGERP (tem)) mod_super = XINT (tem); |
| 3685 | 3685 | ||
| 3686 | 3686 | ||
| 3687 | return ( ((state & mod_alt) ? dpyinfo->alt_mod_mask : 0) | 3687 | return ( ((state & mod_alt) ? dpyinfo->alt_mod_mask : 0) |
| @@ -3827,7 +3827,7 @@ redo_mouse_highlight (void) | |||
| 3827 | static void | 3827 | static void |
| 3828 | XTmouse_position (FRAME_PTR *fp, int insist, Lisp_Object *bar_window, | 3828 | XTmouse_position (FRAME_PTR *fp, int insist, Lisp_Object *bar_window, |
| 3829 | enum scroll_bar_part *part, Lisp_Object *x, Lisp_Object *y, | 3829 | enum scroll_bar_part *part, Lisp_Object *x, Lisp_Object *y, |
| 3830 | long unsigned int *timestamp) | 3830 | Time *timestamp) |
| 3831 | { | 3831 | { |
| 3832 | FRAME_PTR f1; | 3832 | FRAME_PTR f1; |
| 3833 | 3833 | ||
| @@ -5562,7 +5562,7 @@ x_scroll_bar_note_movement (struct scroll_bar *bar, XEvent *event) | |||
| 5562 | static void | 5562 | static void |
| 5563 | x_scroll_bar_report_motion (FRAME_PTR *fp, Lisp_Object *bar_window, | 5563 | x_scroll_bar_report_motion (FRAME_PTR *fp, Lisp_Object *bar_window, |
| 5564 | enum scroll_bar_part *part, Lisp_Object *x, | 5564 | enum scroll_bar_part *part, Lisp_Object *x, |
| 5565 | Lisp_Object *y, long unsigned int *timestamp) | 5565 | Lisp_Object *y, Time *timestamp) |
| 5566 | { | 5566 | { |
| 5567 | struct scroll_bar *bar = XSCROLL_BAR (last_mouse_scroll_bar); | 5567 | struct scroll_bar *bar = XSCROLL_BAR (last_mouse_scroll_bar); |
| 5568 | Window w = bar->x_window; | 5568 | Window w = bar->x_window; |