extjs - How to get the DOM element for a Sencha Touch draw component -


ext.dom.element has setstyle method

i have ext.component of xtype: 'draw'

when use inspector, can set background image under canvas , draw on top of it.

what can't find way dome element can set background property of draw component.

i've tried:

var x = ext.getcmp('mypanel'); x.setstyle('background', 'url(...)');           // no error, no effect  var y = ext.getcmp('mypanel').down('draw'); y.setstyle('background', 'url(...)');           // no error, no effect 

given ext.component, how dom element object can call right setstyle?

finally found it:

var y = ext.getcmp('mypanel').down('draw'); ext.get(y.element).setstyle('background', 'url(...)') 

Comments

Popular posts from this blog

php - Calling a template part from a post -

Firefox SVG shape not printing when it has stroke -

How to mention the localhost in android -