]> git.eshelyaron.com Git - emacs.git/commitdiff
(popup_get_selection): Click not in menu deactivates menu.
authorRichard M. Stallman <rms@gnu.org>
Sat, 4 Jun 2005 18:09:16 +0000 (18:09 +0000)
committerRichard M. Stallman <rms@gnu.org>
Sat, 4 Jun 2005 18:09:16 +0000 (18:09 +0000)
src/ChangeLog
src/xmenu.c

index 36650215350cc18d9021120364689d8f56755e9e..c0466275d4af51e2d7b0b3695ebf9426bd254e14 100644 (file)
@@ -1,3 +1,7 @@
+2005-06-04  Richard M. Stallman  <rms@gnu.org>
+
+       * xmenu.c (popup_get_selection): Click not in menu deactivates menu.
+
 2005-06-04  Jan Dj\e,Ad\e(Brv  <jan.h.d@swipnet.se>
 
        * macmenu.c (cleanup_popup_menu): New function.
index 6f758d12fc745a4f12f8d9067a83be9a2cd0f5d7..6e3a21604c10886e548ae8532bac56bf53b4ab50 100644 (file)
@@ -1235,6 +1235,10 @@ popup_get_selection (initial_event, dpyinfo, id, do_timers)
       if (event.type == ButtonRelease
           && dpyinfo->display == event.xbutton.display)
         {
+         /* If the click is not on the menu, deactivate the menu.  */
+         if (x_any_window_to_frame (dpyinfo, event.xexpose.window))
+           popup_activated_flag = 0;
+           
           dpyinfo->grabbed &= ~(1 << event.xbutton.button);
 #ifdef USE_MOTIF /* Pretending that the event came from a
                     Btn1Down seems the only way to convince Motif to