10.3: Add a Junk button to Mail's standalone message viewer

Jan 29, '04 10:44:00AM

Contributed by: cfoster

Whenever I open a spam email message (in its own window via a double-click, not inline), I find I always instinctively go looking for the "Junk" button in the toolbar. Unfortunately the toolbar for the standalone window can't have a Junk button for some reason. Or can it...?

Quit Mail and choose 'Show Package Contents' by control-clicking on the Mail program. Use any text editor to edit the file at Mail -> Contents -> Resources -> TornOffViewer.toolbar. Add the following text after the deleteMessages: item in the toolbar array:


  {
    help = "TOOLTIP_JUNK"; 
    identifier = "markAsJunkMail:"; 
    image = junkmail; 
    tag = 0; 
    title = "TOOLBAR_JUNK";
    altTitle = "TOOLBAR_NOTJUNK";
  }, 

(Note the trailing comma at the end!)

Save the file and relaunch Mail. You should now be able to edit the toolbar for the standalone message viewer window to include a "Junk" button. (Yes, I know about Shift-Command-J to mark something as Junk, I just always seem to be looking to click the button, is all.)

One can use a similar technique to add a "Delete" button to the toolbar of the Compose window by adding the deleteMessages: toolbar item to the ComposeNewOrDraft.toolbar. Unfortunately, the button gets disabled since deleting an open outgoing message is not allowed for some reason. I've submitted both these items as feature requests to Apple.

Comments (4)


Mac OS X Hints
http://hints.macworld.com/article.php?story=2004012118263096