Last Comment Bug 703197 - Printing a display:none iframe should work
: Printing a display:none iframe should work
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: Printing: Setup (show other bugs)
: 9 Branch
: x86 Mac OS X
: -- normal (vote)
: mozilla11
Assigned To: Boris Zbarsky [:bz] (Out June 25-July 6)
:
Mentors:
data:text/html,<iframe style="display...
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-11-16 22:32 PST by Boris Zbarsky [:bz] (Out June 25-July 6)
Modified: 2012-02-01 14:00 PST (History)
2 users (show)
bzbarsky: in‑testsuite?
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
Make window.print() work in display:none iframes. (1.17 KB, patch)
2011-11-17 01:34 PST, Boris Zbarsky [:bz] (Out June 25-July 6)
bugs: review+
Details | Diff | Review

Description Boris Zbarsky [:bz] (Out June 25-July 6) 2011-11-16 22:32:25 PST
Loading the attached url should pop up a print dialog and let you print.
Comment 1 Boris Zbarsky [:bz] (Out June 25-July 6) 2011-11-17 01:34:25 PST
Created attachment 575117 [details] [diff] [review]
Make window.print() work in display:none iframes.
Comment 2 Boris Zbarsky [:bz] (Out June 25-July 6) 2011-11-17 19:55:06 PST
https://hg.mozilla.org/integration/mozilla-inbound/rev/e4fcfc45b674
Comment 3 Steffen Wilberg 2011-11-18 02:37:34 PST
Comment on attachment 575117 [details] [diff] [review]
Make window.print() work in display:none iframes.

>-  nsCOMPtr<nsIPresShell> presShell;
>-  docShell->GetPresShell(getter_AddRefs(presShell));
>-  if (!presShell || !mDocument || !mDeviceContext) {
>+  if (!mDocument || !mDeviceContext) {
>     PR_PL(("Can't Print without pres shell, document etc"));
Is that log message still correct, after you've removed the check for presShell?
Comment 4 Ed Morley [:emorley] 2011-11-18 02:58:27 PST
https://hg.mozilla.org/mozilla-central/rev/e4fcfc45b674
Comment 5 Boris Zbarsky [:bz] (Out June 25-July 6) 2011-11-18 03:33:45 PST
> Is that log message still correct, after you've removed the check for presShell?

Nope.  Good catch.  I'll fix that.
Comment 6 Boris Zbarsky [:bz] (Out June 25-July 6) 2011-11-19 15:07:18 PST
https://hg.mozilla.org/integration/mozilla-inbound/rev/4c45c9b2cc0c for the message fix
Comment 7 Ed Morley [:emorley] 2011-11-20 14:21:32 PST
https://hg.mozilla.org/mozilla-central/rev/4c45c9b2cc0c

Note You need to log in before you can comment on or make changes to this bug.