emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master 69dde0c: Avoid duplicate gud menu items with gdb-mi


From: Glenn Morris
Subject: [Emacs-diffs] master 69dde0c: Avoid duplicate gud menu items with gdb-mi
Date: Fri, 3 Mar 2017 19:47:08 -0500 (EST)

branch: master
commit 69dde0c54ce8d4ae9600bd10fa15b2b1e227c1f3
Author: Glenn Morris <address@hidden>
Commit: Glenn Morris <address@hidden>

    Avoid duplicate gud menu items with gdb-mi
    
    * lisp/progmodes/gud.el (gud-menu-map): Avoid duplicate "Run"
    entries in gdbmi mode.  (Bug#23923)
---
 lisp/progmodes/gud.el | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/lisp/progmodes/gud.el b/lisp/progmodes/gud.el
index 1301758..7ab1442 100644
--- a/lisp/progmodes/gud.el
+++ b/lisp/progmodes/gud.el
@@ -146,7 +146,11 @@ Used to gray out relevant toolbar icons.")
     ([refresh] "Refresh" . gud-refresh)
     ([run]     menu-item "Run" gud-run
                   :enable (not gud-running)
-                 :visible (memq gud-minor-mode '(gdbmi gdb dbx jdb)))
+                 :visible (or (memq gud-minor-mode '(gdb dbx jdb))
+                              (and (eq gud-minor-mode 'gdbmi)
+                                   (or (not (gdb-show-run-p))
+                                       (bound-and-true-p
+                                        gdb-active-process)))))
     ([go]      menu-item (if (bound-and-true-p gdb-active-process)
                              "Continue" "Run") gud-go
                  :visible (and (eq gud-minor-mode 'gdbmi)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]