Permalink
Browse files

Merge pull request #14 from DrBenton/master

Add "swfClass" getter in SWFLoader  ; this allows multiple instanciation of a loaded SWF content
  • Loading branch information...
Matan committed Aug 6, 2012
2 parents cc7ba18 + 404bf3d commit 16ec695624e6f1d3bfdce9cee8f52a830e05e1b2
Showing with 13 additions and 0 deletions.
  1. +13 −0 src/org/assetloader/loaders/SWFLoader.as
@@ -105,6 +105,19 @@ package org.assetloader.loaders
return _swf;
}
+ /**
+ * Gets the resulting Sprite class after loading is complete.
+ * Allows multiple instanciation of this SWF content.
+ *
+ * @return Class
+ */
+ public function get swfClass() : Class
+ {
+ var swfClassName:String = getQualifiedClassName(_swf);
+ var swfClass:Class = getDefinitionByName(swfClassName) as Class;
+ return swfClass;
+ }
+
/**
* Dispatched when the properties and methods of a loaded SWF file are accessible and ready for use.
*

0 comments on commit 16ec695

Please sign in to comment.