Closed Bug 515213 Opened 12 years ago Closed 12 years ago
Need to handle DOMWill
Open Modal Dialog
Otherwise background tabs can open alerts over the selected tab.
Assignee: nobody → gavin.sharp
(bug 277574 is the original core/firefox bug)
also bug 262887
Comment on attachment 401975 [details] [diff] [review] Implement by adding event listener in _createBrowser Can you add the listener here: http://mxr.mozilla.org/mobile-browser/source/chrome/content/browser-ui.js#389 Add the handler as a member of BrowserUI. Drop the | let targetTop = new XPCNativeWrapper(e.target, "top").top; | and use | let targetTop = event.target.top; | that the newest tabbrowser.xml code uses: http://mxr.mozilla.org/mozilla-central/source/browser/base/content/tabbrowser.xml#2784
Attachment #401975 - Flags: review?(gavin.sharp) → review-
Oh, here is a piece of bad news: "DOMWillOpenModalDialog" and "DOMModalDialogClosed" are fired by nsAutoWindowStateHelper found here: http://mxr.mozilla.org/mozilla-central/source/embedding/components/windowwatcher/src/nsAutoWindowStateHelper.cpp#52 Which is heavily used in nsPromptService: http://mxr.mozilla.org/mozilla-central/ident?i=nsAutoWindowStateHelper Of course, Fennec overrides the nsPromptService and doesn't currently fire the event :(
Let's get this patch ready for listening and handling the event. We can open another bug for firing the event. Filed bug 518054
Cool, I did not know addEventListener will call handleEvent on an object.
Attachment #403494 - Flags: review?(mark.finkle) → review+
pushed: https://hg.mozilla.org/mobile-browser/rev/a5c85d5f25a2 This still needs bug 518054 to work completely.
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.