this.el.on("click", this.autoSize, this);
}
if(this.el.is('input[type=password]') && Roo.isSafari){
- this.el.on('keypress', this.SafariOnKeyPress, this);
this.el.on('keydown', this.SafariOnKeyDown, this);
-
}
},
},
// private
- safariLastKey : false,
-
- SafariOnKeyPress : function(event){
- this.safariLastChar = event.getCharCode();
- },
-
SafariOnKeyDown : function(event){
var isSelectAll = false;
if(this.el.dom.selectionEnd > 0){
return;
};
if(isSelectAll){ // backspace and delete key
+
event.preventDefault();
- this.setValue(String.fromCharCode(this.safariLastChar));
+ // we cast to lowercase, as that is more
+ this.setValue(String.fromCharCode(
+ this.shiftKey ? event.getKey() : event.getKey().toLowerCase()
+ ));
};
+
}
});
\ No newline at end of file