Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

Commit

Permalink
Remove delay, should execute only when needed.
Browse files Browse the repository at this point in the history
  • Loading branch information
cheeaun committed Jul 20, 2009
1 parent 2b64adf commit 53923bf
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions Source/MooEditable/MooEditable.js
Expand Up @@ -376,11 +376,8 @@ var MooEditable = new Class({
},

focus: function(){
// needs the delay to get focus working
(function(){
(this.mode == 'iframe' ? this.win : this.textarea).focus();
this.fireEvent('focus', this);
}).delay(10, this);
(this.mode == 'iframe' ? this.win : this.textarea).focus();
this.fireEvent('focus', this);
return this;
},

Expand Down Expand Up @@ -418,7 +415,7 @@ var MooEditable = new Class({
this.iframe.setStyle('display', 'none');
}
this.fireEvent('toggleView', this);
this.focus();
this.focus.delay(10, this);
return this;
},

Expand Down

0 comments on commit 53923bf

Please sign in to comment.