PDA

View Full Version : [FIXED][3.x] Ext.EventManager needs createTargeted



mjlecomte
2 Apr 2009, 8:53 AM
Ext.EventManager has:


if(o.target){
h = createTargeted(h, o);
}
if(o.delay){
h = createDelayed(h, o);
}
if(o.single){
h = createSingle(h, el, ename, fn, scope);
}
if(o.buffer){
h = createBuffered(h, o);
}


The other create methods are enclosed, but createTargeted is missing from the class. When executing the code below, the error is:

createTargeted is undefined



<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">

<title>Ext.EventManager</title>

<link rel="stylesheet" type="text/css" href="../../resources/css/ext-all.css" />

<script type="text/javascript" src="../../adapter/ext/ext-base.js"></script>
<script type="text/javascript" src="../../ext-all-debug.js"></script>

<script type="text/javascript">
Ext.onReady(function(){
//el = Ext.get('elId');
el = Ext.get('p2')
el.on('click', function(e, t){
console.info(t);
}, this, {
// filter the target element to be a descendant with the class 'clickable'
//delegate: '.clickable'
target: el.up('div')
});
});
</script>

</head>
<body>
<div id='elId' class'outer-div'>
<p id='p1'>paragraph one</p>
<p id='p2' class='clickable'>paragraph two</p>
<p id='p3'>paragraph three</p>
</div>
</body>
</html>