I’m student with EXTJS4..
First, Please see this code.. This is My Ext.Img Item..
var paddleItem = {
xtype : 'image',
src : "lib/Image/Paddle.png",
x : 0,
y : 0,
draggable : true,
index : 0,
id : 'paddleItem',
name : 'Paddle',
width : 100,
height : 100,
listeners : {
dblclick : {
element : 'el',
fn : function(){
conditionWindow.show();
}
},
click : {
element : 'el',
fn : function(e,t,eOpts) {
propertyForm.items.items[0].setValue('This is My Text');
alert(t.id);
}
}
}
};
When Click This Item, I wanna Get the this Item’s Property(e.g. paddleItem.x, paddleItem.index)
But, There Click’s param ‘t’ is HTML Element.
So, I think.. ‘I get the Item from HTML Element’
But I don’t know how to get…
What can i do for this Problem?
Sorry to My fool English..
If you can’t UnderStand, Please Comment to me..
Thanks!
First of all see what’s the scope of handlers you’re creating. Add the following code before alert function:
And check browser console to see what object is being reported.