HomePhorge

Fix submitting forms in a new tab using Ctrl+Return

Description

Fix submitting forms in a new tab using Ctrl+Return

Summary:
This commit adds a keydown listener to <input> elements to activate a flag when
Ctrl (and other keys) are pressed, which causes forms to be submitted to a new
tab.

This commit also modifies the click event listener for buttons to ignore
synthetic clicks from the browser, which is important as they clobber the
"new_tab" flag otherwise.

Closes T15914

Test Plan:
Open the Advanced Search form, and do Ctrl+Return inside one of the text boxes
to ensure that the result is opened in a new tab. Also do a plain Return, plain
click on "Search", and Ctrl+Click on Search to check for regressions.

Reviewers: O1 Blessed Committers, valerio.bozzolan, aklapper

Reviewed By: O1 Blessed Committers, valerio.bozzolan, aklapper

Subscribers: aklapper, tobiaswiese, valerio.bozzolan, Matthew, Cigaryno

Maniphest Tasks: T15914

Differential Revision: https://we.phorge.it/D25773

Details

Provenance
BlankEclairAuthored on Nov 25 2024, 2:06 AM
themackabuPushed on Tue, Mar 25, 8:07 PM
Parents
rPa76444a8e238: Update mimemailparser from May 2011 version to 8.0.4
Branches
Unknown
Tags
Unknown

Event Timeline