Roo/form/HtmlEditor.js
authorEdward <edward@roojs.com>
Mon, 8 Jun 2015 08:40:55 +0000 (16:40 +0800)
committerEdward <edward@roojs.com>
Mon, 8 Jun 2015 08:40:55 +0000 (16:40 +0800)
Roo/form/HtmlEditor.js

index 5945bf6..cb89eab 100644 (file)
@@ -260,7 +260,7 @@ Roo.extend(Roo.form.HtmlEditor, Roo.form.Field, {
         this.keyNav = new Roo.KeyNav(this.el, {
             
             "tab" : function(e){
-                Roo.log(e);
+                
                 e.preventDefault();
                 Roo.log('TAB');
                 
@@ -269,9 +269,15 @@ Roo.extend(Roo.form.HtmlEditor, Roo.form.Field, {
                 var start = this.el.dom.selectionStart;
                 var end = this.el.dom.selectionEnd;
                 
-                this.setValue(value.substring(0, start) + "\t" + value.substring(end));
+                if(!e.shiftKey){
+                    this.setValue(value.substring(0, start) + "\t" + value.substring(end));
+                
+                    this.el.dom.setSelectionRange(end + 1, end + 1);
+                    return;
+                }
+                
+                
                 
-                this.el.dom.setSelectionRange(end + 1, end + 1);
             },
             
             "home" : function(e){