modal dialogs and Quit problem
Alex Rice
alex at mindlube.com
Mon Sep 8 21:05:01 EDT 2003
On Monday, September 8, 2003, at 10:02 PM, Barry Levine wrote:
> Now, someone wrote (and I don't remember who) that it's the
> developer's responsibility to disable the Quit menu item. Fair enough.
> Show me how that can be done in OSX and I'll have a workaround.
re: disabling the Quit menu item.
(that was me) Sorry, "disable menu" is not working for the App's menu.
Menu 1 is apparently mapped to the menu after the App's menu; the File
menu. Menu "appName" doesn't exist. Docs say: "On Mac OS systems, the
Apple menu does not have a number and cannot be enabled or disabled.
Menu numbering starts with the menu to the right of the Apple menu." On
OS X the menu item after the Apple menu is the application menu.
runrev: Is this a docs bug, or an engine bug? In either case, one
cannot disable the Quit menu item.
IMHO sneakily moving menu items (quit, preferences) from other menus to
the Application menu really seems like a poor solution. We need full
control over the App menu on OS X. In Apple's Project Builder, the App
menu is fully editable and is no different than other menus in terms of
creation and event handling. I'm sure the current behavior of Rev is in
the interest of making menu objects cross-platform. This seems like
feature request material.
re: replicating your problem report
I made a new stack and set it's menu bar as the mac os menu bar,
causing the Quit menu item to be moved from the File menu into the
App's menu. Built standalone. Here are my findings:
1 - during an "answer file", the the quit menu item IS disabled. It's
OK after all.
2 - during an "answer info", the the quit menu item is *enabled*.
that's not good because it does also send a shutdownRequest message.
this should be bugzilla'd. (maybe covered in your bug report?)
3 - shutdownRequest always got sent. couldn't replicate that bug.
4 - didn't look at any other modal dialogs
re: miserable workaround for problem 2
hide menubar
answer info "..." -- or other modal dialog
show menubar
re: possible other workaround for problem 2
shutdownRequest is also coincident with an apple event that's described
in the docs. I would check to make sure that the apple event has the
same bug as the shutdownRequest (gets sent during modal dialog). If the
apple event for some reason doesn't suffer the same bug then that opens
up a better workaround possibility.
You seem to have found at least 2 bugs here Barry! It's hard to tell
because of the connection between the Quit menu item and the
shutdownRequest message + apple event message. Anyone know how we can
we look into that connection and see how it's implemented? is it
transcript or part of the OS X engine?
I learned a lot about Rev menus tonight- thanks!
Alex Rice <alex at mindlube.com> | Mindlube Software | http://mindlube.com
what a waste of thumbs that are opposable
to make machines that are disposable -Ani DiFranco
More information about the use-livecode
mailing list