aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRichard M. Stallman1994-10-20 06:39:00 +0000
committerRichard M. Stallman1994-10-20 06:39:00 +0000
commite9a79fb23e5198ad93e6979fb9a9639c8651cac4 (patch)
tree298db7dc318f0f6ed852bd410acfc668e7b51c7d /src
parenta9d77f1fb76d36c0612f4741c7bc267db3bb56cc (diff)
downloademacs-e9a79fb23e5198ad93e6979fb9a9639c8651cac4.tar.gz
emacs-e9a79fb23e5198ad93e6979fb9a9639c8651cac4.zip
(xdialog_show, xmenu_show): Use grabbed field instead of x_mouse_grabbed.
(xmenu_show): Use the screen in FRAME_X_DISPLAY_INFO, not the display's default screen.
Diffstat (limited to 'src')
-rw-r--r--src/xmenu.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/src/xmenu.c b/src/xmenu.c
index fea869ebe60..e1ace610f9c 100644
--- a/src/xmenu.c
+++ b/src/xmenu.c
@@ -1507,8 +1507,6 @@ free_frame_menubar (f)
1507 1507
1508#ifdef USE_X_TOOLKIT 1508#ifdef USE_X_TOOLKIT
1509 1509
1510extern unsigned int x_mouse_grabbed;
1511
1512/* We need a unique id for each widget handled by the Lucid Widget 1510/* We need a unique id for each widget handled by the Lucid Widget
1513 library. This includes the frame main windows, popup menu and 1511 library. This includes the frame main windows, popup menu and
1514 dialog box. */ 1512 dialog box. */
@@ -1988,7 +1986,7 @@ xdialog_show (f, menubarp, keymaps, title, error)
1988 That is not necessarily true, but the fiction leads to reasonable 1986 That is not necessarily true, but the fiction leads to reasonable
1989 results, and it is a pain to ask which are actually held now 1987 results, and it is a pain to ask which are actually held now
1990 or track this in the loop above. */ 1988 or track this in the loop above. */
1991 x_mouse_grabbed = 0; 1989 FRAME_X_DISPLAY_INFO (f)->grabbed = 0;
1992#endif 1990#endif
1993 1991
1994 /* Unread any events that we got but did not handle. */ 1992 /* Unread any events that we got but did not handle. */
@@ -2224,9 +2222,9 @@ xmenu_show (f, x, y, menubarp, keymaps, title, error)
2224 /* All set and ready to fly. */ 2222 /* All set and ready to fly. */
2225 XMenuRecompute (FRAME_X_DISPLAY (f), menu); 2223 XMenuRecompute (FRAME_X_DISPLAY (f), menu);
2226 dispwidth = DisplayWidth (FRAME_X_DISPLAY (f), 2224 dispwidth = DisplayWidth (FRAME_X_DISPLAY (f),
2227 XDefaultScreen (FRAME_X_DISPLAY (f))); 2225 FRAME_X_DISPLAY_INFO (f)->screen);
2228 dispheight = DisplayHeight (FRAME_X_DISPLAY (f), 2226 dispheight = DisplayHeight (FRAME_X_DISPLAY (f),
2229 XDefaultScreen (FRAME_X_DISPLAY (f))); 2227 FRAME_X_DISPLAY_INFO (f)->screen);
2230 x = min (x, dispwidth); 2228 x = min (x, dispwidth);
2231 y = min (y, dispheight); 2229 y = min (y, dispheight);
2232 x = max (x, 1); 2230 x = max (x, 1);
@@ -2308,7 +2306,7 @@ xmenu_show (f, x, y, menubarp, keymaps, title, error)
2308 (The oldXMenu code doesn't track this info for us.) 2306 (The oldXMenu code doesn't track this info for us.)
2309 That is not necessarily true, but the fiction leads to reasonable 2307 That is not necessarily true, but the fiction leads to reasonable
2310 results, and it is a pain to ask which are actually held now. */ 2308 results, and it is a pain to ask which are actually held now. */
2311 x_mouse_grabbed = 0; 2309 FRAME_X_DISPLAY_INFO (f)->grabbed = 0;
2312#endif 2310#endif
2313 2311
2314 return entry; 2312 return entry;