mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-21 23:21:59 +00:00
Support metaKey
This commit is contained in:
parent
53d0c9fa72
commit
046a4b605c
@ -287,7 +287,7 @@
|
||||
</div>
|
||||
<div id="run_div">
|
||||
<button class="shadow" id="run">Run</button>
|
||||
<span class="hint"> (Ctrl+Enter)</span>
|
||||
<span class="hint"> (Ctrl/Cmd+Enter)</span>
|
||||
<span id="hourglass">⧗</span>
|
||||
<span id="check-mark">✔</span>
|
||||
<span id="stats"></span>
|
||||
@ -424,10 +424,11 @@
|
||||
post();
|
||||
}
|
||||
|
||||
document.onkeypress = function(event)
|
||||
|
||||
document.onkeydown = function(event)
|
||||
{
|
||||
/// Firefox has code 13 for Enter and Chromium has code 10.
|
||||
if (event.ctrlKey && (event.charCode == 13 || event.charCode == 10)) {
|
||||
if ((event.metaKey || event.ctrlKey ) && (event.keyCode == 13 || event.keyCode == 10) ) {
|
||||
post();
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user