javascript - How do I detect a particular child on stage with createjs -


how check if there particular child on stage , how check particular child or b in createjs?

var = new createjs.bitmap('images.a'); var b = new createjs.text('hello','bold 12px arial'); a.settransform(100,100); b.settransform(100,150); stage.addchild(a,b); stage.update(); 

when create child element, give name child can child @ later stage using getchildbyname('childname') method.

var = new createjs.bitmap('images.a'); var b = new createjs.text('hello','bold 12px arial');  a.settransform(100,100); b.settransform(100,150); a.name = "somenamea"; b.name = "somenameb"; stage.addchild(a,b); stage.update();  stage.getchildbyname("somenamea"); 

this assuming child added in module, , want child scope of variable no longer available. otherwise, can use variable identify child.


Comments

Popular posts from this blog

database - VFP Grid + SQL server 2008 - grid not showing correctly -

jquery - Set jPicker field to empty value -

.htaccess - htaccess convert request to clean url and add slash at the end of the url -