Revert "Fix: hide colorpicker on mousedown"
This reverts commit 181d9206d9
.
This commit is contained in:
parent
529d2c328c
commit
3c6e2b6f6c
|
@ -9,8 +9,6 @@ function configDialog(style) {
|
|||
const elements = [];
|
||||
const colorpicker = window.colorpicker();
|
||||
|
||||
document.addEventListener('mousedown', onMouseDown);
|
||||
|
||||
buildConfigForm();
|
||||
renderValues();
|
||||
|
||||
|
@ -31,7 +29,6 @@ function configDialog(style) {
|
|||
t('confirmCancel')
|
||||
]
|
||||
}).then(({button, esc}) => {
|
||||
document.removeEventListener('mousedown', onMouseDown);
|
||||
if (button !== 1) {
|
||||
colorpicker.hide();
|
||||
}
|
||||
|
@ -197,10 +194,4 @@ function configDialog(style) {
|
|||
window.addEventListener('keydown', messageBox.listeners.key, true);
|
||||
}
|
||||
}
|
||||
|
||||
function onMouseDown(e) {
|
||||
if (!e.target.closest('.colorpicker-popup')) {
|
||||
colorpicker.hide();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user