diff options
| author | Dmitry Antipov | 2013-09-18 13:23:10 +0400 |
|---|---|---|
| committer | Dmitry Antipov | 2013-09-18 13:23:10 +0400 |
| commit | 18da0d8ad4e5036185acbad3238cbfe2aaf3ca66 (patch) | |
| tree | 7dc7f25186e10dd1c767d1dbf26268b8c70e1a51 /src/nsfns.m | |
| parent | 7a0c745ad134aff0bb8f4258ea607137a819b58d (diff) | |
| download | emacs-18da0d8ad4e5036185acbad3238cbfe2aaf3ca66.tar.gz emacs-18da0d8ad4e5036185acbad3238cbfe2aaf3ca66.zip | |
* frame.c (x_redo_mouse_highlight): New function
to factor out common code used in W32 and X ports.
* dispextern.h (x_redo_mouse_highlight): Add prototype.
* xterm.h (struct x_display_info):
* w32term.h (struct w32_display_info):
* nsterm.h (struct ns_display_info): New members
last_mouse_motion_frame, last_mouse_motion_x and
last_mouse_motion_y, going to replace static variables below.
* xterm.c (last_mouse_motion_event, last_mouse_motion_frame)
(redo_mouse_highlight): Remove.
(note_mouse_movement, syms_of_xterm): Adjust user.
(handle_one_xevent): Likewise. Use x_redo_mouse_highlight.
* w32term.c (last_mouse_motion_event, last_mouse_motion_frame)
(redo_mouse_highlight): Remove.
(note_mouse_movement, syms_of_w32term): Adjust user.
(w32_read_socket): Likewise. Use x_redo_mouse_highlight.
* nsterm.m (last_mouse_motion_position, last_mouse_motion_frame):
Remove.
(note_mouse_movement, mouseMoved, syms_of_nsterm):
* nsfns.m (compute_tip_xy): Adjust user.
Diffstat (limited to 'src/nsfns.m')
| -rw-r--r-- | src/nsfns.m | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/nsfns.m b/src/nsfns.m index 408e6d2176e..93b7d12becb 100644 --- a/src/nsfns.m +++ b/src/nsfns.m | |||
| @@ -2564,6 +2564,7 @@ compute_tip_xy (struct frame *f, | |||
| 2564 | { | 2564 | { |
| 2565 | Lisp_Object left, top; | 2565 | Lisp_Object left, top; |
| 2566 | EmacsView *view = FRAME_NS_VIEW (f); | 2566 | EmacsView *view = FRAME_NS_VIEW (f); |
| 2567 | struct ns_display_info *dpyinfo = FRAME_DISPLAY_INFO (f); | ||
| 2567 | NSPoint pt; | 2568 | NSPoint pt; |
| 2568 | 2569 | ||
| 2569 | /* Start with user-specified or mouse position. */ | 2570 | /* Start with user-specified or mouse position. */ |
| @@ -2572,7 +2573,8 @@ compute_tip_xy (struct frame *f, | |||
| 2572 | 2573 | ||
| 2573 | if (!INTEGERP (left) || !INTEGERP (top)) | 2574 | if (!INTEGERP (left) || !INTEGERP (top)) |
| 2574 | { | 2575 | { |
| 2575 | pt = last_mouse_motion_position; | 2576 | pt.x = dpyinfo->last_mouse_motion_x; |
| 2577 | pt.y = dpyinfo->last_mouse_motion_y; | ||
| 2576 | /* Convert to screen coordinates */ | 2578 | /* Convert to screen coordinates */ |
| 2577 | pt = [view convertPoint: pt toView: nil]; | 2579 | pt = [view convertPoint: pt toView: nil]; |
| 2578 | pt = [[view window] convertBaseToScreen: pt]; | 2580 | pt = [[view window] convertBaseToScreen: pt]; |