#29830
Patrick C
Participant

Example code (formatted version):

#title = "URL open or select"
#icon = "C:\\Windows\\System32\\shell32.dll",135
#tooltip = "URL open or select"
#language = "V8"
#async = "off"

// Self test: https://www.emeditor.com/
// Issue with control + single click:   https://www.emeditor.com/forums/topic/control-click-triggers-double-click/
// PC, Version 1.0

"use strict";

bCtrlDown = shell.GetKeyState( 0x11 ) < 0;
if( bCtrlDown ) {
    // OutputBar.writeln( '"'.concat(document.selection.Text, '"') );
    shell.Run(  "c:\\Program Files\\Vivaldi\\Application\\vivaldi.exe", 1, false, '"'.concat(document.selection.Text, '"')  );
    document.selection.Collapse();
}