Closed Bug 129034 Opened 23 years ago Closed 22 years ago

IFrames display on the wrong page in PP

Categories

(Core :: Print Preview, defect, P1)

x86
Windows 2000
defect

Tracking

()

VERIFIED FIXED
mozilla1.2beta

People

(Reporter: rods, Assigned: kmcclusk)

References

()

Details

(Keywords: top100, topembed, Whiteboard: [adt2] [ETA 09/23], will be adt minused on 11/5)

Attachments

(5 files, 2 obsolete files)

 
If you have enough lines in a document to push the IFrame on to the second page
(for PP) it will be shown on the first page of the PP. This is the same for
object tags.
Severity: normal → major
Status: NEW → ASSIGNED
Keywords: nsbeta1
Target Milestone: --- → mozilla1.0
Depends on: 129546
No longer depends on: 129546
Bulk moving all nsbeta1 nominations to future-P1. If they are approved
(nsbeta1+) they will be moved to mozilla1.0
Priority: -- → P1
Target Milestone: mozilla1.0 → Future
nsbeta1-
Keywords: nsbeta1nsbeta1-
Keywords: nsbeta1-nsbeta1
Summary: IFrames display on the worng page in PP → IFrames display on the wrong page in PP
Target Milestone: Future → mozilla1.2beta
Fails on www.news.com
Status: ASSIGNED → NEW
nsbeta1+
Keywords: nsbeta1nsbeta1+
Note that the testcase is part of the build, located at:
file:///S:/mozilla/layout/html/tests/printer/iframe_2nd_page/index.html
Status: NEW → ASSIGNED
One interesting thing I noticed by setting some breakpoints in the
CSSFrameConstructor is that the 1st PageFrame gets created and then the IFrame
frame get created as part of the block reflow and then the 2nd PageFrame frame
is created. 

Then the IFrame gets moved to the second page and it's parenting is messed up.
->kmcclusk
Assignee: rods → kmcclusk
Status: ASSIGNED → NEW
Fix which reparents the widgets owned by the view or its descendants when the
view is inserted into its parents list of children. Solves the problem on
WIN32. Mac and Linux need to have nsIWidget::SetParent(nsIWidget *aNewParent)
implemented.
Attachment #98058 - Attachment is obsolete: true
Note: As expected, browsing webpages and running jrgm's pageloader tests it
*never* triggers the logic which calls GetWidgetForView or ReparentChildWidgets.
 It only gets executed when print previewing pages so there will not be any page
load performance impact from this fix.

SetParent needs to be implemented on Mac and Linux. I'll file separate bugs for
this work. If the current patch is checked in SetParent will be a no-op on those
platforms so this bug will still occur until we implement nsIWidget::SetParent
Shouldn't SetParent be setting the mParent field of the widget?
Some platforms use the basewidget's mParent member and others don't. WIN32
doesn't use it at all. I didn't set the mParent field because I didn't want to
regress any behavior on the non-WIN32 platforms which may rely on mParent. I was
assuming that when the nsIWidget::SetParent implementation is done for a
platform that actually uses mParent it will become clear what the proper
implementation for the basewidget's ::SetParent should be. For now, I think the
safest behavior is to report that it's not implemented.

I would like to check in this patch which includes the xp-code and WIN32
specific nsIWidget::SetParent code, and have platform experts implement the
nsIWidget::SetParent logic for Mac, Linux and other platforms.  
Comment on attachment 98215 [details] [diff] [review]
Same as last patch minus the small part of an unrelated patch.

r/sr=kin@netscape.com

Just add a comment to nsWindow::SetParent() that explains why you aren't
setting mParent for win32.
Attachment #98215 - Flags: superreview+
Comment on attachment 98215 [details] [diff] [review]
Same as last patch minus the small part of an unrelated patch.

r=roc+moz

This is rather horrid, really, but I can't think of a better way to do solve
the problem.
Attachment #98215 - Flags: review+
Blocks: 167775
Fix checked in to the trunk
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
bug 168116 covers the GTK nsIWidget::SetParent implementation
bug 168117 covers the Mac nsIWidget::SetParent implementation
Keywords: top100
Comment on attachment 98215 [details] [diff] [review]
Same as last patch minus the small part of an unrelated patch.

a=rjesup@wgate.com for 1.0 branch.  Please mark on the Linux and Mac sub-bugs
that we'll want those patches for 1.0 when they're done.

WHen checked in, change mozilla1.0.2+ to fixed1.0.2
Attachment #98215 - Flags: approval+
This is effecting scrolling performance on a top site.

Changing edt1.0.2 nomination to adt1.0.2, as the ADT is monitoring the 1.0.2
checkins. 
Keywords: edt1.0.2adt1.0.2
Pls excuse my last comment, "This is effecting scrolling performance on a top
site." It was a copy and paste error brought on b y big thumbs on a sunday
afternoon. ;-)

sujay: can you pls verify this as fixed on the trunk? thanks!
Whiteboard: [adt2] [ETA 09/23]
adt-, not verified on the trunk. Please get this verified before you renominate
and then make the case why this fits the Blackbird goals.
Keywords: adt1.0.2adt1.0.2-
verified in 9/26 trunk build

news.com seems to render properly in PP mode. I compared actual
print output with PP.
Status: RESOLVED → VERIFIED
Removing the minus to renominate this one, as it effects a top100 site.
Keywords: adt1.0.2-adt1.0.2
please check in to branch and add keyword fixed1.0.2
if new driver approval is needed please make sure to get it.
Keywords: adt1.0.2adt1.0.2+
ported over....
Attachment #104897 - Flags: superreview+
Comment on attachment 104897 [details] [diff] [review]
patch for 1.0.2 branch

sr=dveditz based on it being the same as the reviewed trunk patch
rod:  please get r= and drivers approval today as we are driving toward a
release candidate
Whiteboard: [adt2] [ETA 09/23] → [adt2] [ETA 09/23], will be adt minused on 11/5
Comment on attachment 104897 [details] [diff] [review]
patch for 1.0.2 branch

r=kin@netscape.com
Attachment #104897 - Flags: review+
Comment on attachment 104897 [details] [diff] [review]
patch for 1.0.2 branch

a=chofmann for 1.0.2
Attachment #104897 - Flags: approval+
fixed on branch
Keywords: fixed1.0.2
Just talked to Rod.  This has landed on the branch.  Linking  to our meta.
Blocks: blackbird
verified in 11/6 branch build.
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: