X-Git-Url: https://git.mdrn.pl/redakcja.git/blobdiff_plain/32ee10aaf4c035a199a96c06bd2506befed5e17f..8da57c41af2d69702bbc23c7a64adc6f102d2bcd:/src/redakcja/static/js/wiki/loader.js diff --git a/src/redakcja/static/js/wiki/loader.js b/src/redakcja/static/js/wiki/loader.js index e9cf2b1a..adc2cb42 100644 --- a/src/redakcja/static/js/wiki/loader.js +++ b/src/redakcja/static/js/wiki/loader.js @@ -119,6 +119,17 @@ $(function() { CurrentDocument.active = new Date(); }); + $(window).keydown(function(e) { + if (e.ctrlKey || e.metaKey) { + switch (e.key) { + case 's': + e.preventDefault(); + $("#save-button").click(); + break; + } + } + }); + console.log("Fetching document's text"); $(document).bind('wlapi_document_changed', function(event, doc) {