diff options
| author | Alexander Gramiak | 2019-04-11 09:00:58 -0600 |
|---|---|---|
| committer | Alexander Gramiak | 2019-04-26 16:10:49 -0600 |
| commit | da9541dd1086b7bab52940c82915efe114bb7419 (patch) | |
| tree | 24c279c12ad07586d77b30f410ce0ea1a38adcf6 /src | |
| parent | ff4e31fa328a2cee5197beb20f068eb021712b5c (diff) | |
| download | emacs-da9541dd1086b7bab52940c82915efe114bb7419.tar.gz emacs-da9541dd1086b7bab52940c82915efe114bb7419.zip | |
Add prefixes to some window system-dependent procedures
* src/nsterm.m (note_mouse_movement):
* src/w32fns.c (construct_console_modifiers):
* src/w32inevt.c:
* src/w32term.c (frame_highlight, frame_unhighlight)
(construct_mouse_click, construct_mouse_wheel, construct_drag_n_drop)
(lispy_file_action, queue_notifications, note_mouse_movement):
* src/w32term.h:
* src/xterm.c (frame_highlight, frame_unhighlight)
(construct_mouse_click, note_mouse_movement, get_current_wm_state):
Add and use window system prefixes.
Diffstat (limited to 'src')
| -rw-r--r-- | src/nsterm.m | 6 | ||||
| -rw-r--r-- | src/w32fns.c | 8 | ||||
| -rw-r--r-- | src/w32inevt.c | 2 | ||||
| -rw-r--r-- | src/w32term.c | 43 | ||||
| -rw-r--r-- | src/w32term.h | 2 | ||||
| -rw-r--r-- | src/xterm.c | 42 |
6 files changed, 53 insertions, 50 deletions
diff --git a/src/nsterm.m b/src/nsterm.m index 15316e23edc..62fb4b2e216 100644 --- a/src/nsterm.m +++ b/src/nsterm.m | |||
| @@ -2467,7 +2467,7 @@ frame_set_mouse_pixel_position (struct frame *f, int pix_x, int pix_y) | |||
| 2467 | } | 2467 | } |
| 2468 | 2468 | ||
| 2469 | static int | 2469 | static int |
| 2470 | note_mouse_movement (struct frame *frame, CGFloat x, CGFloat y) | 2470 | ns_note_mouse_movement (struct frame *frame, CGFloat x, CGFloat y) |
| 2471 | /* ------------------------------------------------------------------------ | 2471 | /* ------------------------------------------------------------------------ |
| 2472 | Called by EmacsView on mouseMovement events. Passes on | 2472 | Called by EmacsView on mouseMovement events. Passes on |
| 2473 | to emacs mainstream code if we moved off of a rect of interest | 2473 | to emacs mainstream code if we moved off of a rect of interest |
| @@ -6890,7 +6890,7 @@ not_in_argv (NSString *arg) | |||
| 6890 | last_mouse_window = window; | 6890 | last_mouse_window = window; |
| 6891 | } | 6891 | } |
| 6892 | 6892 | ||
| 6893 | if (!note_mouse_movement (emacsframe, pt.x, pt.y)) | 6893 | if (!ns_note_mouse_movement (emacsframe, pt.x, pt.y)) |
| 6894 | help_echo_string = previous_help_echo_string; | 6894 | help_echo_string = previous_help_echo_string; |
| 6895 | 6895 | ||
| 6896 | XSETFRAME (frame, emacsframe); | 6896 | XSETFRAME (frame, emacsframe); |
| @@ -6898,7 +6898,7 @@ not_in_argv (NSString *arg) | |||
| 6898 | { | 6898 | { |
| 6899 | /* NOTE: help_echo_{window,pos,object} are set in xdisp.c | 6899 | /* NOTE: help_echo_{window,pos,object} are set in xdisp.c |
| 6900 | (note_mouse_highlight), which is called through the | 6900 | (note_mouse_highlight), which is called through the |
| 6901 | note_mouse_movement () call above. */ | 6901 | ns_note_mouse_movement () call above. */ |
| 6902 | any_help_event_p = YES; | 6902 | any_help_event_p = YES; |
| 6903 | gen_help_event (help_echo_string, frame, help_echo_window, | 6903 | gen_help_event (help_echo_string, frame, help_echo_window, |
| 6904 | help_echo_object, help_echo_pos); | 6904 | help_echo_object, help_echo_pos); |
diff --git a/src/w32fns.c b/src/w32fns.c index 814998f5f2f..e6cb1ee311c 100644 --- a/src/w32fns.c +++ b/src/w32fns.c | |||
| @@ -3061,7 +3061,7 @@ w32_get_modifiers (void) | |||
| 3061 | and window input. */ | 3061 | and window input. */ |
| 3062 | 3062 | ||
| 3063 | static int | 3063 | static int |
| 3064 | construct_console_modifiers (void) | 3064 | w32_construct_console_modifiers (void) |
| 3065 | { | 3065 | { |
| 3066 | int mods; | 3066 | int mods; |
| 3067 | 3067 | ||
| @@ -3087,7 +3087,7 @@ w32_get_key_modifiers (unsigned int wparam, unsigned int lparam) | |||
| 3087 | int mods; | 3087 | int mods; |
| 3088 | 3088 | ||
| 3089 | /* Convert to emacs modifiers. */ | 3089 | /* Convert to emacs modifiers. */ |
| 3090 | mods = w32_kbd_mods_to_emacs (construct_console_modifiers (), wparam); | 3090 | mods = w32_kbd_mods_to_emacs (w32_construct_console_modifiers (), wparam); |
| 3091 | 3091 | ||
| 3092 | return mods; | 3092 | return mods; |
| 3093 | } | 3093 | } |
| @@ -3719,7 +3719,7 @@ deliver_wm_chars (int do_translate, HWND hwnd, UINT msg, UINT wParam, | |||
| 3719 | if (count) | 3719 | if (count) |
| 3720 | { | 3720 | { |
| 3721 | W32Msg wmsg; | 3721 | W32Msg wmsg; |
| 3722 | DWORD console_modifiers = construct_console_modifiers (); | 3722 | DWORD console_modifiers = w32_construct_console_modifiers (); |
| 3723 | int *b = buf, strip_ExtraMods = 1, hairy = 0; | 3723 | int *b = buf, strip_ExtraMods = 1, hairy = 0; |
| 3724 | const char *type_CtrlAlt = NULL; | 3724 | const char *type_CtrlAlt = NULL; |
| 3725 | 3725 | ||
| @@ -4351,7 +4351,7 @@ w32_wnd_proc (HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) | |||
| 4351 | /* If not defined as a function key, change it to a WM_CHAR message. */ | 4351 | /* If not defined as a function key, change it to a WM_CHAR message. */ |
| 4352 | if (wParam > 255 || !lispy_function_keys[wParam]) | 4352 | if (wParam > 255 || !lispy_function_keys[wParam]) |
| 4353 | { | 4353 | { |
| 4354 | DWORD modifiers = construct_console_modifiers (); | 4354 | DWORD modifiers = w32_construct_console_modifiers (); |
| 4355 | 4355 | ||
| 4356 | if (!NILP (Vw32_recognize_altgr) | 4356 | if (!NILP (Vw32_recognize_altgr) |
| 4357 | && modifier_set (VK_LCONTROL) && modifier_set (VK_RMENU)) | 4357 | && modifier_set (VK_LCONTROL) && modifier_set (VK_RMENU)) |
diff --git a/src/w32inevt.c b/src/w32inevt.c index ab71c560d69..fc1f90cd025 100644 --- a/src/w32inevt.c +++ b/src/w32inevt.c | |||
| @@ -680,7 +680,7 @@ handle_file_notifications (struct input_event *hold_quit) | |||
| 680 | already be defined at this point. */ | 680 | already be defined at this point. */ |
| 681 | Lisp_Object fname | 681 | Lisp_Object fname |
| 682 | = code_convert_string_norecord (utf_16_fn, cs, 0); | 682 | = code_convert_string_norecord (utf_16_fn, cs, 0); |
| 683 | Lisp_Object action = lispy_file_action (fni->Action); | 683 | Lisp_Object action = w32_lispy_file_action (fni->Action); |
| 684 | 684 | ||
| 685 | inev.kind = FILE_NOTIFY_EVENT; | 685 | inev.kind = FILE_NOTIFY_EVENT; |
| 686 | inev.timestamp = GetTickCount (); | 686 | inev.timestamp = GetTickCount (); |
diff --git a/src/w32term.c b/src/w32term.c index a43d43c5583..edcdc56a9ea 100644 --- a/src/w32term.c +++ b/src/w32term.c | |||
| @@ -180,8 +180,8 @@ static void w32_initialize (void); | |||
| 180 | static void x_update_end (struct frame *); | 180 | static void x_update_end (struct frame *); |
| 181 | static void w32_frame_up_to_date (struct frame *); | 181 | static void w32_frame_up_to_date (struct frame *); |
| 182 | static void x_clear_frame (struct frame *); | 182 | static void x_clear_frame (struct frame *); |
| 183 | static void frame_highlight (struct frame *); | 183 | static void w32_frame_highlight (struct frame *); |
| 184 | static void frame_unhighlight (struct frame *); | 184 | static void w32_frame_unhighlight (struct frame *); |
| 185 | static void x_new_focus_frame (struct w32_display_info *, | 185 | static void x_new_focus_frame (struct w32_display_info *, |
| 186 | struct frame *); | 186 | struct frame *); |
| 187 | static void x_focus_changed (int, int, struct w32_display_info *, | 187 | static void x_focus_changed (int, int, struct w32_display_info *, |
| @@ -2904,14 +2904,14 @@ x_scroll_run (struct window *w, struct run *run) | |||
| 2904 | ***********************************************************************/ | 2904 | ***********************************************************************/ |
| 2905 | 2905 | ||
| 2906 | static void | 2906 | static void |
| 2907 | frame_highlight (struct frame *f) | 2907 | w32_frame_highlight (struct frame *f) |
| 2908 | { | 2908 | { |
| 2909 | gui_update_cursor (f, 1); | 2909 | gui_update_cursor (f, 1); |
| 2910 | x_set_frame_alpha (f); | 2910 | x_set_frame_alpha (f); |
| 2911 | } | 2911 | } |
| 2912 | 2912 | ||
| 2913 | static void | 2913 | static void |
| 2914 | frame_unhighlight (struct frame *f) | 2914 | w32_frame_unhighlight (struct frame *f) |
| 2915 | { | 2915 | { |
| 2916 | gui_update_cursor (f, 1); | 2916 | gui_update_cursor (f, 1); |
| 2917 | x_set_frame_alpha (f); | 2917 | x_set_frame_alpha (f); |
| @@ -3059,9 +3059,9 @@ x_frame_rehighlight (struct w32_display_info *dpyinfo) | |||
| 3059 | if (dpyinfo->x_highlight_frame != old_highlight) | 3059 | if (dpyinfo->x_highlight_frame != old_highlight) |
| 3060 | { | 3060 | { |
| 3061 | if (old_highlight) | 3061 | if (old_highlight) |
| 3062 | frame_unhighlight (old_highlight); | 3062 | w32_frame_unhighlight (old_highlight); |
| 3063 | if (dpyinfo->x_highlight_frame) | 3063 | if (dpyinfo->x_highlight_frame) |
| 3064 | frame_highlight (dpyinfo->x_highlight_frame); | 3064 | w32_frame_highlight (dpyinfo->x_highlight_frame); |
| 3065 | } | 3065 | } |
| 3066 | } | 3066 | } |
| 3067 | 3067 | ||
| @@ -3168,7 +3168,8 @@ parse_button (int message, int xbutton, int * pbutton, int * pup) | |||
| 3168 | the mouse. */ | 3168 | the mouse. */ |
| 3169 | 3169 | ||
| 3170 | static Lisp_Object | 3170 | static Lisp_Object |
| 3171 | construct_mouse_click (struct input_event *result, W32Msg *msg, struct frame *f) | 3171 | w32_construct_mouse_click (struct input_event *result, W32Msg *msg, |
| 3172 | struct frame *f) | ||
| 3172 | { | 3173 | { |
| 3173 | int button = 0; | 3174 | int button = 0; |
| 3174 | int up = 0; | 3175 | int up = 0; |
| @@ -3194,7 +3195,8 @@ construct_mouse_click (struct input_event *result, W32Msg *msg, struct frame *f) | |||
| 3194 | } | 3195 | } |
| 3195 | 3196 | ||
| 3196 | static Lisp_Object | 3197 | static Lisp_Object |
| 3197 | construct_mouse_wheel (struct input_event *result, W32Msg *msg, struct frame *f) | 3198 | w32_construct_mouse_wheel (struct input_event *result, W32Msg *msg, |
| 3199 | struct frame *f) | ||
| 3198 | { | 3200 | { |
| 3199 | POINT p; | 3201 | POINT p; |
| 3200 | int delta; | 3202 | int delta; |
| @@ -3228,7 +3230,8 @@ construct_mouse_wheel (struct input_event *result, W32Msg *msg, struct frame *f) | |||
| 3228 | } | 3230 | } |
| 3229 | 3231 | ||
| 3230 | static Lisp_Object | 3232 | static Lisp_Object |
| 3231 | construct_drag_n_drop (struct input_event *result, W32Msg *msg, struct frame *f) | 3233 | w32_construct_drag_n_drop (struct input_event *result, W32Msg *msg, |
| 3234 | struct frame *f) | ||
| 3232 | { | 3235 | { |
| 3233 | Lisp_Object files; | 3236 | Lisp_Object files; |
| 3234 | Lisp_Object frame; | 3237 | Lisp_Object frame; |
| @@ -3307,7 +3310,7 @@ construct_drag_n_drop (struct input_event *result, W32Msg *msg, struct frame *f) | |||
| 3307 | /* File event notifications (see w32notify.c). */ | 3310 | /* File event notifications (see w32notify.c). */ |
| 3308 | 3311 | ||
| 3309 | Lisp_Object | 3312 | Lisp_Object |
| 3310 | lispy_file_action (DWORD action) | 3313 | w32_lispy_file_action (DWORD action) |
| 3311 | { | 3314 | { |
| 3312 | static char unknown_fmt[] = "unknown-action(%d)"; | 3315 | static char unknown_fmt[] = "unknown-action(%d)"; |
| 3313 | Lisp_Object retval; | 3316 | Lisp_Object retval; |
| @@ -3347,8 +3350,8 @@ lispy_file_action (DWORD action) | |||
| 3347 | function runs when the WM_EMACS_FILENOTIFY message arrives from a | 3350 | function runs when the WM_EMACS_FILENOTIFY message arrives from a |
| 3348 | watcher thread. */ | 3351 | watcher thread. */ |
| 3349 | static void | 3352 | static void |
| 3350 | queue_notifications (struct input_event *event, W32Msg *msg, struct frame *f, | 3353 | w32_queue_notifications (struct input_event *event, W32Msg *msg, |
| 3351 | int *evcount) | 3354 | struct frame *f, int *evcount) |
| 3352 | { | 3355 | { |
| 3353 | struct notifications_set *ns = NULL; | 3356 | struct notifications_set *ns = NULL; |
| 3354 | Lisp_Object frame; | 3357 | Lisp_Object frame; |
| @@ -3407,7 +3410,7 @@ queue_notifications (struct input_event *event, W32Msg *msg, struct frame *f, | |||
| 3407 | already be defined at this point. */ | 3410 | already be defined at this point. */ |
| 3408 | Lisp_Object fname | 3411 | Lisp_Object fname |
| 3409 | = code_convert_string_norecord (utf_16_fn, cs, 0); | 3412 | = code_convert_string_norecord (utf_16_fn, cs, 0); |
| 3410 | Lisp_Object action = lispy_file_action (fni->Action); | 3413 | Lisp_Object action = w32_lispy_file_action (fni->Action); |
| 3411 | 3414 | ||
| 3412 | event->kind = FILE_NOTIFY_EVENT; | 3415 | event->kind = FILE_NOTIFY_EVENT; |
| 3413 | event->timestamp = msg->msg.time; | 3416 | event->timestamp = msg->msg.time; |
| @@ -3445,7 +3448,7 @@ queue_notifications (struct input_event *event, W32Msg *msg, struct frame *f, | |||
| 3445 | another motion event, so we can check again the next time it moves. */ | 3448 | another motion event, so we can check again the next time it moves. */ |
| 3446 | 3449 | ||
| 3447 | static int | 3450 | static int |
| 3448 | note_mouse_movement (struct frame *frame, MSG *msg) | 3451 | w32_note_mouse_movement (struct frame *frame, MSG *msg) |
| 3449 | { | 3452 | { |
| 3450 | struct w32_display_info *dpyinfo; | 3453 | struct w32_display_info *dpyinfo; |
| 3451 | int mouse_x = LOWORD (msg->lParam); | 3454 | int mouse_x = LOWORD (msg->lParam); |
| @@ -5020,7 +5023,7 @@ w32_read_socket (struct terminal *terminal, | |||
| 5020 | last_mouse_window = window; | 5023 | last_mouse_window = window; |
| 5021 | } | 5024 | } |
| 5022 | 5025 | ||
| 5023 | if (!note_mouse_movement (f, &msg.msg)) | 5026 | if (!w32_note_mouse_movement (f, &msg.msg)) |
| 5024 | help_echo_string = previous_help_echo_string; | 5027 | help_echo_string = previous_help_echo_string; |
| 5025 | } | 5028 | } |
| 5026 | else | 5029 | else |
| @@ -5064,7 +5067,7 @@ w32_read_socket (struct terminal *terminal, | |||
| 5064 | 5067 | ||
| 5065 | if (f) | 5068 | if (f) |
| 5066 | { | 5069 | { |
| 5067 | construct_mouse_click (&inev, &msg, f); | 5070 | w32_construct_mouse_click (&inev, &msg, f); |
| 5068 | 5071 | ||
| 5069 | /* Is this in the tool-bar? */ | 5072 | /* Is this in the tool-bar? */ |
| 5070 | if (WINDOWP (f->tool_bar_window) | 5073 | if (WINDOWP (f->tool_bar_window) |
| @@ -5129,7 +5132,7 @@ w32_read_socket (struct terminal *terminal, | |||
| 5129 | || f == dpyinfo->w32_focus_frame) | 5132 | || f == dpyinfo->w32_focus_frame) |
| 5130 | /* Emit an Emacs wheel-up/down event. */ | 5133 | /* Emit an Emacs wheel-up/down event. */ |
| 5131 | { | 5134 | { |
| 5132 | construct_mouse_wheel (&inev, &msg, f); | 5135 | w32_construct_mouse_wheel (&inev, &msg, f); |
| 5133 | 5136 | ||
| 5134 | /* Ignore any mouse motion that happened before this | 5137 | /* Ignore any mouse motion that happened before this |
| 5135 | event; any subsequent mouse-movement Emacs events | 5138 | event; any subsequent mouse-movement Emacs events |
| @@ -5146,7 +5149,7 @@ w32_read_socket (struct terminal *terminal, | |||
| 5146 | 5149 | ||
| 5147 | if (f1 && FRAME_LIVE_P (f1) && FRAME_W32_P (f1)) | 5150 | if (f1 && FRAME_LIVE_P (f1) && FRAME_W32_P (f1)) |
| 5148 | { | 5151 | { |
| 5149 | construct_mouse_wheel (&inev, &msg, f1); | 5152 | w32_construct_mouse_wheel (&inev, &msg, f1); |
| 5150 | f1->mouse_moved = false; | 5153 | f1->mouse_moved = false; |
| 5151 | f1->last_tool_bar_item = -1; | 5154 | f1->last_tool_bar_item = -1; |
| 5152 | dpyinfo->last_mouse_frame = f1; | 5155 | dpyinfo->last_mouse_frame = f1; |
| @@ -5166,7 +5169,7 @@ w32_read_socket (struct terminal *terminal, | |||
| 5166 | f = x_window_to_frame (dpyinfo, msg.msg.hwnd); | 5169 | f = x_window_to_frame (dpyinfo, msg.msg.hwnd); |
| 5167 | 5170 | ||
| 5168 | if (f) | 5171 | if (f) |
| 5169 | construct_drag_n_drop (&inev, &msg, f); | 5172 | w32_construct_drag_n_drop (&inev, &msg, f); |
| 5170 | break; | 5173 | break; |
| 5171 | 5174 | ||
| 5172 | case WM_HSCROLL: | 5175 | case WM_HSCROLL: |
| @@ -5577,7 +5580,7 @@ w32_read_socket (struct terminal *terminal, | |||
| 5577 | case WM_EMACS_FILENOTIFY: | 5580 | case WM_EMACS_FILENOTIFY: |
| 5578 | f = x_window_to_frame (dpyinfo, msg.msg.hwnd); | 5581 | f = x_window_to_frame (dpyinfo, msg.msg.hwnd); |
| 5579 | if (f) | 5582 | if (f) |
| 5580 | queue_notifications (&inev, &msg, f, &count); | 5583 | w32_queue_notifications (&inev, &msg, f, &count); |
| 5581 | break; | 5584 | break; |
| 5582 | #endif | 5585 | #endif |
| 5583 | 5586 | ||
diff --git a/src/w32term.h b/src/w32term.h index 4c496e97e4a..a0942d630a5 100644 --- a/src/w32term.h +++ b/src/w32term.h | |||
| @@ -732,7 +732,7 @@ struct notifications_set { | |||
| 732 | }; | 732 | }; |
| 733 | extern struct notifications_set *notifications_set_head; | 733 | extern struct notifications_set *notifications_set_head; |
| 734 | extern Lisp_Object w32_get_watch_object (void *); | 734 | extern Lisp_Object w32_get_watch_object (void *); |
| 735 | extern Lisp_Object lispy_file_action (DWORD); | 735 | extern Lisp_Object w32_lispy_file_action (DWORD); |
| 736 | extern int handle_file_notifications (struct input_event *); | 736 | extern int handle_file_notifications (struct input_event *); |
| 737 | 737 | ||
| 738 | extern void w32_initialize_display_info (Lisp_Object); | 738 | extern void w32_initialize_display_info (Lisp_Object); |
diff --git a/src/xterm.c b/src/xterm.c index 5d4d2ca3b78..69f9afddbcc 100644 --- a/src/xterm.c +++ b/src/xterm.c | |||
| @@ -234,7 +234,7 @@ static void x_wm_set_window_state (struct frame *, int); | |||
| 234 | static void x_wm_set_icon_pixmap (struct frame *, ptrdiff_t); | 234 | static void x_wm_set_icon_pixmap (struct frame *, ptrdiff_t); |
| 235 | static void x_initialize (void); | 235 | static void x_initialize (void); |
| 236 | 236 | ||
| 237 | static bool get_current_wm_state (struct frame *, Window, int *, bool *); | 237 | static bool x_get_current_wm_state (struct frame *, Window, int *, bool *); |
| 238 | 238 | ||
| 239 | /* Flush display of frame F. */ | 239 | /* Flush display of frame F. */ |
| 240 | 240 | ||
| @@ -4354,7 +4354,7 @@ x_scroll_run (struct window *w, struct run *run) | |||
| 4354 | 4354 | ||
| 4355 | 4355 | ||
| 4356 | static void | 4356 | static void |
| 4357 | frame_highlight (struct frame *f) | 4357 | x_frame_highlight (struct frame *f) |
| 4358 | { | 4358 | { |
| 4359 | /* We used to only do this if Vx_no_window_manager was non-nil, but | 4359 | /* We used to only do this if Vx_no_window_manager was non-nil, but |
| 4360 | the ICCCM (section 4.1.6) says that the window's border pixmap | 4360 | the ICCCM (section 4.1.6) says that the window's border pixmap |
| @@ -4375,7 +4375,7 @@ frame_highlight (struct frame *f) | |||
| 4375 | } | 4375 | } |
| 4376 | 4376 | ||
| 4377 | static void | 4377 | static void |
| 4378 | frame_unhighlight (struct frame *f) | 4378 | x_frame_unhighlight (struct frame *f) |
| 4379 | { | 4379 | { |
| 4380 | /* We used to only do this if Vx_no_window_manager was non-nil, but | 4380 | /* We used to only do this if Vx_no_window_manager was non-nil, but |
| 4381 | the ICCCM (section 4.1.6) says that the window's border pixmap | 4381 | the ICCCM (section 4.1.6) says that the window's border pixmap |
| @@ -4740,9 +4740,9 @@ x_frame_rehighlight (struct x_display_info *dpyinfo) | |||
| 4740 | if (dpyinfo->x_highlight_frame != old_highlight) | 4740 | if (dpyinfo->x_highlight_frame != old_highlight) |
| 4741 | { | 4741 | { |
| 4742 | if (old_highlight) | 4742 | if (old_highlight) |
| 4743 | frame_unhighlight (old_highlight); | 4743 | x_frame_unhighlight (old_highlight); |
| 4744 | if (dpyinfo->x_highlight_frame) | 4744 | if (dpyinfo->x_highlight_frame) |
| 4745 | frame_highlight (dpyinfo->x_highlight_frame); | 4745 | x_frame_highlight (dpyinfo->x_highlight_frame); |
| 4746 | } | 4746 | } |
| 4747 | } | 4747 | } |
| 4748 | 4748 | ||
| @@ -4962,9 +4962,9 @@ x_get_keysym_name (int keysym) | |||
| 4962 | the mouse. */ | 4962 | the mouse. */ |
| 4963 | 4963 | ||
| 4964 | static Lisp_Object | 4964 | static Lisp_Object |
| 4965 | construct_mouse_click (struct input_event *result, | 4965 | x_construct_mouse_click (struct input_event *result, |
| 4966 | const XButtonEvent *event, | 4966 | const XButtonEvent *event, |
| 4967 | struct frame *f) | 4967 | struct frame *f) |
| 4968 | { | 4968 | { |
| 4969 | /* Make the event type NO_EVENT; we'll change that when we decide | 4969 | /* Make the event type NO_EVENT; we'll change that when we decide |
| 4970 | otherwise. */ | 4970 | otherwise. */ |
| @@ -4993,7 +4993,7 @@ construct_mouse_click (struct input_event *result, | |||
| 4993 | another motion event, so we can check again the next time it moves. */ | 4993 | another motion event, so we can check again the next time it moves. */ |
| 4994 | 4994 | ||
| 4995 | static bool | 4995 | static bool |
| 4996 | note_mouse_movement (struct frame *frame, const XMotionEvent *event) | 4996 | x_note_mouse_movement (struct frame *frame, const XMotionEvent *event) |
| 4997 | { | 4997 | { |
| 4998 | XRectangle *r; | 4998 | XRectangle *r; |
| 4999 | struct x_display_info *dpyinfo; | 4999 | struct x_display_info *dpyinfo; |
| @@ -7670,7 +7670,7 @@ x_net_wm_state (struct frame *f, Window window) | |||
| 7670 | Lisp_Object lval = Qnil; | 7670 | Lisp_Object lval = Qnil; |
| 7671 | bool sticky = false; | 7671 | bool sticky = false; |
| 7672 | 7672 | ||
| 7673 | get_current_wm_state (f, window, &value, &sticky); | 7673 | x_get_current_wm_state (f, window, &value, &sticky); |
| 7674 | 7674 | ||
| 7675 | switch (value) | 7675 | switch (value) |
| 7676 | { | 7676 | { |
| @@ -8594,12 +8594,12 @@ handle_one_xevent (struct x_display_info *dpyinfo, | |||
| 8594 | /* EnterNotify counts as mouse movement, | 8594 | /* EnterNotify counts as mouse movement, |
| 8595 | so update things that depend on mouse position. */ | 8595 | so update things that depend on mouse position. */ |
| 8596 | if (f && !f->output_data.x->hourglass_p) | 8596 | if (f && !f->output_data.x->hourglass_p) |
| 8597 | note_mouse_movement (f, &event->xmotion); | 8597 | x_note_mouse_movement (f, &event->xmotion); |
| 8598 | #ifdef USE_GTK | 8598 | #ifdef USE_GTK |
| 8599 | /* We may get an EnterNotify on the buttons in the toolbar. In that | 8599 | /* We may get an EnterNotify on the buttons in the toolbar. In that |
| 8600 | case we moved out of any highlighted area and need to note this. */ | 8600 | case we moved out of any highlighted area and need to note this. */ |
| 8601 | if (!f && dpyinfo->last_mouse_glyph_frame) | 8601 | if (!f && dpyinfo->last_mouse_glyph_frame) |
| 8602 | note_mouse_movement (dpyinfo->last_mouse_glyph_frame, &event->xmotion); | 8602 | x_note_mouse_movement (dpyinfo->last_mouse_glyph_frame, &event->xmotion); |
| 8603 | #endif | 8603 | #endif |
| 8604 | goto OTHER; | 8604 | goto OTHER; |
| 8605 | 8605 | ||
| @@ -8632,7 +8632,7 @@ handle_one_xevent (struct x_display_info *dpyinfo, | |||
| 8632 | #ifdef USE_GTK | 8632 | #ifdef USE_GTK |
| 8633 | /* See comment in EnterNotify above */ | 8633 | /* See comment in EnterNotify above */ |
| 8634 | else if (dpyinfo->last_mouse_glyph_frame) | 8634 | else if (dpyinfo->last_mouse_glyph_frame) |
| 8635 | note_mouse_movement (dpyinfo->last_mouse_glyph_frame, &event->xmotion); | 8635 | x_note_mouse_movement (dpyinfo->last_mouse_glyph_frame, &event->xmotion); |
| 8636 | #endif | 8636 | #endif |
| 8637 | goto OTHER; | 8637 | goto OTHER; |
| 8638 | 8638 | ||
| @@ -8701,7 +8701,7 @@ handle_one_xevent (struct x_display_info *dpyinfo, | |||
| 8701 | last_mouse_window = window; | 8701 | last_mouse_window = window; |
| 8702 | } | 8702 | } |
| 8703 | 8703 | ||
| 8704 | if (!note_mouse_movement (f, &event->xmotion)) | 8704 | if (!x_note_mouse_movement (f, &event->xmotion)) |
| 8705 | help_echo_string = previous_help_echo_string; | 8705 | help_echo_string = previous_help_echo_string; |
| 8706 | } | 8706 | } |
| 8707 | else | 8707 | else |
| @@ -8959,13 +8959,13 @@ handle_one_xevent (struct x_display_info *dpyinfo, | |||
| 8959 | && event->xbutton.time > ignore_next_mouse_click_timeout) | 8959 | && event->xbutton.time > ignore_next_mouse_click_timeout) |
| 8960 | { | 8960 | { |
| 8961 | ignore_next_mouse_click_timeout = 0; | 8961 | ignore_next_mouse_click_timeout = 0; |
| 8962 | construct_mouse_click (&inev.ie, &event->xbutton, f); | 8962 | x_construct_mouse_click (&inev.ie, &event->xbutton, f); |
| 8963 | } | 8963 | } |
| 8964 | if (event->type == ButtonRelease) | 8964 | if (event->type == ButtonRelease) |
| 8965 | ignore_next_mouse_click_timeout = 0; | 8965 | ignore_next_mouse_click_timeout = 0; |
| 8966 | } | 8966 | } |
| 8967 | else | 8967 | else |
| 8968 | construct_mouse_click (&inev.ie, &event->xbutton, f); | 8968 | x_construct_mouse_click (&inev.ie, &event->xbutton, f); |
| 8969 | } | 8969 | } |
| 8970 | if (FRAME_X_EMBEDDED_P (f)) | 8970 | if (FRAME_X_EMBEDDED_P (f)) |
| 8971 | xembed_send_message (f, event->xbutton.time, | 8971 | xembed_send_message (f, event->xbutton.time, |
| @@ -10671,10 +10671,10 @@ x_set_z_group (struct frame *f, Lisp_Object new_value, Lisp_Object old_value) | |||
| 10671 | Return true iff we are not hidden. */ | 10671 | Return true iff we are not hidden. */ |
| 10672 | 10672 | ||
| 10673 | static bool | 10673 | static bool |
| 10674 | get_current_wm_state (struct frame *f, | 10674 | x_get_current_wm_state (struct frame *f, |
| 10675 | Window window, | 10675 | Window window, |
| 10676 | int *size_state, | 10676 | int *size_state, |
| 10677 | bool *sticky) | 10677 | bool *sticky) |
| 10678 | { | 10678 | { |
| 10679 | unsigned long actual_size; | 10679 | unsigned long actual_size; |
| 10680 | int i; | 10680 | int i; |
| @@ -10922,7 +10922,7 @@ x_handle_net_wm_state (struct frame *f, const XPropertyEvent *event) | |||
| 10922 | int value = FULLSCREEN_NONE; | 10922 | int value = FULLSCREEN_NONE; |
| 10923 | Lisp_Object lval; | 10923 | Lisp_Object lval; |
| 10924 | bool sticky = false; | 10924 | bool sticky = false; |
| 10925 | bool not_hidden = get_current_wm_state (f, event->window, &value, &sticky); | 10925 | bool not_hidden = x_get_current_wm_state (f, event->window, &value, &sticky); |
| 10926 | 10926 | ||
| 10927 | lval = Qnil; | 10927 | lval = Qnil; |
| 10928 | switch (value) | 10928 | switch (value) |