1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-03-26 21:12:59 +02:00

Desktop: Fixes #3287: Disable middle-clicking external URLs, as they would open inside the application

This commit is contained in:
Laurent Cozic 2020-06-03 18:34:00 +01:00
parent 0ee370303c
commit da77de0a08

View File

@ -419,6 +419,12 @@
updateBodyHeight();
}));
// Prevent middle-click as that would open the URL in an Electron window
// https://github.com/laurent22/joplin/issues/3287
window.addEventListener('auxclick', webviewLib.logEnabledEventHandler((event) => {
event.preventDefault();
}));
updateBodyHeight();
} catch (error) {
ipcProxySendToHost('error:' + JSON.stringify(webviewLib.cloneError(error)));