Closed
Bug 746640
Opened 13 years ago
Closed 2 months ago
Popup window.open() blocked when called from a key-related event listener
Categories
(Core :: DOM: Core & HTML, defect, P3)
Tracking
()
RESOLVED
FIXED
People
(Reporter: kloots, Unassigned)
References
(Depends on 1 open bug)
Details
(Keywords: access, parity-chrome, parity-safari)
Attachments
(2 files, 1 obsolete file)
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_3) AppleWebKit/534.55.3 (KHTML, like Gecko) Version/5.1.5 Safari/534.55.3
Steps to reproduce:
I'm adding keyboard shortcuts for an application. These shortcuts are for sharing news articles on Facebook, Twitter, etc. Each shortcut makes a call to window.open() to popup a window to the associated services sharing page.
Actual results:
The popup window initiated from the call to window.open() is blocked when called from a key-related (keypress, keydown, or keyup) event listener.
Expected results:
The popup window should not have been blocked in my opinion. The call to window.open() was initiated from a real user action. And Firefox doesn't block popups called from within a "click" event listener for example. So, it seems like they should not be blocked when called from within a key-related event listener.
Reporter | ||
Comment 1•13 years ago
|
||
One additional note: I've noticed that popup windows aren't blocked when the call to window.open() originates from a key event in Webkit.
Updated•13 years ago
|
Status: UNCONFIRMED → NEW
Component: Untriaged → General
Ever confirmed: true
Keywords: access
QA Contact: untriaged → general
Whiteboard: [parity webkit]
Comment 2•8 years ago
|
||
This should be an issue of DOM component.
Component: General → DOM: Core & HTML
Product: Firefox → Core
Whiteboard: [parity webkit] → [parity-blink][parity-webkit]
Comment 3•8 years ago
|
||
And this is a simplified testcase shows that Firefox bans window.open in keypress event.
Comment 4•8 years ago
|
||
FWIW, there is https://www.w3.org/TR/html5/browsers.html#allowed-to-show-a-popup in W3C spec, but I can't seem to find similar in HTML spec around https://html.spec.whatwg.org/#browsing-context-names
Comment 5•8 years ago
|
||
The list in WHATWG's HTML spec is https://html.spec.whatwg.org/multipage/interaction.html#triggered-by-user-activation and there is some discussion here: https://github.com/whatwg/html/issues/1903#issuecomment-260112697
Comment 6•7 years ago
|
||
Mass bug change to replace various 'parity' whiteboard flags with the new canonical keywords. (See bug 1443764 comment 13.)
Keywords: parity-chrome,
parity-safari
Whiteboard: [parity-blink][parity-webkit]
Updated•7 years ago
|
Priority: -- → P3
Updated•2 years ago
|
Severity: normal → S3
Updated•11 months ago
|
Attachment #9383497 -
Attachment is obsolete: true
Comment 8•3 months ago
|
||
Like bug 1863217, the bug 746640 testcase works after enabling dom.popup.experimental
(enabled in Nightly as of bug 1911736).
Depends on: 1656444
Updated•2 months ago
|
Attachment #616194 -
Attachment mime type: text/plain → text/html
Comment 9•2 months ago
|
||
Close per comment #8. Thanks for verifying this, Zach!
Status: NEW → RESOLVED
Closed: 2 months ago
Resolution: --- → FIXED
Comment 10•2 months ago
|
||
You bet!
You need to log in
before you can comment on or make changes to this bug.
Description
•