Closed Bug 173074 Opened 22 years ago Closed 21 years ago

print preview is enabled in the context menu for whitespace

Categories

(SeaMonkey :: MailNews: Message Display, defect)

x86
Windows 2000
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: timeless, Assigned: sspitzer)

References

Details

(Keywords: fixed1.4, fixed1.4.2)

Attachments

(1 file, 2 obsolete files)

doron tested this using his untarnished mailnews client. 

the steps:
1. open mailnews to a folder
2. scroll to the very end of the thread pane and size the pane so that you can
see some whitespace
3. select a message in the thread pane
4. ctrl-click it to deselect it (problems start here)
5. right click whitespace in the threadpane (be sure not to click on a row that
has a message)
5' print preview was enabled

What should we do? don't enable print preview if zero items are selected.

I have a rewrite for the relevant file and I can fix this then if someone is
willing to review my patch.
Blocks: 173077
I assume the fix looks like this:
Index: mailContextMenus.js
===================================================================
RCS file: /cvsroot/mozilla/mailnews/base/resources/content/mailContextMenus.js,v
retrieving revision 1.37
diff -u -r1.37 mailContextMenus.js
--- mailContextMenus.js 14 Aug 2002 06:33:06 -0000      1.37
+++ mailContextMenus.js 11 Oct 2002 10:16:04 -0000
@@ -109,6 +109,7 @@
   EnableMenuItem("threadPaneContext-labels", (numSelected >= 1));
   SetupSaveAsMenuItem("threadPaneContext-saveAs", numSelected, false);
   SetupPrintMenuItem("threadPaneContext-print", numSelected, false);
+  SetupPrintMenuItem("threadPaneContext-printpreview", numSelected, false);
   SetupDeleteMenuItem("threadPaneContext-delete", numSelected, false);
   SetupAddSenderToABMenuItem("threadPaneContext-addSenderToAddressBook",
numSelected, false);
   SetupAddAllToABMenuItem("threadPaneContext-addAllToAddressBook", numSelected,
false);
BTW, an easier way to demonstrate the problem is to use an empty folder.
Yes, (numSelected == 1) works better :-)
QA Contact: olgam → esther
Attached patch fix (obsolete) — Splinter Review
This patch makes the Print Preview item available exactly when the Print item
is available.
Comment on attachment 129677 [details] [diff] [review]
fix

... which is wrong, as I mentioned in comment 3.
Attachment #129677 - Flags: review-
Attached patch fix 2 (obsolete) — Splinter Review
Attachment #129677 - Attachment is obsolete: true
Attachment #129808 - Flags: review?(neil.parkwaycc.co.uk)
*** Bug 191112 has been marked as a duplicate of this bug. ***
*** Bug 202786 has been marked as a duplicate of this bug. ***
Comment on attachment 129808 [details] [diff] [review]
fix 2

Worse - now I don't get print preview at all in the message pane context menu.
Attachment #129808 - Flags: review?(neil.parkwaycc.co.uk) → review-
> ... which is wrong, as I mentioned in comment 3.

So the issue is that the user can't get a print preview of more than one message
at a time, even though they can print more than one message at a time? That
sounds like a bug in the Print Preview feature to me.
Hmmm... on the other hand, Print Preview is disabled in the File menu if more
than one message is selected, so I suppose the context menu should behave them same.
Attached patch fix 3Splinter Review
This patch also disables Print Preview when multiple messages are selected,
just like Save As does. Additionally, it disables Print Preview when
right-clicking a link in a mail message, as it should.
Attachment #129808 - Attachment is obsolete: true
Attachment #129820 - Flags: superreview?(scott)
Attachment #129820 - Flags: review+
Attachment #129820 - Flags: superreview?(scott) → superreview+
Comment on attachment 129820 [details] [diff] [review]
fix 3

This patch prevents a bogus window and task from being created when Print
Preview is chosen when no message is selected. There is essentially no risk
because Print Preview is available through the File menu. Let's get this in for
1.5. The added lines can be commented out if anyone wants to fix the bugs this
depends on (the bogus window and task problem).
Attachment #129820 - Flags: approval1.5b?
Comment on attachment 129820 [details] [diff] [review]
fix 3

1.5b shipped. moving approval request forward.
Attachment #129820 - Flags: approval1.5b? → approval1.5?
Comment on attachment 129820 [details] [diff] [review]
fix 3

a=asa (on behalf of drivers) for checkin to Mozilla 1.5
Attachment #129820 - Flags: approval1.5? → approval1.5+
Fix checked in.
Status: NEW → RESOLVED
Closed: 21 years ago
Resolution: --- → FIXED
Comment on attachment 129820 [details] [diff] [review]
fix 3

Let's get this in for 1.4.1, too. It's a pretty bad bug (creates a zombie task)
and is easy to trigger (start mailnews, right click on message window, and
select one of the two choices).
Attachment #129820 - Flags: approval1.4.x?
Comment on attachment 129820 [details] [diff] [review]
fix 3

too late for 1.4.1. if you'd like to see this in the next 1.4.x release please
set the approval1.4.2? flag.
Attachment #129820 - Flags: approval1.4.1? → approval1.4.1-
Attachment #129820 - Flags: approval1.4.2?
Comment on attachment 129820 [details] [diff] [review]
fix 3

a=mkaply
Attachment #129820 - Flags: approval1.4.2? → approval1.4.2+
Keywords: fixed1.4, fixed1.4.2
Product: Browser → Seamonkey
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: