Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Prevent accidental window closure in a given app' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Prevent accidental window closure in a given app
Authored by: CarlRJ on Mar 22, '04 08:06:46PM

I'd like to add a large thank you to the author. I've used the new ability to set keyboard shortcuts (it's nice to have cmd-shift-M as Zoom, for Terminal windows, to compliment cmd-M for Minimize), and I've also been extremely annoyed, once a week or so, when my finger strayed from cmd-W to cmd-Q in Safari and I suddenly lost several dozen pages I'd not yet read... but until seeing this hint, I hadn't put the two together and realized that one could remap the existing "Quit Safari" command from cmd-Q to cmd-option-Q). This will save me a lot of grief in the future -- Thanks!

-- Carl, who still thinks Safari needs an "Are you sure?" dialog when quitting with multiple tabs open.



[ Reply to This | # ]
Prevent accidental window closure in a given app
Authored by: ericasadun on Mar 22, '04 09:13:27PM

It's easy enough to add an "Are you sure" dialog to Safari.

Build a new window in Interface Builder. Add text ("Are you sure")
and two buttons (Cancel, OK).

Connect the Quit menu item (in MainMenu.nib) to the Window
(make key and order front) and connect OK to File's Owner/Terminate. Have Cancel close the window.



[ Reply to This | # ]
Proper dialog box text
Authored by: derrickbass on Mar 22, '04 11:34:47PM

Well maybe this doesn't really matter for when you modify an application yourself, but one of the things that sets Macs apart from Windows is the useful text in dialog boxes and on the buttons. (I've seen dialog boxes in Windows with triple negatives! Very hard to decide if OK or Cancel is what you want!)

The text should be: "Are you sure you want to quit?" and the buttons should be "Quit" and "Cancel". (The reason you use "Quit" instead of "OK" is so the user does not have to read and understand the text. "OK" is almost never appropriate.)



[ Reply to This | # ]
Proper dialog box text
Authored by: kps on Mar 23, '04 10:15:35AM