This was my mis-reading/remembering of the code in menu-bar.el. I thought there was code in menu-bar.el that was adding 'action' menus 'buttons' at the top level in the ns port, but looking at it again, I realise this is for the GNUStep version. My (flawed) logic was that if menu-bar.el is adding top level action buttons for a version, then the tookit used for that version must allow it. I think my logic is OK, it was my scanning of the code that led to the wrong conclusion! The code in quesiton was
On Sat, Feb 26, 2011 at 9:22 PM, Jan Djärv <address@hidden>
Tim Cross skrev 2011-02-26 00.58:
Menu-bar.el has nothing to do with how things are implemented at the toolkit level. Looking at it gives no clue what so ever.
I'm a bit surprised that the same problem seems to occur under the NextStep OS
- while I'm not expert here and could have things confused, it looked to me
like the ns version added menu 'buttons' when I scanned the menu-bar.el file.
(if (not (featurep 'ns))
;; Force Help item to come last, after the major mode's own items.
;; The symbol used to be called `help', but that gets confused with the
;; help key.
(setq menu-bar-final-items '(help-menu))
(if (eq system-type 'darwin)
(setq menu-bar-final-items '(buffer services help-menu))
(setq menu-bar-final-items '(buffer services hide-app quit))
;; Add standard top-level items to GNUstep menu.
(define-key global-map [menu-bar quit]
`(menu-item ,(purecopy "Quit") save-buffers-kill-emacs
:help ,(purecopy "Save unsaved buffers, then exit")))
(define-key global-map [menu-bar hide-app]
`(menu-item ,(purecopy "Hide") ns-do-hide-emacs
:help ,(purecopy "Hide Emacs"))))
(define-key global-map [menu-bar services] ; set-up in ns-win
(cons (purecopy "Services") (make-sparse-keymap "Services"))))