diff options
author | Karoly Lorentey <lorentey@elte.hu> | 2006-07-29 20:57:26 +0000 |
---|---|---|
committer | Karoly Lorentey <lorentey@elte.hu> | 2006-07-29 20:57:26 +0000 |
commit | 14ab3a40ec0cfdfa7f351e1202e0f873af553391 (patch) | |
tree | 8e0369b9f5716ef4fac672fd816af559051396ff /lisp/menu-bar.el | |
parent | e6aee454e682e137d5b04116716d308c1d5c3544 (diff) | |
download | emacs-14ab3a40ec0cfdfa7f351e1202e0f873af553391.tar.gz |
Fix F10 behaviour. (Reported by Bernard Adrian.)
* src/xmenu.c (Fx_menu_bar_open) [USE_X_TOOLKIT, USE_GTK]:
Rename from Fmenu_bar_open.
(syms_of_xmenu): Update defsubr.
* lisp/menu-bar.el (menu-bar-open): New function.
Bind it to f10.
* lisp/term/x-win.el: Don't bind f10.
* lisp/tmm.el: Remove autoload binding for f10.
* lisp/ldefs-boot.el: Regenerate.
git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-577
Diffstat (limited to 'lisp/menu-bar.el')
-rw-r--r-- | lisp/menu-bar.el | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/lisp/menu-bar.el b/lisp/menu-bar.el index 598c18128c9..b3909559d03 100644 --- a/lisp/menu-bar.el +++ b/lisp/menu-bar.el @@ -1768,6 +1768,22 @@ See `menu-bar-mode' for more information." (menu-bar-mode (if (> (frame-parameter nil 'menu-bar-lines) 0) 0 1)) (menu-bar-mode arg))) +(defun menu-bar-open (&optional frame) + "Start key navigation of the menu bar in FRAME. + +This function decides which method to use to access the menu +depending on FRAME's terminal device. On X displays, it calls +`x-menu-bar-open'; otherwise it calls `tmm-menubar'. + +If FRAME is nil or not given, use the selected frame." + (interactive) + (if (eq window-system 'x) + (x-menu-bar-open frame) + (with-selected-frame (or frame (selected-frame)) + (tmm-menubar)))) + +(global-set-key [f10] 'menu-bar-open) + (provide 'menu-bar) ;;; arch-tag: 6e6a3c22-4ec4-4d3d-8190-583f8ef94ced |