Closed Bug 315434 Opened 19 years ago Closed 19 years ago

Security error with remote <xul:tabbox>: can't switch tabs if chrome has focus

Categories

(Toolkit :: UI Widgets, defect, P2)

defect

Tracking

()

RESOLVED FIXED
mozilla1.9alpha1

People

(Reporter: mrbkap, Assigned: mrbkap)

References

()

Details

(Keywords: fixed1.8.1, regression, verified1.8.0.1)

Attachments

(1 file)

STEPS TO REPRODUCE:
0. Make sure the browser's tab bar is visible.
1. Load the testcase in the URL.
2. Focus a tab in the content.
3. Click on the active browser tab (the one with the testcase loaded), this should give you a focus rectangle around it.
4. Click on a non-selected tab in the content area.

ACTUAL RESULTS: The new tab is not selected; a security error appears in the JS console.
EXPECTED RESULTS: The new tab is selected.
Attached patch Use try/catchSplinter Review
In the case that focusedElement would throw, our tab would not be selected.
Attachment #202132 - Flags: first-review?(mconnor)
Attachment #202132 - Flags: first-review?(mconnor) → first-review+
Sadly, this missed Firefox 1.5. Hoping this can hit 1.8.1, though.
Status: NEW → ASSIGNED
Flags: blocking1.8.1?
Priority: -- → P2
Target Milestone: --- → mozilla1.9alpha1
Fix checked into trunk.
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Summary: Security error on remote XUL → Security error with remote <xul:tabbox>: can't switch tabs if chrome has focus
*** Bug 317356 has been marked as a duplicate of this bug. ***
*** Bug 317434 has been marked as a duplicate of this bug. ***
Making note of the error so that this bug is easier to find:
Error: uncaught exception: [Exception... "Security error"  code: "1000" nsresult: "0x805303e8 (NS_ERROR_DOM_SECURITY_ERR)"  location: "chrome://global/content/bindings/tabbox.xml Line: 344"]
*** Bug 320427 has been marked as a duplicate of this bug. ***
Flags: blocking1.8.0.1?
*** Bug 319309 has been marked as a duplicate of this bug. ***
Comment on attachment 202132 [details] [diff] [review]
Use try/catch

This is a low-risk fix (only affects remote XUL) that fixes bugs in remote XUL that is impossible to work around on the content side.
Attachment #202132 - Flags: approval1.8.0.1?
Comment on attachment 202132 [details] [diff] [review]
Use try/catch

a=dveditz for drivers
Attachment #202132 - Flags: approval1.8.1+
Attachment #202132 - Flags: approval1.8.0.1?
Attachment #202132 - Flags: approval1.8.0.1+
Blake, can you get this checked in?
Flags: blocking1.8.1?
Flags: blocking1.8.1+
Flags: blocking1.8.0.1?
Flags: blocking1.8.0.1+
Fix checked into the branches.
Verified fixed on the branch using Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.1) Gecko/20060111 Firefox/1.5.0.1. Following Blake's excellent STR, I do not see a security error in the JS console and the tab is correctly selected.
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: