<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	>
<channel>
	<title>Comments on: What Happened to _global?</title>
	<atom:link href="http://www.taterboy.com/blog/2008/04/what-happened-to-_global/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.taterboy.com/blog/2008/04/what-happened-to-_global/</link>
	<description>FLASH :: FLEX :: AIR :: ILLUSTRATION :: ANIMATION :: WEB DEVELOPMENT</description>
	<pubDate>Fri, 30 Jul 2010 06:37:25 +0000</pubDate>
	<generator>http://wordpress.org/?v=abc</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: taterboy</title>
		<link>http://www.taterboy.com/blog/2008/04/what-happened-to-_global/comment-page-1/#comment-212</link>
		<dc:creator>taterboy</dc:creator>
		<pubDate>Sun, 01 Feb 2009 18:18:57 +0000</pubDate>
		<guid isPermaLink="false">http://taterboy.com/blog/?p=3#comment-212</guid>
		<description>Good catch, I should have added import globalEvent. Technically with the class files being in the same directory as the fla, I really did not need to add import globalEvent or import global except for good documentation.

There are two classes being used, one is "global" to handle variables and "globalEvent" to handle events. It was incosistant of me not to import both, sorry.

Thanks for keeping me honest.</description>
		<content:encoded><![CDATA[<p>Good catch, I should have added import globalEvent. Technically with the class files being in the same directory as the fla, I really did not need to add import globalEvent or import global except for good documentation.</p>
<p>There are two classes being used, one is &#8220;global&#8221; to handle variables and &#8220;globalEvent&#8221; to handle events. It was incosistant of me not to import both, sorry.</p>
<p>Thanks for keeping me honest.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: anym</title>
		<link>http://www.taterboy.com/blog/2008/04/what-happened-to-_global/comment-page-1/#comment-209</link>
		<dc:creator>anym</dc:creator>
		<pubDate>Sat, 31 Jan 2009 21:51:32 +0000</pubDate>
		<guid isPermaLink="false">http://taterboy.com/blog/?p=3#comment-209</guid>
		<description>isnt import globalEvent instead of import global in your example?</description>
		<content:encoded><![CDATA[<p>isnt import globalEvent instead of import global in your example?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: taterboy</title>
		<link>http://www.taterboy.com/blog/2008/04/what-happened-to-_global/comment-page-1/#comment-153</link>
		<dc:creator>taterboy</dc:creator>
		<pubDate>Mon, 13 Oct 2008 17:11:06 +0000</pubDate>
		<guid isPermaLink="false">http://taterboy.com/blog/?p=3#comment-153</guid>
		<description>Event is an existing Class (flash.events.Event). A class is made up of a Public Class and a public Function within the class of the same name. This function is the constructor of the class. When the class is called or an new instance of the class is initiated, this public function is executed. Classes can be completely custom or extensions of an existing class.

For this example I wanted to show how you can add properties to the Event class. If we look up Event in the help we can see all the existing properties (public and private), methods and events. We should not modify the Event class itself, so we choose to extend it. When we add "extends Event" we are telling flash we have new class, but instead of rewriting the entire Event class over we want to add to it's functionality; something that will work better with our application. This is actually called a "sub class", not technically custom but customized.

The super part is a call directly to the Event class from within our subclass. So when this event is fired, we pass in some data and set our new properties and fire off the parent or super class that has all the functionality we need.  Some subclasses do not need to call super "legoClip" class from above.

You can fire a custom event a lot easier then extending the event class. Just put dispatchEvent(new Event("SOME_EVENT",true)); Add ",true" if you want the event to bubble up to a higher object, if you just want the event within the object that fired it, then leave it out. You will need to add an addEventListener("SOME_EVENT", eventHandler); where ever you want to handle the event, from there you can still get basic event functionality. like event.target and event.type.

Hope this helps.</description>
		<content:encoded><![CDATA[<p>Event is an existing Class (flash.events.Event). A class is made up of a Public Class and a public Function within the class of the same name. This function is the constructor of the class. When the class is called or an new instance of the class is initiated, this public function is executed. Classes can be completely custom or extensions of an existing class.</p>
<p>For this example I wanted to show how you can add properties to the Event class. If we look up Event in the help we can see all the existing properties (public and private), methods and events. We should not modify the Event class itself, so we choose to extend it. When we add &#8220;extends Event&#8221; we are telling flash we have new class, but instead of rewriting the entire Event class over we want to add to it&#8217;s functionality; something that will work better with our application. This is actually called a &#8220;sub class&#8221;, not technically custom but customized.</p>
<p>The super part is a call directly to the Event class from within our subclass. So when this event is fired, we pass in some data and set our new properties and fire off the parent or super class that has all the functionality we need.  Some subclasses do not need to call super &#8220;legoClip&#8221; class from above.</p>
<p>You can fire a custom event a lot easier then extending the event class. Just put dispatchEvent(new Event(&#8221;SOME_EVENT&#8221;,true)); Add &#8220;,true&#8221; if you want the event to bubble up to a higher object, if you just want the event within the object that fired it, then leave it out. You will need to add an addEventListener(&#8221;SOME_EVENT&#8221;, eventHandler); where ever you want to handle the event, from there you can still get basic event functionality. like event.target and event.type.</p>
<p>Hope this helps.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: JD</title>
		<link>http://www.taterboy.com/blog/2008/04/what-happened-to-_global/comment-page-1/#comment-152</link>
		<dc:creator>JD</dc:creator>
		<pubDate>Mon, 13 Oct 2008 04:27:01 +0000</pubDate>
		<guid isPermaLink="false">http://taterboy.com/blog/?p=3#comment-152</guid>
		<description>Thanks for the rundown. Public static vars have made my life a lot easier now and then. One thing I'm a little lost on is your custom event. How does a public function in a class that extends Event equal up to a custom event? Plus the whole super thing still eludes me. Nonetheless, I learned some!</description>
		<content:encoded><![CDATA[<p>Thanks for the rundown. Public static vars have made my life a lot easier now and then. One thing I&#8217;m a little lost on is your custom event. How does a public function in a class that extends Event equal up to a custom event? Plus the whole super thing still eludes me. Nonetheless, I learned some!</p>
]]></content:encoded>
	</item>
</channel>
</rss>
