Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Fix secondary actions #3252

Merged
merged 1 commit into from
Aug 18, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions js/lib/eventUtil.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,10 @@
* You can obtain one at http://mozilla.org/MPL/2.0/. */

const isDarwin = process.platform === 'darwin'
module.exports.isForSecondaryAction = (e) => {
module.exports.isForSecondaryAction = (e) =>
e.ctrlKey && !isDarwin ||
e.metaKey && isDarwin ||
e.button === 1
}

module.exports.eventElHasAncestorWithClasses = (e, classesToCheck) => {
let node = e.target
Expand Down