From 96d78af15cef247c2db8c8895c2bb57f459470f9 Mon Sep 17 00:00:00 2001 From: zuber Date: Tue, 18 Aug 2009 17:03:04 +0200 Subject: [PATCH] =?utf8?q?Dodanie=20mo=C5=BCliwo=C5=9Bci=20ustalania=20skr?= =?utf8?q?=C3=B3t=C3=B3w=20klawiszowych=20(z=20CTRL)=20dla=20przycisk?= =?utf8?q?=C3=B3w=20wstawiaj=C4=85cych=20tagi.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- project/static/js/codemirror/editor.js | 4 +- project/templates/explorer/file_xml.html | 74 +++++++++++++++--------- 2 files changed, 49 insertions(+), 29 deletions(-) diff --git a/project/static/js/codemirror/editor.js b/project/static/js/codemirror/editor.js index b8b7abc8..757d3eaf 100644 --- a/project/static/js/codemirror/editor.js +++ b/project/static/js/codemirror/editor.js @@ -656,7 +656,7 @@ var Editor = (function(){ // Intercept enter and tab, and assign their new functions. keyDown: function(event) { if (this.frozen == "leave") this.frozen = null; - if (this.frozen && (!this.keyFilter || this.keyFilter(event.keyCode))) { + if (this.frozen && (!this.keyFilter || this.keyFilter(event))) { event.stop(); this.frozen(event); return; @@ -734,7 +734,7 @@ var Editor = (function(){ // keydown event does not prevent the associated keypress event // from happening, so we have to cancel enter and tab again // here. - if ((this.frozen && (!this.keyFilter || this.keyFilter(event.keyCode))) || + if ((this.frozen && (!this.keyFilter || this.keyFilter(event))) || event.code == 13 || (event.code == 9 && this.options.tabMode != "default") || (event.keyCode == 32 && event.shiftKey && this.options.tabMode == "default")) event.stop(); diff --git a/project/templates/explorer/file_xml.html b/project/templates/explorer/file_xml.html index e9cd85c0..c23ad41f 100644 --- a/project/templates/explorer/file_xml.html +++ b/project/templates/explorer/file_xml.html @@ -5,15 +5,7 @@ -