Closed Bug 116093 Opened 24 years ago Closed 24 years ago

[viewpoint] Windowless plugins do not always get right coordinates

Categories

(Core Graveyard :: Plug-ins, defect, P2)

x86
Windows NT
defect

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: serhunt, Assigned: serhunt)

Details

Attachments

(2 files, 4 obsolete files)

This bug is off-spring from bug 114667. If you use <center><embed ...><\center> construction with the windowless plugin, you will see that the plugin ignores <center> tag and always drawn with (0,0) position. Test case to follow. Please install ViewPoint plugin for testing: http://cole.viewpoint.com/~aberger/setwindowbug/viewpointplugin.zip Ari, please update the plugin location if this link is obsolete.
...restoring the parent bug nominations.
Severity: normal → critical
Status: NEW → ASSIGNED
Keywords: edt0.9.4
Priority: -- → P2
Target Milestone: --- → mozilla0.9.7
Best link for our plugin is here: http://cole.viewpoint.com/~aberger/viewpointplugin.zip If you already have us installed and just want the latest .dll and .xpt: http://cole.viewpoint.com/~aberger/npViewpoint.zip http://cole.viewpoint.com/~aberger/npViewpoint.xpt
Attached patch patch v.1 (obsolete) — Splinter Review
This patch is in cvs -uw format so do not pay much attention to white spaces, they are aligned well in the original fix. The patch is based on patch http://bugzilla.mozilla.org/attachment.cgi?id=61428&action=view from bug 114667 with one addition: with only that patch we do not get it right after the page shows up first time, it picks up only when you start to resize and on. I added an additional reflow command after the first reflow which seems to fix this problem. Please review and try.
Keywords: patch
Attached patch patch v.2 (obsolete) — Splinter Review
This version is essentially the same, I just factored out some code into nsObjectFrame::GetWindowOrigin as I am going to reuse this code for fixing bug 116108. Please review.
Attachment #62251 - Attachment is obsolete: true
The patch looks good to me and works with my test content.
Summary: Windowless plugins do not always get right coordinates → [viewpoint] Windowless plugins do not always get right coordinates
Attached patch patch v.3 (obsolete) — Splinter Review
Nothing dramatically new, just hide twips to pixel conversion inside GetWindowOrigin method to make code smaller and cleaner.
Attachment #62284 - Attachment is obsolete: true
Attached patch patch v.4 (obsolete) — Splinter Review
Sorry, forgot the header file which did not change but still needs to be in the patch, I guess.
Attachment #62420 - Attachment is obsolete: true
Interesting idea. Why do we need to set up the window in DidReflow at all? We will do it anyway in Paint method. No need to do it twice. This should be true for windowless plugins (windowed plugins still need it here) and for Mac in general! Patrick? Peter?
Attached patch patch v.5Splinter Review
I need massive opinions on this one to make sure I was not too radical. I removed a bunch of code from DidReflow and return early from it on Mac (always) and on Windows (for windowless plugins) relying on the fact that all this window setup action will be correctly done in Paint method.
Attachment #62421 - Attachment is obsolete: true
Serge, would you please try this on Unix to make sure we don't break anything?
it looks good to me, nothing is broken on linux.
Comment on attachment 62479 [details] [diff] [review] patch v.5 r=peterl
Attachment #62479 - Flags: review+
Keywords: edt0.9.4edt0.9.4+
Comment on attachment 62479 [details] [diff] [review] patch v.5 sr=attinasi
Attachment #62479 - Flags: superreview+
In the trunk. Nominating for 0.9.7.
Keywords: patchmozilla0.9.7
In 0.9.4, marking fixed.
Status: ASSIGNED → RESOLVED
Closed: 24 years ago
Keywords: mozilla0.9.7
Resolution: --- → FIXED
Target Milestone: mozilla0.9.7 → ---
Confirmed fixed on mozilla trunk 122603. Ari, could you please confirm the fix as well. Thanks! I have filed http://bugscape.mcom.com/show_bug.cgi?id=11566 for a problem that I see using commercial trunk builds. Cannot berify the fix on the embedding branch unless I get thru that problem.
Ok, Arun clarified that viewpoint might be blocking commercial netscape builds, so I changed the useragent string on commercial branch build and verified this bug. It works fine, the cube is not drawn at (0,0) and appears centered. Verif using 1225 branch build.
Status: RESOLVED → VERIFIED
Keywords: fixed0.9.4
adding keyword 'verified0.9.4'
Keywords: verified0.9.4
Keywords: fixed0.9.4
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: