# HG changeset patch # User Richard M. Stallman # Date 838499431 0 # Node ID fc460a98a7f9d8d30c3dfd40765870177b6f4652 # Parent feeb1f7c1cec67ee4e04033af16b7e0c5b4d59c2 (last_mouse_press_frame): New variable. (XTread_socket): Store a saved_button_event for ButtonRelease. diff -r feeb1f7c1cec -r fc460a98a7f9 src/xterm.c --- a/src/xterm.c Sat Jul 27 20:28:55 1996 +0000 +++ b/src/xterm.c Sat Jul 27 20:30:31 1996 +0000 @@ -195,6 +195,7 @@ /* Where the mouse was last time we reported a mouse event. */ static FRAME_PTR last_mouse_frame; +static FRAME_PTR last_mouse_press_frame; static XRectangle last_mouse_glyph; /* The scroll bar in which the last X motion event occurred. @@ -4047,6 +4048,12 @@ && event.xbutton.same_screen) { SET_SAVED_BUTTON_EVENT; + last_mouse_press_frame = f; + } + else if (event.type == ButtonRelease) + { + if (!f) f = last_mouse_press_frame; + SET_SAVED_BUTTON_EVENT; } else goto OTHER;