Closed Bug 914609 Opened 8 years ago Closed 8 years ago

Inconsistent references to plugin placeholder elements

Categories

(Firefox :: General, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
Firefox 26

People

(Reporter: neil, Assigned: neil)

References

Details

Attachments

(1 file)

Now that bug 910899 added anonids to the plugin placeholder elements that need it, the front-end code should switch to use it consistently.
Attached patch Proposed patchSplinter Review
Assignee: nobody → neil
Status: NEW → ASSIGNED
Attachment #802283 - Flags: review?(jaws)
Comment on attachment 802283 [details] [diff] [review]
Proposed patch

Review of attachment 802283 [details] [diff] [review]:
-----------------------------------------------------------------

::: browser/base/content/browser-plugins.js
@@ +886,5 @@
>      //
>  
>      // Force a layout flush so the binding is attached.
>      plugin.clientTop;
>      let doc = plugin.ownerDocument;

Can you move the declaration of doc to be closer to its first reference?
Attachment #802283 - Flags: review?(jaws) → review+
Comment on attachment 802283 [details] [diff] [review]
Proposed patch

>     // Force a layout flush so the binding is attached.
>     plugin.clientTop;
>     let doc = plugin.ownerDocument;
>-    let overlay = doc.getAnonymousElementByAttribute(plugin, "class", "mainBox");
>-    let statusDiv = doc.getAnonymousElementByAttribute(plugin, "class", "submitStatus");
>+    let overlay = this.getPluginUI(plugin, "main");
>+    let statusDiv = this.getPluginUI(plugin, "submitStatus");
> #ifdef MOZ_CRASHREPORTER
There are further references after the #ifdef block too, but the the next reference of doc is inside the #ifdef block, so the best I can do is to move it down after the two changed lines.
Yeah that sounds good.
https://hg.mozilla.org/mozilla-central/rev/aa3655d26fce
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → Firefox 26
You need to log in before you can comment on or make changes to this bug.