Permalink
Browse files

Fixing multi-pseudo demo: pressing any character then enter produced …

…weird results. Also using correct element, not the one that happened to be right
  • Loading branch information...
1 parent b659f4e commit 94a64e99700d609d09f46669e8fbafc044ceecc9 @asuth asuth committed with arian Jun 25, 2011
Showing with 2 additions and 2 deletions.
  1. +2 −2 demos/Element.Event.Pseudos/demo.js
@@ -23,8 +23,8 @@ window.addEvent('domready', function() {
});
// use multiple pseudos
- $('multiplePseudoText').addEvent('keydown:relay(textarea):keys(enter):once', function(){
- this.getElement('textarea').set('value', 'MooTools!!').highlight();
+ $('multiplePseudoText').addEvent('keydown:relay(textarea):keys(enter):once', function(event, el){
+ el.set('value', 'MooTools!!').highlight();
});
// pause pseudo event, you can define the pause, otherwise it will use the default (250)

0 comments on commit 94a64e9

Please sign in to comment.