Last active
December 21, 2015 13:59
-
-
Save jarkkosyrjala/6316791 to your computer and use it in GitHub Desktop.
Enabling instance names (.name property) in JavaScript library exported from Flash Professional / Toolkit for CreateJS.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var someContainer=new lib.SomeContainer(); | |
for(var childName in someContainer){ | |
if(someContainer[childName] instanceof createjs.DisplayObject) { | |
someContainer[childName].name=childName; | |
console.log(childName+" now has a name!!"); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment