<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" 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/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>CWi Labs :: jloa's blog :: Open source projects, snippets, notes, thoughts, flash, flex, air, as3, js</title>
	
	<link>http://chargedweb.com/labs</link>
	<description>Open source projects, snippets, notes, thoughts, flash, flex, air, as3, js</description>
	<lastBuildDate>Tue, 03 Jan 2012 13:49:59 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/jloa_labs" /><feedburner:info uri="jloa_labs" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><feedburner:browserFriendly></feedburner:browserFriendly><item>
		<title>Occupy wha?</title>
		<link>http://chargedweb.com/labs/2011/11/17/occupy-wha/</link>
		<comments>http://chargedweb.com/labs/2011/11/17/occupy-wha/#comments</comments>
		<pubDate>Thu, 17 Nov 2011 11:48:30 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[misc]]></category>
		<category><![CDATA[thoughts]]></category>
		<category><![CDATA[Flash]]></category>
		<category><![CDATA[fun]]></category>
		<category><![CDATA[html]]></category>
		<category><![CDATA[lol]]></category>
		<category><![CDATA[occupy]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=932</guid>
		<description><![CDATA[occupy html vs occupy flash LOL, i&#8217;m waiting for a same java site from c# devs]]></description>
			<content:encoded><![CDATA[<p><img title="occupy html" src="http://occupyhtml.org/images/logo-redux.png" alt="" width="400" height="257" /><br />
<br/><br/><br/><br />
<a href="http://occupyhtml.org/"><strong>occupy html</strong></a> vs <a href="http://www.occupyflash.org/"><strong>occupy flash</strong></a> LOL, i&#8217;m waiting for a same java site from c# devs <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
 <p><a href="http://chargedweb.com/labs/?flattrss_redirect&amp;id=932&amp;md5=a86ead4e4e726c84d9d8707b93115e17" title="Flattr" target="_blank"><img src="http://chargedweb.com/labs/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2011/11/17/occupy-wha/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Queue class (upd v.1.2)</title>
		<link>http://chargedweb.com/labs/2011/10/02/queue-class/</link>
		<comments>http://chargedweb.com/labs/2011/10/02/queue-class/#comments</comments>
		<pubDate>Sun, 02 Oct 2011 22:34:04 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[queue]]></category>
		<category><![CDATA[stack]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=891</guid>
		<description><![CDATA[Sometimes you need to do a bunch of similar tasks at once (create similar display objects, render stuff, reindex pools etc), but often this may be a pain due to performance limits (which may result in poor user experience) and that&#8217;s where the queue pattern comes to the rescue. I&#8217;ve wrote a simple thought useful [...]]]></description>
			<content:encoded><![CDATA[<p><img class="size-full wp-image-901" title="queue" src="http://chargedweb.com/labs/files/2011/10/queue.png" alt="" width="240" height="220" /></p>
<p>Sometimes you need to do a bunch of similar tasks at once (create similar display objects, render stuff, reindex pools etc), but often this may be a pain due to performance limits (which may result in poor user experience) and that&#8217;s where the queue pattern comes to the rescue. I&#8217;ve wrote a simple thought useful util for that purpose.</p>
<p>Play with the demo below (a simple IQueueItem implementation) or <a href="http://chargedweb.com/labs/files/com.chargedweb.zip">download the source (com.chargedweb.queue.*)</a><br />
<br/><br />
<strong><span style="color: #ff0000;">UPDATE:</span> v.1.2 update + docs updated</strong><br/><br />
<br/><br />
<object width="550" height="400" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowFullScreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://chargedweb.com/labs/files/2011/10/queue.swf" /><param name="allowfullscreen" value="true" /><embed width="550" height="400" type="application/x-shockwave-flash" src="http://chargedweb.com/labs/files/2011/10/queue.swf" allowFullScreen="true" allowscriptaccess="always" allowfullscreen="true" /></object></p>
 <p><a href="http://chargedweb.com/labs/?flattrss_redirect&amp;id=891&amp;md5=30feab0f3f0d989b0daf7895f41c39d4" title="Flattr" target="_blank"><img src="http://chargedweb.com/labs/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2011/10/02/queue-class/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Which mobile os do you prefer?</title>
		<link>http://chargedweb.com/labs/2011/09/09/mobile-os-prefer/</link>
		<comments>http://chargedweb.com/labs/2011/09/09/mobile-os-prefer/#comments</comments>
		<pubDate>Fri, 09 Sep 2011 23:27:58 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[misc]]></category>
		<category><![CDATA[mobile]]></category>
		<category><![CDATA[os]]></category>
		<category><![CDATA[poll]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=883</guid>
		<description><![CDATA[I&#8217;m just curious, which mobile os do you personally prefer more in yr everyday life (leave aside fp, miniusb etc)? ps: no holy wars plz guys ^_^]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m just curious, which mobile os do you personally prefer more in yr everyday life (leave aside fp, miniusb etc)?<br />
Note: There is a poll embedded within this post, please visit the site to participate in this post's poll.</p>
<p>ps: no holy wars plz guys ^_^</p>
 <p><a href="http://chargedweb.com/labs/?flattrss_redirect&amp;id=883&amp;md5=59f71470549370c979b3a51b64a64a02" title="Flattr" target="_blank"><img src="http://chargedweb.com/labs/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2011/09/09/mobile-os-prefer/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>A fast trick to lighten/darken colors</title>
		<link>http://chargedweb.com/labs/2011/09/09/fast-trick-lightendarken-colors/</link>
		<comments>http://chargedweb.com/labs/2011/09/09/fast-trick-lightendarken-colors/#comments</comments>
		<pubDate>Fri, 09 Sep 2011 15:21:28 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[brightness]]></category>
		<category><![CDATA[color]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=868</guid>
		<description />
			<content:encoded><![CDATA[<p><!--<script type="text/javascript" src="http://wonderfl.net/blogparts/rU4n/js"></script>--!><br />
<a href="http://wonderfl.net/c/rU4n">Running example</a></p>
<pre class="brush: as3; ">

/**
 * Scales r-g-b channels by &#039;scale&#039; factor, having the r-g-b proportions saved
 * @param	color:uint		color to be scaled (i.e. lighten or darken)
 * @param	scale:Number	the scale factor (values -1 to 1) -1 = absolute dark; 1 = absolute light;
 * @return	uint			scaled color
 */
function scaleColor(color:uint, scale:Number):uint
{
	var r:int = (color &amp;amp;amp;amp;amp; 0xFF0000) &gt;&gt; 16;
	var g:int = (color &amp;amp;amp;amp;amp; 0x00FF00) &gt;&gt; 8;
	var b:int = color &amp;amp;amp;amp;amp; 0x0000FF;
	r += (255 * scale)*(r/(r+g+b)); r = (r &gt; 255) ? 255 : r; r = (r &lt; 0) ? 0 : r;
	g += (255 * scale)*(g/(r+g+b)); g = (g &gt; 255) ? 255 : g; g = (g &lt; 0) ? 0 : g;
	b += (255 * scale)*(b/(r+g+b)); b = (b &gt; 255) ? 255 : b; b = (b &lt; 0) ? 0 : b;
	return (r &lt;&lt; 16 &amp;amp;amp;amp;amp; 0xff0000) + (g &lt;&lt; 8 &amp;amp;amp;amp;amp; 0x00ff00) + (b &amp;amp;amp;amp;amp; 0x0000ff);
}
</pre>
<p><a href="http://wonderfl.net/c/rU4n" target="_blank">View the complete source code</a></p>
 <p><a href="http://chargedweb.com/labs/?flattrss_redirect&amp;id=868&amp;md5=33c35bbd03058d23317d502baa6ef75d" title="Flattr" target="_blank"><img src="http://chargedweb.com/labs/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2011/09/09/fast-trick-lightendarken-colors/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Google swiffy</title>
		<link>http://chargedweb.com/labs/2011/06/29/google-swiffy/</link>
		<comments>http://chargedweb.com/labs/2011/06/29/google-swiffy/#comments</comments>
		<pubDate>Wed, 29 Jun 2011 21:48:06 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[misc]]></category>
		<category><![CDATA[news]]></category>
		<category><![CDATA[converter]]></category>
		<category><![CDATA[Flash]]></category>
		<category><![CDATA[google]]></category>
		<category><![CDATA[html5]]></category>
		<category><![CDATA[swiffy]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=851</guid>
		<description><![CDATA[The news about the new &#8220;flash killer&#8221; (adobe shared the wallaby source code to google or it&#8217;s just a clone?) flew over around the web (even Lee Brimelow posted about it). So i&#8217;ve decided to check it out and see it myself. So, i made a simple as2 movie compiled for fp6 ( they recommend [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.google.com/images/logos/swiffy_logo.gif" alt="swiffy" /><br />
<br/></p>
<p>The news about the new &#8220;flash killer&#8221; (adobe shared the <a href="http://labs.adobe.com/downloads/wallaby.html">wallaby</a> source code to google or it&#8217;s just a clone?) flew over around the web (even <a href="http://blog.theflashblog.com/?p=2787#comment-767381">Lee Brimelow</a> posted about it). So i&#8217;ve decided to check it out and see it myself.<br />
So, i made a simple as2 movie compiled for fp6 ( they recommend version below 8 ) to see if swiffy could manage to convert it.</p>
<p><strong>Original as2 movie</strong> <a href="http://chargedweb.com/labs/files/2011/06/fp6.as2.swf">http://chargedweb.com/labs/files/2011/06/fp6.as2.swf</a></p>
<p><strong>Swiffy output</strong> <a href="http://chargedweb.com/labs/files/2011/06/fp6.as2.html">http://chargedweb.com/labs/files/2011/06/fp6.as2.html</a></p>
<p>it&#8217;s you to comment&#8230;</p>
 <p><a href="http://chargedweb.com/labs/?flattrss_redirect&amp;id=851&amp;md5=3fffaef66b69bf933201afbcf53a2403" title="Flattr" target="_blank"><img src="http://chargedweb.com/labs/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2011/06/29/google-swiffy/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>Howdy mister JointStyle.MITER</title>
		<link>http://chargedweb.com/labs/2011/05/30/howdy-mister-jointstylemiter/</link>
		<comments>http://chargedweb.com/labs/2011/05/30/howdy-mister-jointstylemiter/#comments</comments>
		<pubDate>Mon, 30 May 2011 11:46:59 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[bug]]></category>
		<category><![CDATA[fp]]></category>
		<category><![CDATA[graphics]]></category>
		<category><![CDATA[jointstyle]]></category>
		<category><![CDATA[mitter]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=834</guid>
		<description><![CDATA[Do you like sharp border corners (miter ones)? Well, i do, but adobe does not, probably&#8230; (watch the third square with JointStyle.MITER joints set) ps: yeap, the issue can be fixed by setting the LineScaleMode.NORMAL, instead of the NONE, but what if i do need the NONE mode on? Try it out yourself: package { [...]]]></description>
			<content:encoded><![CDATA[<p><img title="mitter.bug" src="http://chargedweb.com/labs/files/2011/05/mitter.bug_-150x150.png" alt="" width="150" height="150" /><br />
<br/><br />
Do you like sharp border corners (miter ones)?<br />
Well, i do, but adobe does not, probably&#8230; (watch the third square with JointStyle.MITER joints set)<br/><br/><br />
ps: yeap, the issue can be fixed by setting the <strong>LineScaleMode.NORMAL</strong>, instead of the <strong>NONE</strong>, but what if i do need the <strong>NONE</strong> mode on?<br />
<br/><br />
<span id="more-834"></span><br />
<object width="400" height="400"><param name="movie" value="http://www.youtube.com/v/DUWo19BcC7s&amp;hl=en_GB&amp;fs=1&amp;" /><param name="allowFullScreen" value="true" /><param name="allowscriptaccess" value="always" /><embed type="application/x-shockwave-flash" width="400" height="400" src="http://chargedweb.com/labs/files/2011/05/MitterBug.swf" allowfullscreen="true" allowscriptaccess="always"></embed></object></p>
<p>Try it out yourself:</p>
<pre class="brush: as3; ">

package
{
	import flash.display.MovieClip;
	import flash.display.Graphics;
	import flash.display.Shape;
	import flash.display.JointStyle;
	import flash.display.CapsStyle;
	import flash.display.LineScaleMode;
	import flash.events.Event;

	[SWF(width=&quot;400&quot;, height=&quot;400&quot;, frameRate=&quot;50&quot;)]
	public class MitterBug extends MovieClip
	{
		var inc:Boolean = true;
		var b:int = 1;
		var jointStyles:Array = [JointStyle.BEVEL, JointStyle.ROUND, JointStyle.MITER];	// MITTER&#039;s buggy

		public function MitterBug()
		{
			if(stage) init();
			else addEventListener(Event.ADDED_TO_STAGE, init);
		}

		private function init(event:Event = null):void
		{
			var n:int = jointStyles.length;
			for(var i = 0; i &lt; n; ++i) addChild(new Shape());
			addEventListener(Event.ENTER_FRAME, onEnterFrameHandler);
		}

		private function redrawRect(g:Graphics, b:int, j:String, w:int, h:int):void
		{
			g.clear();
			g.lineStyle(b, 0, 1, true, LineScaleMode.NONE, CapsStyle.NONE, j);
			g.beginFill(0xff0000, 1);
			g.drawRect(0, 0, w, h);
			g.endFill();
		}

		private function onEnterFrameHandler(event:Event):void
		{
			if(b == 50) 	inc = false;	// increase &#039;til 50
			if(b == 0)		inc = true;		// decrease &#039;til 0

			if(inc) b++;
			else b--;

			var n:int = jointStyles.length;

			for(var i = 0; i &lt; n; ++i)
			{
				var s:Shape = getChildAt(i) as Shape;
				s.rotation++;
				s.x = 200;
				s.y = 70 + i*120;
				redrawRect(s.graphics, b, jointStyles[i], 40, 40);
			}
		}
	}
}
</pre>
 <p><a href="http://chargedweb.com/labs/?flattrss_redirect&amp;id=834&amp;md5=0285d8c259cef5b17f5f2db8602b50af" title="Flattr" target="_blank"><img src="http://chargedweb.com/labs/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2011/05/30/howdy-mister-jointstylemiter/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Around the world trip or greets from Russia</title>
		<link>http://chargedweb.com/labs/2011/05/18/around-the-world-trip/</link>
		<comments>http://chargedweb.com/labs/2011/05/18/around-the-world-trip/#comments</comments>
		<pubDate>Wed, 18 May 2011 13:53:09 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[misc]]></category>
		<category><![CDATA[news]]></category>
		<category><![CDATA[around the world]]></category>
		<category><![CDATA[kemo]]></category>
		<category><![CDATA[oleg]]></category>
		<category><![CDATA[russia]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=814</guid>
		<description><![CDATA[A russian partner of mine Oleg Radul (CEO of the Kemo LLC) is starting his trip around the world on his Mitsubishi L200 So, if u r open to meeting new people from far away, keep track of his blog to catch him up in your city to get together and have some beer ^_^ [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://chargedweb.com/labs/files/2011/05/around.world_.png" alt="" title="around the world trip" width="160" height="165" /><br />
<br/><br />
A russian partner of mine <a href="http://translate.google.com/translate?hl=ru&amp;sl=ru&amp;tl=en&amp;u=http://radul.ru/">Oleg Radul</a> (CEO of the <a href="http://kemo.ru/">Kemo LLC</a>) is starting his trip around the world on his Mitsubishi L200 <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
So, if u r open to meeting new people from far away, keep track of his blog to catch him up in your city to get together and have some beer ^_^<br />
<br/><br />
Most important &mdash; here&#8217;s his route (clickable):<br/><br />
<a href="http://translate.googleusercontent.com/translate_c?hl=ru&amp;rurl=translate.google.com&amp;sl=ru&amp;tl=en&amp;u=http://radul.ru/route/&amp;usg=ALkJrhh3neesROhgiKdGY9doGjQeRfbhdA"><img class="alignnone" title="Oleg's around the world trip route" src="http://img-fotki.yandex.ru/get/5304/olegradul.9/0_5463f_5fd1224e_XXL.jpg" alt="" width="601" height="187" /></a><br />
<br/><br/><br />
ps: more about the trip in his blog (thank u google ^_^)</p>
 <p><a href="http://chargedweb.com/labs/?flattrss_redirect&amp;id=814&amp;md5=8dd95f2fac893591ea41562931deedcb" title="Flattr" target="_blank"><img src="http://chargedweb.com/labs/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2011/05/18/around-the-world-trip/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>as3scorm updated</title>
		<link>http://chargedweb.com/labs/2011/04/18/as3scorm-updated/</link>
		<comments>http://chargedweb.com/labs/2011/04/18/as3scorm-updated/#comments</comments>
		<pubDate>Mon, 18 Apr 2011 07:29:41 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[as3scorm]]></category>
		<category><![CDATA[scorm]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=810</guid>
		<description><![CDATA[Just a short post to let you know, that i&#8217;ve updated the as3scorm lib (simple course example added). Might be useful to get started with the lib fast.]]></description>
			<content:encoded><![CDATA[<p>Just a short post to let you know, that i&#8217;ve updated the <a href="http://chargedweb.com/labs/2011/02/01/scorm-122004-as3-implementation/">as3scorm</a> lib (simple course example added).<br />
Might be useful to get started with the lib fast.</p>
 <p><a href="http://chargedweb.com/labs/?flattrss_redirect&amp;id=810&amp;md5=73dffd2a30beaaf46cc9b81100893f14" title="Flattr" target="_blank"><img src="http://chargedweb.com/labs/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2011/04/18/as3scorm-updated/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MAXRacer live</title>
		<link>http://chargedweb.com/labs/2011/03/01/maxracer-live/</link>
		<comments>http://chargedweb.com/labs/2011/03/01/maxracer-live/#comments</comments>
		<pubDate>Tue, 01 Mar 2011 19:47:40 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[thoughts]]></category>
		<category><![CDATA[alternativa]]></category>
		<category><![CDATA[max]]></category>
		<category><![CDATA[racer]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=790</guid>
		<description><![CDATA[Ough, almost forgot&#8230; Remember that Alternativa&#8217;s racing demo at the Adobe MAX? Well, guess what &#8212; they&#8217;ve uploaded it, so u can go and drive that ferrari (or whatever that is) on your own now (link below) Take a MAXRacer ride]]></description>
			<content:encoded><![CDATA[<p>Ough, almost forgot&#8230; Remember that Alternativa&#8217;s racing demo at the <a href="http://chargedweb.com/labs/2010/10/25/adobe-max-2010-1st-day/">Adobe MAX</a>?<br />
Well, guess what &#8212; they&#8217;ve uploaded it, so u can go and drive that ferrari (or whatever that is) on your own now (link below) <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><strong><a href="http://alternativaplatform.com/en/demos/maxracer/">Take a MAXRacer ride</a></strong></p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2011/03/01/maxracer-live/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Copying objects bytearray vs for in loop</title>
		<link>http://chargedweb.com/labs/2011/03/01/copying-objects-bytearray-for-in-loop/</link>
		<comments>http://chargedweb.com/labs/2011/03/01/copying-objects-bytearray-for-in-loop/#comments</comments>
		<pubDate>Tue, 01 Mar 2011 19:32:00 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[thoughts]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[bytearray]]></category>
		<category><![CDATA[copy]]></category>
		<category><![CDATA[for in loop]]></category>
		<category><![CDATA[object]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=780</guid>
		<description><![CDATA[I was curious, which of those would be quicker in the &#8220;copying objects&#8221; battle &#8212; bytearray / for in loop. Foreseeing your possible thoughts, &#8220;yes&#8221; i do realize that those methods actually differ (bytearray copies the entire object, uses describeType etc), but still curiosity takes over And, frankly, i was surprized with the results. See [...]]]></description>
			<content:encoded><![CDATA[<p>I was curious, which of those would be quicker in the &#8220;copying objects&#8221; battle &#8212; bytearray / for in loop.<br />
Foreseeing your possible thoughts, &#8220;yes&#8221; i do realize that those methods actually differ (bytearray copies the entire object, uses describeType etc), but still curiosity takes over <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
And, frankly, i was surprized with the results. See it for yourself.<br />
<br/><br />
<span id="more-780"></span></p>
<pre class="brush: as3; ">

// using ByteArray
function cloneObjectBA(value:Object):Object
{
var ba:ByteArray = new ByteArray();
ba.writeObject(value); ba.position = 0;
return ba.readObject() as Object;
}

// using for in loop
function cloneObjectForInLoop(value:Object):Object
{
var obj:Object = new Object();
for(var p:String in value) obj[p] = value[p];
return obj;
}

// &gt;&gt; Benchmark
var t:int, tb:int, tbAvg:int, tbTotal:int, tl:int, tlAvg:int, tlTotal:int;
var obj:Object = {};		// our testee ^_^
var numProps:int = 100000;	// num props to push to the object
var numCycles:int = 20;		// num cycles to run

// create properties
for(var i:int = 0; i &lt; numProps; i++) obj[&quot;prop_&quot;+i] = &quot;val_&quot;+i; trace(&quot;object&quot;, &quot;-&gt;&quot;, numProps, &quot;props&quot;);
trace(&quot;bytes&quot;, &quot;\t|\t&quot;, &quot;for in loop&quot;);
trace(&quot;-------------------------&quot;);

for(i = 0; i &lt; numCycles; i++)
{
t = getTimer();
cloneObjectBA(obj);
tb = getTimer() - t;
tbTotal += tb;

t = getTimer();
cloneObjectForInLoop(obj);
tl = getTimer() - t;
tlTotal += tl;
trace(tb, &quot;ms&quot;, &quot;\t|\t&quot;, tl, &quot;ms&quot;);
}
tbAvg = tbTotal/numCycles;
tlAvg = tlTotal/numCycles;

trace(&quot;-------------------------&quot;);
trace(&quot;AVG after &quot;+numCycles+&quot; cycles:&quot;);
trace(&quot;bytes&quot;, &quot;\t|\t&quot;, &quot;for in loop&quot;);
trace(&quot;-------------------------&quot;);
trace(tbAvg, &quot;ms&quot;, &quot;\t|\t&quot;, tlAvg, &quot;ms&quot;);
trace(&quot;-------------------------&quot;);
</pre>
<p>My results on core2duo 3Ghz, win 10.2.152.26 debug:<br />
<code><br />
object -&gt; 100000 props<br />
bytes 	|	 for in loop<br />
-------------------------<br />
678 ms 	|	 32 ms<br />
407 ms 	|	 32 ms<br />
380 ms 	|	 32 ms<br />
383 ms 	|	 32 ms<br />
384 ms 	|	 31 ms<br />
392 ms 	|	 34 ms<br />
405 ms 	|	 32 ms<br />
391 ms 	|	 32 ms<br />
393 ms 	|	 32 ms<br />
397 ms 	|	 31 ms<br />
390 ms 	|	 31 ms<br />
394 ms 	|	 31 ms<br />
395 ms 	|	 31 ms<br />
395 ms 	|	 32 ms<br />
399 ms 	|	 31 ms<br />
412 ms 	|	 32 ms<br />
390 ms 	|	 31 ms<br />
390 ms 	|	 31 ms<br />
389 ms 	|	 32 ms<br />
392 ms 	|	 32 ms<br />
-------------------------<br />
AVG after 20 cycles:<br />
bytes 	|	 for in loop<br />
-------------------------<br />
407 ms 	|	 31 ms<br />
-------------------------<br />
</code></p>
<p><strong>K.O. for in loop wins</strong> <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2011/03/01/copying-objects-bytearray-for-in-loop/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>SWFSize on gitHub</title>
		<link>http://chargedweb.com/labs/2011/02/27/swfsize-github/</link>
		<comments>http://chargedweb.com/labs/2011/02/27/swfsize-github/#comments</comments>
		<pubDate>Sun, 27 Feb 2011 21:01:32 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[news]]></category>
		<category><![CDATA[git]]></category>
		<category><![CDATA[swfsize]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=771</guid>
		<description><![CDATA[SWFSize master branch is now available at GitHub, so that those of u that use svn/git could easily pull the source. https://github.com/jloa/SWFSize]]></description>
			<content:encoded><![CDATA[<p><img src="http://chargedweb.com/labs/files/2011/02/ico_swfsize_git.png" alt="" title="ico_swfsize_git" width="180" height="130"  /></p>
<p>SWFSize master branch is now available at GitHub, so that those of u that use svn/git could easily pull the source.<br />
<strong><a href="https://github.com/jloa/SWFSize">https://github.com/jloa/SWFSize</a></strong> <img alt="" src="http://assets1.github.com/images/icons/public.png" title="smiley" width="16" height="16" /></p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2011/02/27/swfsize-github/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Math.atan2 and zeros</title>
		<link>http://chargedweb.com/labs/2011/02/17/mathatan2-zeros/</link>
		<comments>http://chargedweb.com/labs/2011/02/17/mathatan2-zeros/#comments</comments>
		<pubDate>Thu, 17 Feb 2011 21:17:37 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[thoughts]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[math.atan2]]></category>
		<category><![CDATA[zero]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=766</guid>
		<description><![CDATA[Keep in mind that trace(0 === -0); // true trace(Math.atan2(0, 0)); // 0 trace(Math.atan2(0, -0)); // 3.141592653589793 trace(Math.atan2(-0, -0)); // -3.141592653589793 function posZero(n:Number) { if(n === 0) return Math.abs(n); }]]></description>
			<content:encoded><![CDATA[<p>Keep in mind that</p>
<pre class="brush: as3; ">

trace(0 === -0);			// true
trace(Math.atan2(0, 0));	// 0
trace(Math.atan2(0, -0));	// 3.141592653589793
trace(Math.atan2(-0, -0));	// -3.141592653589793

function posZero(n:Number) { if(n === 0) return Math.abs(n); }
</pre>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2011/02/17/mathatan2-zeros/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>SCORM 1.2/2004 as3 implementation</title>
		<link>http://chargedweb.com/labs/2011/02/01/scorm-122004-as3-implementation/</link>
		<comments>http://chargedweb.com/labs/2011/02/01/scorm-122004-as3-implementation/#comments</comments>
		<pubDate>Tue, 01 Feb 2011 12:19:04 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[actionscript]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[js]]></category>
		<category><![CDATA[scorm]]></category>
		<category><![CDATA[wrapper]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=729</guid>
		<description><![CDATA[It&#8217;s been a while since i last posted in my blog thx to the holidays and the the enormous num of projects that&#8217;ve fallen down. One of my lastest projects was to build a swf course for an LMS using the SCORM standart. That&#8217;s when i&#8217;ve ran across Philip Hutchison&#8217;s blog and his SCORM project. [...]]]></description>
			<content:encoded><![CDATA[<p><img title="as3 loves scorm" src="http://chargedweb.com/labs/files/2011/01/scorm.png" alt="as3 loves scorm" width="300" height="250" /></p>
<p>It&#8217;s been a while since i last posted in my blog thx to the holidays and the the enormous num of projects that&#8217;ve fallen down. One of my lastest projects was to build a swf course for an <a href="http://en.wikipedia.org/wiki/Learning_management_system" target="_blank"><acronym>LMS</acronym></a> using the <a href="http://en.wikipedia.org/wiki/SCORM" target="_blank"><acronym>SCORM</acronym></a> standart. That&#8217;s when i&#8217;ve ran across <a href="http://pipwerks.com/" target="_blank">Philip Hutchison&#8217;s blog</a> and his <a href="http://pipwerks.com/laboratory/scorm/" target="_blank">SCORM project</a>. After a few days of SCORM researches and running through the pipwerks SCORM solution, i came up with the idea to make an extention of it, which would fully implement SCORM 1.2 and 2004 &#8220;from the box&#8221; in the nearest future (currently a beta yet it works). <em>[to be continued...]</em></p>
<p>So, here&#8217;s my version of the SCORM implementation for as3:</p>
<p><strong><a href="https://sourceforge.net/projects/as3scorm/files/">Download as3scorm at sourceforge</a></strong> (OS, <a href="http://www.opensource.org/licenses/mit-license.php" target="_blank">MIT</a> license as always)</p>
<p><strong><span style="color: #ff0000;">UPDATE:</span> </strong>added a <a href="http://sourceforge.net/projects/as3scorm/files/scorm.lib.1.3b.samples.zip/download">new archive with a sample course</a></p>
<p><a href="http://sourceforge.net/projects/as3scorm/files/scorm.lib.1.3b.samples.zip/download"> </a></p>
<p><a href="http://sourceforge.net/projects/as3scorm/files/scorm.lib.1.3b.samples.zip/download">Might be useful:<br />
</a><a href="http://chargedweb.com/labs/files/scorm/scorm.1.2.pdf" target="_blank">SCORM 1.2</a><br />
<a href="http://chargedweb.com/labs/files/scorm/scorm.2004.4.pdf" target="_blank">SCORM 2004 4th edition</a> (and <a href="http://www.adlnet.gov/Technologies/scorm/SCORMSDocuments/2004%204th%20Edition/Documentation.aspx" target="_blank">some more</a>)<br />
<a href="http://scorm.com/scorm-explained/scorm-resources/" target="_blank">SCORM resourses, books, articles, tools etc</a><br />
<a href="https://github.com/mikechambers/as3corelib">Adobe&#8217;s serialization as3corelib</a><br />
<a href="http://pipwerks.com/lab/scorm/">Philip Hutchison&#8217;s aka pipwerks SCORM labs</a></p>
<p>ps: Philip thx <strong>A LOT</strong> for yr help! Btw if u have any scorm related questions, do not hesitate to contact either <a href="http://twitter.com/chargedweb">me</a> or <a href="http://twitter.com/pipwerks">Philip</a></p>
<p><a href="http://chargedweb.com/labs/files/2011/01/as3scorm_qr.png"><img class="alignnone size-full wp-image-758" title="as3scorm" src="http://chargedweb.com/labs/files/2011/01/as3scorm_qr.png" alt="" width="175" height="175" /></a></p>
 <p><a href="http://chargedweb.com/labs/?flattrss_redirect&amp;id=729&amp;md5=8027a32052d343fa1d1c6b7dfd11a9a2" title="Flattr" target="_blank"><img src="http://chargedweb.com/labs/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2011/02/01/scorm-122004-as3-implementation/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Adobe max 2010 1st day</title>
		<link>http://chargedweb.com/labs/2010/10/25/adobe-max-2010-1st-day/</link>
		<comments>http://chargedweb.com/labs/2010/10/25/adobe-max-2010-1st-day/#comments</comments>
		<pubDate>Mon, 25 Oct 2010 22:11:49 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[news]]></category>
		<category><![CDATA[thoughts]]></category>
		<category><![CDATA[2010]]></category>
		<category><![CDATA[3d]]></category>
		<category><![CDATA[adobe]]></category>
		<category><![CDATA[alternativa]]></category>
		<category><![CDATA[Flash]]></category>
		<category><![CDATA[max]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=659</guid>
		<description><![CDATA[Today was the 1st day of the Adobe max 2010, and as far as some of you already know, i wasn&#8217;t able to attend it personally, so i had to watch it live at http://max.adobe.com/online/ (btw in HD !!!). I won&#8217;t write a poem about it, as tomorrow there will be one available at the [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://max.adobe.com/online/"><img title="adobe.max.2010" src="http://chargedweb.com/labs/files/2010/10/adobe.max_.png" alt="adobe.max.2010" width="506" height="222" /></a></p>
<p>Today was the 1st day of the Adobe max 2010, and as far as some of you already know, i wasn&#8217;t able to attend it personally, so i had to watch it live at <a href="http://max.adobe.com/online/">http://max.adobe.com/online/</a> (btw in HD !!!).<br />
I won&#8217;t write a poem about it, as <s>tomorrow there will be one available at the said above <a href="http://max.adobe.com/online/">http://max.adobe.com/online/</a></s> they&#8217;ve already posted the replay of today&#8217;s session. However i just owe to mention what really impressed me and that was the <a href="http://alternativaplatform.com/en/">Alternativa&#8217;s</a> 3d game called &#8220;<a href="http://www.youtube.com/watch?v=tgwi0lWgX8w">Max racer</a>&#8221; (a demo of the new, 8th edition of the engine), which was presented by Kevin Lynch as a sneak peak of fp&#8217;s performance increasement.<br/><br />
Ough, and <span style="color: #ff0000;"><span style="text-decoration: underline;"><strong>the most important notice</strong></span></span>: check out the today&#8217;s replay <a href="http://max.adobe.com/online/">http://max.adobe.com/online/monday/</a><br />
<br/><br />
I guess, that&#8217;s it for now. Now, back to work. Cheers <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /><br />
<br/><br />
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="550" height="333" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowFullScreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://www.youtube.com/v/tgwi0lWgX8w?fs=1&amp;hl=en_GB" /><param name="allowfullscreen" value="true" /><embed type="application/x-shockwave-flash" width="550" height="333" src="http://www.youtube.com/v/tgwi0lWgX8w?fs=1&amp;hl=en_GB" allowscriptaccess="always" allowfullscreen="true"></embed></object></p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/10/25/adobe-max-2010-1st-day/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Microsoft buys Adobe?</title>
		<link>http://chargedweb.com/labs/2010/10/08/microsoft-buys-adobe/</link>
		<comments>http://chargedweb.com/labs/2010/10/08/microsoft-buys-adobe/#comments</comments>
		<pubDate>Fri, 08 Oct 2010 19:38:15 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[news]]></category>
		<category><![CDATA[thoughts]]></category>
		<category><![CDATA[adobe]]></category>
		<category><![CDATA[microsoft]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=655</guid>
		<description><![CDATA[There&#8217;s that rumor walking around the web that ms intends to purchase adobe. What for? Didn&#8217;t they just yell about SL being the future of the web 2.0? I guess it&#8217;s just a rumor and possibly a marketing strategy (adobe&#8217;s shares increased about 17%). Source]]></description>
			<content:encoded><![CDATA[<p>There&#8217;s that rumor walking around the web that ms intends to purchase adobe.<br />
What for? Didn&#8217;t they just yell about SL being the future of the web 2.0?<br />
I guess it&#8217;s just a rumor and possibly a marketing strategy (adobe&#8217;s shares increased about 17%).<br />
<a href="http://www.ecommerce-journal.com/node/29986">Source</a></p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/10/08/microsoft-buys-adobe/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Mozilla’s mobile phone concept</title>
		<link>http://chargedweb.com/labs/2010/09/24/mozilla-seabird-mobile-phone-concept/</link>
		<comments>http://chargedweb.com/labs/2010/09/24/mozilla-seabird-mobile-phone-concept/#comments</comments>
		<pubDate>Fri, 24 Sep 2010 19:51:48 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[thoughts]]></category>
		<category><![CDATA[mobile]]></category>
		<category><![CDATA[mozilla]]></category>
		<category><![CDATA[phone]]></category>
		<category><![CDATA[seabird]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=646</guid>
		<description><![CDATA[Have u already seen the mozilla&#8217;s seabird mobile phone concept? As for me, finally, someone made a mobile phone (even if just a concept for now) that i would like to have for sure. Damn, i would kill for that phone Read more about mozilla seabird]]></description>
			<content:encoded><![CDATA[<p><img class="alignnone" title="Seabird – A Community-driven Mobile Phone Concept" src="http://mozillalabs.com/conceptseries/files/2010/09/seabird_1.jpg" alt="" width="426" height="320" /><br />
<br/><br />
Have u already seen the <a href="http://mozillalabs.com/conceptseries/2010/09/23/seabird/">mozilla&#8217;s seabird mobile phone concept</a>?<br />
As for me, finally, someone made a mobile phone (even if just a concept for now) that i would like to have for sure.<br />
Damn, i would kill for that phone <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
<br/><br />
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="425" height="259" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowFullScreen" value="true" /><param name="allowScriptAccess" value="always" /><param name="src" value="http://www.youtube.com/v/oG3tLxEQEdg&amp;hl=en_US&amp;feature=player_embedded&amp;version=3" /><param name="allowfullscreen" value="true" /><embed type="application/x-shockwave-flash" width="425" height="259" src="http://www.youtube.com/v/oG3tLxEQEdg&amp;hl=en_US&amp;feature=player_embedded&amp;version=3" allowscriptaccess="always" allowfullscreen="true"></embed></object><br/><br />
<strong><br />
<a href="http://mozillalabs.com/conceptseries/2010/09/23/seabird/">Read more about mozilla seabird</a></strong></p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/09/24/mozilla-seabird-mobile-phone-concept/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>ActionScript 4 required or a method from the future</title>
		<link>http://chargedweb.com/labs/2010/09/22/actionscript-4-required/</link>
		<comments>http://chargedweb.com/labs/2010/09/22/actionscript-4-required/#comments</comments>
		<pubDate>Wed, 22 Sep 2010 14:14:40 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[thoughts]]></category>
		<category><![CDATA[actionscript 4]]></category>
		<category><![CDATA[as4]]></category>
		<category><![CDATA[flex]]></category>
		<category><![CDATA[hasFocusableChildren]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=628</guid>
		<description><![CDATA[While surfing the flex docs i bumped into this method. Btw, as4 is not just a rumor as the ecma4 development still continues. ps: sry for the late update, i&#8217;ve got tons of projects&#8230;]]></description>
			<content:encoded><![CDATA[<p><img src="http://chargedweb.com/labs/files/2010/09/as4_magnified.png" alt="" title="as4_magnified" width="300" height="256" /><br />
<br/><br />
While surfing the flex docs i bumped into this <a href="http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/mx/core/UIComponent.html?filter_flex=4.1&#038;filter_flashplayer=10.1&#038;filter_air=2#hasFocusableChildren">method</a>.<br />
Btw, as4 is not just a rumor as the ecma4 development <a href="http://moock.org/lectures/newInECMAScript4/">still continues</a>.<br/><br />
ps: sry for the late update, i&#8217;ve got tons of projects&#8230; <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/09/22/actionscript-4-required/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>JSCompressor or a GIU for the YUI Compressor</title>
		<link>http://chargedweb.com/labs/2010/08/06/jscompressor-yuicompressor/</link>
		<comments>http://chargedweb.com/labs/2010/08/06/jscompressor-yuicompressor/#comments</comments>
		<pubDate>Fri, 06 Aug 2010 16:06:51 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[app]]></category>
		<category><![CDATA[air]]></category>
		<category><![CDATA[compress]]></category>
		<category><![CDATA[js]]></category>
		<category><![CDATA[yuicompressor]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=581</guid>
		<description><![CDATA[While the whole world is on fire, i made a small air app which actually is a GUI for the yahoo&#8217;s YUI Compressor util. About the YUI Compressor tool: The YUI Compressor is written in Java (requires Java >= 1.4) and relies on Rhino to tokenize the source JavaScript file. It starts by analyzing the [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://chargedweb.com/labs/files/2010/08/i_128.png" alt="jscompressor" title="jscompressor" width="128" height="128" /><br/><br />
While <a href="http://www.esa.int/esaCP/SEMRBH9ATME_index_1.html#subhead1" target="_blank">the whole world is on fire</a>, i made a small air app which actually is a GUI for the <a href="http://developer.yahoo.com/yui/compressor/"  target="_blank">yahoo&#8217;s YUI Compressor util</a>.<br/><br />
About the YUI Compressor tool:</p>
<blockquote><p>The YUI Compressor is written in Java (requires Java >= 1.4) and relies on Rhino  to tokenize the source JavaScript file. It starts by analyzing the source JavaScript file to understand how it is structured. It then prints out the token stream, omitting as many white space characters as possible, and replacing all local symbols by a 1 (or 2, or 3) letter symbol wherever such a substitution is appropriate (in the face of evil features such as eval or with, the YUI Compressor takes a defensive approach by not obfuscating any of the scopes containing the evil statement) The CSS compression algorithm uses a set of finely tuned regular expressions to compress the source CSS file. The YUI Compressor is open-source, so don&#8217;t hesitate to look at the code to understand exactly how it works. </p></blockquote>
<p><br/><br />
In short, YUI Compressor is a jar tool which compresses *.js files. Sure, u can use it through the command line as described <a href="http://developer.yahoo.com/yui/compressor/#using" target="_blank">here</a>, however just give JSCompressor a try <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><strong>Requirements:</strong><br />
<strong>AIR:</strong> 2.0 run-time installed (in case u don&#8217;t have it <a href="http://get.adobe.com/air/" target="_blank">click here</a>)<br />
<strong>OS:</strong> win<br />
<strong>Download:</strong> <a href='http://chargedweb.com/labs/files/2010/08/jscompressor.exe'>jscompressor.exe</a></p>
<p>ps: i just love making small apps is my spare time ^_^</p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/08/06/jscompressor-yuicompressor/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>AlignUtil – align objects easily</title>
		<link>http://chargedweb.com/labs/2010/07/27/alignutil_align_objects_easily/</link>
		<comments>http://chargedweb.com/labs/2010/07/27/alignutil_align_objects_easily/#comments</comments>
		<pubDate>Tue, 27 Jul 2010 13:13:10 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[align]]></category>
		<category><![CDATA[alignutil]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[displayobject]]></category>
		<category><![CDATA[uicomponent]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=556</guid>
		<description><![CDATA[Recently i had to align tons of UIComponents with scale and even rotation defined. And so, i decided to write a small static class that would really facilitate my life. I called it AlignUtil. That&#8217;s it for now. All links are listed bellow. Hope it helps someone. Cheers ^_^ ps: btw i decided to switch [...]]]></description>
			<content:encoded><![CDATA[<p><img title="alignutil" src="http://chargedweb.com/labs/files/2010/07/alignutil.png" alt="" width="575" height="221" /></p>
<p>Recently i had to align tons of UIComponents with scale and even rotation defined. And so, i decided to write a small static class that would really facilitate my life. I called it AlignUtil. That&#8217;s it for now. All links are listed bellow. Hope it helps someone. Cheers ^_^</p>
<p>ps: btw i decided to switch my devs license to <a href="http://www.opensource.org/licenses/mit-license.php">MIT</a>, so from now on u r free to use the source codes for whatever u want purpose.</p>
<p><strong><a href="http://chargedweb.com/labs/files/2010/07/alignutil/" target="_blank">Online demo</a></strong><br />
<strong><a href="http://chargedweb.com/labs/files/2010/07/AlignUtil.zip">Download the AlignUtil class</a></strong></p>
<p><span style="text-decoration: underline;"><span style="color: #ff0000;"><strong>UPDATE:</strong></span></span> class updated to v.1.3</p>
<p>And here&#8217;s the source code (in case u r 2 lazy to download the archive):</p>
<pre class="brush: as3; ">

////////////////////////////////////////////////////////////////////////////////
//
//  (c) 2011 Julius Loa | jloa[u know wha]chargedweb.com | http://chargedweb.com/labs/
//  All Rights Reserved.
//  license:	MIT {http://www.opensource.org/licenses/mit-license.php}
//  notice: 	just keep the header plz
//
////////////////////////////////////////////////////////////////////////////////

package com.chargedweb.utils
{
/** fp api **/
import flash.display.DisplayObject;
import flash.text.TextField;
import flash.geom.Rectangle;
import flash.geom.Point;

/**
* &lt;p&gt;AlignUtil class - vertical/horizontal align DisplayObjects&lt;/p&gt;
* @availability 	fp9 (flash/flex, as3)
* @version 		1.3
*
* &lt;p&gt;Class usage:&lt;/p&gt;
* @example using parentalRelation set to &quot;true&quot; (aligning children inside the &quot;parent&quot;)
* &lt;listing version=&quot;3.0&quot;&gt;
* import com.chargedweb.utils.AlignUtil;
*
* var btn:Button = new Button();
* btn.x = 100;
* btn.y = 100;
* btn.width = 100;
* btn.height = 30;
* btn.rotation = 30;
* addChild(btn);
*
* AlignUtil.setAlign(AlignUtil.H_CENTER, btn, this);
* AlignUtil.setAlign(AlignUtil.V_MIDDLE, btn, this);
* &lt;/listing&gt;
*
* @example using parentalRelation set to &quot;false&quot; (aligning children according to another child on the same level)
* &lt;listing version=&quot;3.0&quot;&gt;
* import flash.display.Shape;
* import com.chargedweb.utils.AlignUtil;
*
* function createBox(w:Number, h:Number, r:Number):Shape
* {
* 	var sp:Shape = new Shape();
*	sp.graphics.beginFill(Math.random()*0xffffff);
*	sp.graphics.drawRect(0, 0, w, h);
*	sp.graphics.endFill();
*	sp.rotation = r;
*	return sp;
* }
*
* var a:Shape = createBox(200, 200, 45);
* a.x = 200; a.y = 100;
* addChild(a);
*
* var b:Shape = createBox(50, 20, -10);
* b.x = 50; b.y = 200;
* addChild(b);
*
* var c:Shape = createBox(120, 75, 150);
* c.x = 300; c.y = 200;
* addChild(c);
*
* // align &#039;b&#039;,&#039;c&#039; according to &#039;a&#039; (horizontal-left and vertical-top alignment)
* // horizontally
* AlignUtil.setAlign(AlignUtil.H_LEFT, b, a, false);
* AlignUtil.setAlign(AlignUtil.H_LEFT, c, a, false);
* // now vertically
* AlignUtil.setAlign(AlignUtil.V_TOP, b, a, false);
* AlignUtil.setAlign(AlignUtil.V_TOP, c, a, false);
* &lt;/listing&gt;
*/
public class AlignUtil
{
/** Horizontal left alignment **/
public static const H_LEFT:String = &quot;horizontalLeft&quot;;
/** Horizontal center alignment **/
public static const H_CENTER:String = &quot;horizontalCenter&quot;;
/** Horizontal right alignment **/
public static const H_RIGHT:String = &quot;horizontalRight&quot;;

/** Vertical top alignment **/
public static const V_TOP:String = &quot;verticalTop&quot;;
/** Vertical middle alignment **/
public static const V_MIDDLE:String = &quot;verticalMiddle&quot;;
/** Vertical bottom alignment **/
public static const V_BOTTOM:String = &quot;verticalBottom&quot;;

/**
* Applies a specified alignment to the target DisplayObject
* @param	align:String				alignment mode (see the public constants defined above)
* @param	target:DisplayObject		target DisplayObject to align (according to the set alignment mode) @see flash.display.DisplayObject
* @param	parent:DisplayObject		the parent DisplayObject of the target one @see flash.display.DisplayObject
* @param	parentalRelation:Boolean	whether the &quot;target&quot; DisplayObject is a child of the &quot;parent&quot; or not @default true;
* @return	nothing
*/
public static function setAlign(align:String, target:DisplayObject, parent:DisplayObject, parentalRelation:Boolean = true):void
{
var a:String = align;
var t:DisplayObject = target;
var p:DisplayObject = parent;
var b:Rectangle = t.transform.pixelBounds;
var tp:Point = new Point();
var bp:Point;

/**
* @note 28/03/2011 :: bug fix for TextFields :: tip by Arindam Mojumder
* TextField.transform.pixelBounds return incorrect x/y coordinates (not the actual, but rather
* the one of the transform point) and the x/y are always &#039;zero&#039; valued, so we make an exception for tfs
*/
if(t is TextField) b = t.getBounds(t.parent);

/** if parentalRelation is enabled, use local coordinates **/
if(parentalRelation)
{
bp = p.globalToLocal(new Point(b.x, b.y));
b.x = bp.x;	b.y = bp.y;
}else{
tp = new Point(p.transform.pixelBounds.x, p.transform.pixelBounds.y);
}

if(a == H_LEFT) t.x = (t.x &gt; b.x) ? tp.x + t.x - b.x : tp.x;
if(a == H_CENTER) t.x = tp.x + int((p.width - b.width)/2 + t.x - b.x);
if(a == H_RIGHT) t.x = (t.x &gt; b.x + b.width) ? tp.x + p.width : tp.x + p.width - (b.x + b.width - t.x);
if(a == V_TOP) t.y = (t.y &gt; b.y) ? tp.y + t.y - b.y : tp.y;
if(a == V_MIDDLE) t.y = tp.y + int((p.height - b.height)/2 + t.y - b.y);
if(a == V_BOTTOM) t.y = (t.y &gt; b.y + b.height) ? tp.y + p.height : tp.y + p.height - (b.y + b.height - t.y);
}
}
}
</pre>
 <p><a href="http://chargedweb.com/labs/?flattrss_redirect&amp;id=556&amp;md5=1c0d71ee83a333acc476f0a55b08c4e4" title="Flattr" target="_blank"><img src="http://chargedweb.com/labs/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/07/27/alignutil_align_objects_easily/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>Flash on apple devices, finally?</title>
		<link>http://chargedweb.com/labs/2010/07/06/flash-apple-devices-finally/</link>
		<comments>http://chargedweb.com/labs/2010/07/06/flash-apple-devices-finally/#comments</comments>
		<pubDate>Tue, 06 Jul 2010 21:41:55 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[news]]></category>
		<category><![CDATA[apple]]></category>
		<category><![CDATA[flash player]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=550</guid>
		<description><![CDATA[The European Union’s new Digital Agenda, an ambitious program of incentives and legislation designed to improve access to technology across the EU, could force companies such as Apple to open up their businesses by requiring them to offer more interoperability and use open standards. It could force more openness even if those companies are not [...]]]></description>
			<content:encoded><![CDATA[<blockquote><p>The European Union’s new Digital Agenda, an ambitious program of incentives and legislation designed to improve access to technology across the EU, could force companies such as Apple to open up their businesses by requiring them to offer more interoperability and use open standards. It could force more openness even if those companies are not the dominant player in a specific market, because the language in the EU Agenda says that such measures could apply merely to “significant” players in a market — broadening the scope of previous antitrust rules substantially.</p></blockquote>
<p>Could that be true? Flash player support on i-devices, really? Or just another rumor?</p>
<p>more info here => <a href="http://bit.ly/abeBdC">http://bit.ly/abeBdC</a></p>
<p>ps: 0k, that&#8217;s it guys. I&#8217;m fed up with that apple stuff, let&#8217;s get back to development <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/07/06/flash-apple-devices-finally/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Flash on the iPad</title>
		<link>http://chargedweb.com/labs/2010/07/05/flash-ipad/</link>
		<comments>http://chargedweb.com/labs/2010/07/05/flash-ipad/#comments</comments>
		<pubDate>Mon, 05 Jul 2010 08:59:49 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[news]]></category>
		<category><![CDATA[thoughts]]></category>
		<category><![CDATA[apple]]></category>
		<category><![CDATA[Flash]]></category>
		<category><![CDATA[ipad]]></category>
		<category><![CDATA[iphone]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=542</guid>
		<description><![CDATA[Well, finally someone&#8217;d found some courage to stop Steve&#8217;s flash rage Frash is a port of the Adobe Flash runtime for Android to the iPhone, using a compatibility layer, by comex (http://twitter.com/comex). Frash can currently run most Flash programs natively in the MobileSafari browser. Frash currently only runs on the iPad, but support for other [...]]]></description>
			<content:encoded><![CDATA[<p>Well, finally someone&#8217;d found some courage to stop Steve&#8217;s flash rage <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<blockquote><p>Frash is a port of the Adobe Flash runtime for Android to the iPhone, using a compatibility layer, by comex (<a href="http://twitter.com/comex">http://twitter.com/comex</a>). Frash can currently run most Flash programs natively in the MobileSafari browser. Frash currently only runs on the iPad, but support for other devices (3GS+ only due to technical restrictions) is planned, as well as support for iOS 4.</p>
<p>A release is planned for when Frash is stable. Developers are welcome to join the effort at <a href="http://github.com/comex/frash">http://github.com/comex/frash</a> &#8211; fork it and send a pull request with your patches.</p>
<p>Frash uses a multi-process model similar to Chrome on the desktop, so a crash in the Frash/Flash plugin doesn&#8217;t take down the browser. You can see this while I&#8217;m playing Alien Hominid: the ad above crashed (probably a Frash bug), but Safari stays open just fine, and continues to play other Flash content on the page.</p>
<p>Video and keyboard input are currently not supported. The former will require major reverse engineering of the video decoding frameworks on the iPhone, but the latter should be reasonably easy to implement.</p>
<p>&#8230;and if anyone from Adobe reads this: Hosting the libflashplayer.so binary somewhere accessible outside the Android Market would make this a lot easier to distribute <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>
<p>Shot on an iPhone 4 and edited using iMovie on the phone.</p></blockquote>
<p><embed width="400" height="300" flashvars="el=profilepage&amp;showinfo=0&amp;creator=Xuzz149&amp;allow_embed=1&amp;keywords=iphone%2Cflash%2Cfrash%2Cipad&amp;fexp=907041&amp;allow_ratings=1&amp;user_gender=m&amp;track_embed=0&amp;fmt_list=22%2F1280x720%2F9%2F0%2F115%2C35%2F854x480%2F9%2F0%2F115%2C34%2F640x360%2F9%2F0%2F115%2C5%2F320x240%2F7%2F0%2F0&amp;iv_storage_server=http%3A%2F%2Fwww.google.com%2Freviews%2Fy%2F&amp;author=Xuzz149&amp;muted=0&amp;lpbb=http%3A%2F%2Fs.ytimg.com%2Fyt%2Fswf%2Flpbb-vfl54521.swf&amp;length_seconds=201&amp;user_age=30&amp;rel=0&amp;has_cc=False&amp;iv_module=http%3A%2F%2Fs.ytimg.com%2Fyt%2Fswf%2Fiv_module-vfl174041.swf&amp;ftoken=dEaUCdfxBFBucl4avIe6K44Tllx8MjU1NjcyNjg3MA%3D%3D&amp;status=ok&amp;fs=1&amp;watermark=http%3A%2F%2Fs.ytimg.com%2Fyt%2Fswf%2Flogo-vfl107009.swf%2Chttp%3A%2F%2Fs.ytimg.com%2Fyt%2Fswf%2Fhdlogo-vfl101609.swf&amp;lpbf=http%3A%2F%2Fs.ytimg.com%2Fyt%2Fswf%2Flpbf-vfl54521.swf&amp;timestamp=1278320235&amp;plid=AASKoB-H6BVONKAV&amp;fmt_url_map=22%7Chttp%3A%2F%2Fv23.lscache2.c.youtube.com%2Fvideoplayback%3Fip%3D0.0.0.0%26sparams%3Did%252Cexpire%252Cip%252Cipbits%252Citag%252Cratebypass%252Coc%253AU0dWTVNPUF9FSkNNNl9LSVRB%26fexp%3D907041%26itag%3D22%26ipbits%3D0%26sver%3D3%26ratebypass%3Dyes%26expire%3D1278342000%26key%3Dyt1%26signature%3DB0BCC5444A92A0343D46AB67CDA9BF4B1ED90F40.D115C6645AAB87E23728C9403FFC806CCE471B96%26id%3D69da2e4e75e07a51%2C35%7Chttp%3A%2F%2Fv17.lscache1.c.youtube.com%2Fvideoplayback%3Fip%3D0.0.0.0%26sparams%3Did%252Cexpire%252Cip%252Cipbits%252Citag%252Calgorithm%252Cburst%252Cfactor%252Coc%253AU0dWTVNPUF9FSkNNNl9LSVRB%26fexp%3D907041%26algorithm%3Dthrottle-factor%26itag%3D35%26ipbits%3D0%26burst%3D40%26sver%3D3%26expire%3D1278342000%26key%3Dyt1%26signature%3D56FD0A655435414ECA13CD4E72188BC80DF1CFB9.32E85996161C6FA260B6DC987294F7E2A3DCBC43%26factor%3D1.25%26id%3D69da2e4e75e07a51%2C34%7Chttp%3A%2F%2Fv3.lscache4.c.youtube.com%2Fvideoplayback%3Fip%3D0.0.0.0%26sparams%3Did%252Cexpire%252Cip%252Cipbits%252Citag%252Calgorithm%252Cburst%252Cfactor%252Coc%253AU0dWTVNPUF9FSkNNNl9LSVRB%26fexp%3D907041%26algorithm%3Dthrottle-factor%26itag%3D34%26ipbits%3D0%26burst%3D40%26sver%3D3%26expire%3D1278342000%26key%3Dyt1%26signature%3D727473EE209A6C7F406A8A051DD0AA8C7DB91949.48EFF54D02E5300862A46129315B12F8EAA51156%26factor%3D1.25%26id%3D69da2e4e75e07a51%2C5%7Chttp%3A%2F%2Fv16.lscache2.c.youtube.com%2Fvideoplayback%3Fip%3D0.0.0.0%26sparams%3Did%252Cexpire%252Cip%252Cipbits%252Citag%252Calgorithm%252Cburst%252Cfactor%252Coc%253AU0dWTVNPUF9FSkNNNl9LSVRB%26fexp%3D907041%26algorithm%3Dthrottle-factor%26itag%3D5%26ipbits%3D0%26burst%3D40%26sver%3D3%26expire%3D1278342000%26key%3Dyt1%26signature%3D67E00E6A6AFE9753CC82F12546D7427980B2F71E.30E90E2FD4037CDD39F993F0E32590144578D29C%26factor%3D1.25%26id%3D69da2e4e75e07a51&amp;fmt_map=22%2F1280x720%2F9%2F0%2F115%2C35%2F854x480%2F9%2F0%2F115%2C34%2F640x360%2F9%2F0%2F115%2C5%2F320x240%2F7%2F0%2F0&amp;hl=en_GB&amp;eurl=http://www.youtube.com/user/Xuzz149&amp;iurl=http%3A//i2.ytimg.com/vi/adouTnXgelE/hqdefault.jpg&amp;fmt_stream_map=22%7Chttp%3A%2F%2Fv23.lscache2.c.youtube.com%2Fvideoplayback%3Fip%3D0.0.0.0%26sparams%3Did%252Cexpire%252Cip%252Cipbits%252Citag%252Cratebypass%252Coc%253AU0dWTVNPUF9FSkNNNl9LSVRB%26fexp%3D907041%26itag%3D22%26ipbits%3D0%26sver%3D3%26ratebypass%3Dyes%26expire%3D1278342000%26key%3Dyt1%26signature%3DB0BCC5444A92A0343D46AB67CDA9BF4B1ED90F40.D115C6645AAB87E23728C9403FFC806CCE471B96%26id%3D69da2e4e75e07a51%7C%7Ctc.v23.cache2.c.youtube.com%2C35%7Chttp%3A%2F%2Fv17.lscache1.c.youtube.com%2Fvideoplayback%3Fip%3D0.0.0.0%26sparams%3Did%252Cexpire%252Cip%252Cipbits%252Citag%252Calgorithm%252Cburst%252Cfactor%252Coc%253AU0dWTVNPUF9FSkNNNl9LSVRB%26fexp%3D907041%26algorithm%3Dthrottle-factor%26itag%3D35%26ipbits%3D0%26burst%3D40%26sver%3D3%26expire%3D1278342000%26key%3Dyt1%26signature%3D56FD0A655435414ECA13CD4E72188BC80DF1CFB9.32E85996161C6FA260B6DC987294F7E2A3DCBC43%26factor%3D1.25%26id%3D69da2e4e75e07a51%7C%7Ctc.v17.cache1.c.youtube.com%2C34%7Chttp%3A%2F%2Fv3.lscache4.c.youtube.com%2Fvideoplayback%3Fip%3D0.0.0.0%26sparams%3Did%252Cexpire%252Cip%252Cipbits%252Citag%252Calgorithm%252Cburst%252Cfactor%252Coc%253AU0dWTVNPUF9FSkNNNl9LSVRB%26fexp%3D907041%26algorithm%3Dthrottle-factor%26itag%3D34%26ipbits%3D0%26burst%3D40%26sver%3D3%26expire%3D1278342000%26key%3Dyt1%26signature%3D727473EE209A6C7F406A8A051DD0AA8C7DB91949.48EFF54D02E5300862A46129315B12F8EAA51156%26factor%3D1.25%26id%3D69da2e4e75e07a51%7C%7Ctc.v3.cache4.c.youtube.com%2C5%7Chttp%3A%2F%2Fv16.lscache2.c.youtube.com%2Fvideoplayback%3Fip%3D0.0.0.0%26sparams%3Did%252Cexpire%252Cip%252Cipbits%252Citag%252Calgorithm%252Cburst%252Cfactor%252Coc%253AU0dWTVNPUF9FSkNNNl9LSVRB%26fexp%3D907041%26algorithm%3Dthrottle-factor%26itag%3D5%26ipbits%3D0%26burst%3D40%26sver%3D3%26expire%3D1278342000%26key%3Dyt1%26signature%3D67E00E6A6AFE9753CC82F12546D7427980B2F71E.30E90E2FD4037CDD39F993F0E32590144578D29C%26factor%3D1.25%26id%3D69da2e4e75e07a51%7C%7Ctc.v16.cache2.c.youtube.com&amp;ss=1&amp;referrer=None&amp;avg_rating=4.57281553398&amp;video_id=adouTnXgelE&amp;sk=HG-zVAB_oEwkeqr8lVtiyOdTiRGtcnANR&amp;token=vjVQa1PpcFMHvaWnbMKmEzOLNnVoQoUaUmDGGre2EDY%3D&amp;thumbnail_url=http%3A%2F%2Fi2.ytimg.com%2Fvi%2FadouTnXgelE%2Fdefault.jpg&amp;vq=auto&amp;showsearch=0&amp;autoplay=0&amp;playnext=0&amp;ad_eurl=http://www.youtube.com/user/Xuzz149&amp;enablejsapi=1&amp;jsapicallback=onChannelPlayerReady" allowscriptaccess="always" wmode="opaque" allowfullscreen="true" quality="high" bgcolor="#000000" name="movie_player" id="movie_player" style="" src="http://s.ytimg.com/yt/swf/watch-vfl174813.swf" type="application/x-shockwave-flash"></p>
<p>ps: muhaha, i told u Steve that yr rage was useless <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/07/05/flash-ipad/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>js tooltip</title>
		<link>http://chargedweb.com/labs/2010/06/16/js-tooltip/</link>
		<comments>http://chargedweb.com/labs/2010/06/16/js-tooltip/#comments</comments>
		<pubDate>Wed, 16 Jun 2010 22:23:33 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[misc]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[js]]></category>
		<category><![CDATA[tooltip]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=501</guid>
		<description><![CDATA[+ Well, i&#8217;m not a js-developer actually, however i had to write a small tooltip in js 2day and i thought that some of you would probably find it usefull. Won&#8217;t post the source code here this time, but the demo and source archive are still available @see the links below. Lightweight Supports basic fade [...]]]></description>
			<content:encoded><![CDATA[<table>
<tbody>
<tr>
<td><img title="tooltip" src="http://dryicons.com/images/icon_sets/colorful_stickers_icons_set/png/128x128/comment.png" alt="" width="128" height="128" /></td>
<td>
<h1>+</h1>
</td>
<td><img title="js" src="http://chargedweb.com/labs/files/2010/06/js.png" alt="" width="100" height="60" /></td>
</tr>
</tbody>
</table>
<p><br/><br/><br />
Well, i&#8217;m not a js-developer actually, however i had to write a small tooltip in js 2day and i thought that some of you would probably find it usefull. Won&#8217;t post the source code here this time, but the demo and source archive are still available @see the links below.
<ul>
<li>Lightweight</li>
<li>Supports basic fade effects</li>
<li>Easy to use</li>
<li>Uses external png graphics</li>
<li>Supports html</li>
<li>Works in all browsers</li>
</ul>
<p>Check out the <a href="http://chargedweb.com/labs/files/2010/06/tooltip_js/" target="_blank"><strong>online demo</strong></a> or <a href="http://chargedweb.com/labs/files/2010/06/tooltip_js.zip" target="_blank"><strong>grab the source files</strong></a></p>
<p>ps: thx <a href="http://dryicons.com/free-icons/icons-list/colorful-stickers-icons-set/">DryIcons</a> for the icon.</p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/06/16/js-tooltip/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
		<item>
		<title>Realaxy actionscript editor finally shipped</title>
		<link>http://chargedweb.com/labs/2010/06/15/realaxy-actionscript-editor/</link>
		<comments>http://chargedweb.com/labs/2010/06/15/realaxy-actionscript-editor/#comments</comments>
		<pubDate>Tue, 15 Jun 2010 20:56:36 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[news]]></category>
		<category><![CDATA[realaxy as3 editor ide mps]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=491</guid>
		<description><![CDATA[Yes, guys, finally realaxy is out for download Btw it supports win/mac/linux. And guess what, it&#8217;s free ! Ain&#8217;t that awesome? Profit!]]></description>
			<content:encoded><![CDATA[<table>
<tbody>
<tr>
<td><img title="realaxy as editor" src="http://pics.livejournal.com/ivan_dembicki/pic/000019kt/s320x240" alt="" width="240" height="240" /></td>
</tr>
<tr bgcolor="#000000">
<td align="center"><img title="realaxy" src="http://realaxy.com/images/realaxy.gif" alt="" width="215" height="42" /><br />
<img title="as editor" src="http://realaxy.com/images/ase.gif" alt="" width="255" height="42" /></td>
</tr>
</tbody>
</table>
<p><br/><br />
Yes, guys, finally realaxy is out for download <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
Btw it supports win/mac/linux. And guess what, it&#8217;s <u>free</u> !<br />
Ain&#8217;t that awesome? Profit!<br />
<br/><br />
<a href="http://www.realaxy.com/download/index" target="_blank"><img alt="" src="http://chargedweb.com/swfsize/i/download.png" title="download realaxy editor now!"width="90" height="30" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/06/15/realaxy-actionscript-editor/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>html5 almost ready?</title>
		<link>http://chargedweb.com/labs/2010/05/25/html5-ready/</link>
		<comments>http://chargedweb.com/labs/2010/05/25/html5-ready/#comments</comments>
		<pubDate>Tue, 25 May 2010 15:01:53 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[thoughts]]></category>
		<category><![CDATA[html5]]></category>
		<category><![CDATA[release]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=473</guid>
		<description><![CDATA[Did you know that there&#8217;s a some sort of a html5 fan club? Why am i telling you this? Because there&#8217;s a sort of a timer telling when will html5 be fully released check it http://ishtml5readyyet.com/ ps: only 12 more years still to go&#8230;]]></description>
			<content:encoded><![CDATA[<p><img src="http://chargedweb.com/labs/files/2010/05/fp_html5.png" alt="" title="fp_html5" width="300" height="200"  /></p>
<p>Did you know that there&#8217;s a some sort of a html5 fan club?<br />
Why am i telling you this? Because there&#8217;s a sort of a timer telling when will html5 be fully released check it <a href="http://ishtml5readyyet.com/">http://ishtml5readyyet.com/</a> <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>ps: only 12 more years still to go&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/05/25/html5-ready/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>flash vs html5 on nexus one</title>
		<link>http://chargedweb.com/labs/2010/05/15/flash-vs-html5-on-nexus-one/</link>
		<comments>http://chargedweb.com/labs/2010/05/15/flash-vs-html5-on-nexus-one/#comments</comments>
		<pubDate>Sat, 15 May 2010 09:56:58 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[thoughts]]></category>
		<category><![CDATA[benchmark]]></category>
		<category><![CDATA[Flash]]></category>
		<category><![CDATA[html5]]></category>
		<category><![CDATA[nexus one]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=466</guid>
		<description><![CDATA[Just sit back and watch ^_^ ps: So, where did the great html5 performance go?]]></description>
			<content:encoded><![CDATA[<p>Just sit back and watch ^_^</p>
<p><object width="400" height="300"><param name="movie" value="http://www.youtube.com/v/DUWo19BcC7s&#038;hl=en_GB&#038;fs=1&#038;"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/DUWo19BcC7s&#038;hl=en_GB&#038;fs=1&#038;" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="400" height="300"></embed></object></p>
<p>ps: So, where did the great html5 performance go? <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/05/15/flash-vs-html5-on-nexus-one/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>csv, xls and utf8 fail</title>
		<link>http://chargedweb.com/labs/2010/05/10/csv-xls-and-utf8-fail/</link>
		<comments>http://chargedweb.com/labs/2010/05/10/csv-xls-and-utf8-fail/#comments</comments>
		<pubDate>Mon, 10 May 2010 13:10:58 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[csv]]></category>
		<category><![CDATA[utf8]]></category>
		<category><![CDATA[xls]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=452</guid>
		<description><![CDATA[In case u need to save utf8 data to a csv or xls file, mind that those formats do not support utf8 encoding. Say, u&#8217;ve got to save a cyrillic text to a csv file: // A sample cyrillic, bulgarian text, for exmaple var utf8String:String = &#34;Аз съм българче. Обичам наште планини зелени...&#34;; // Try [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://chargedweb.com/labs/files/2010/05/excell_utf8.png"><img src="http://chargedweb.com/labs/files/2010/05/excell_utf8.png" alt="" title="excell_utf8" width="150" height="150" class="alignnone size-full wp-image-458" /></a></p>
<p>In case u need to save utf8 data to a csv or xls file, mind that those formats <strong>do not</strong> support utf8 encoding.<br />
Say, u&#8217;ve got to save a cyrillic text to a csv file:</p>
<pre class="brush: as3; ">

// A sample cyrillic, bulgarian text, for exmaple
var utf8String:String = &quot;Аз съм българче. Обичам наште планини зелени...&quot;;

// Try to save the file in utf8 charset and then
// open it with Microsoft Excel
var file:FileReference = new FileReference();
file.save(utf8String, &quot;utf8_test.csv&quot;);
</pre>
<p>And here&#8217;s the result:<br />
<a href="http://chargedweb.com/labs/files/2010/05/utf8.jpg"><img src="http://chargedweb.com/labs/files/2010/05/utf8-300x147.jpg" alt="" title="utf8" width="300" height="147" class="alignnone size-medium wp-image-454" /></a></p>
<p>But don&#8217;t hurry to google for an as3 charset encoding library, as there&#8217;s a simple way to solve this issue:</p>
<pre class="brush: as3; ">

// A sample cyrillic, bulgarian text, for exmaple
var utf8String:String = &quot;Аз съм българче. Обичам наште планини зелени...&quot;;

// csv, xls appear to work only with the ascii
// and windows-like charsets, so as the string is
// cyrillic, we&#039;ll use the cyrillic (Windows) charset &#039;windows-1251&#039;
// which codename&#039;s &#039;x-cp1251&#039; according to the adobe&#039;s as3 reference.
var bytes:ByteArray = new ByteArray();
bytes.writeMultiByte(utf8String, &quot;x-cp1251&quot;);

var file:FileReference = new FileReference();
file.save(bytes, &quot;cp1251_test.csv&quot;);
</pre>
<p>Now we got the expected result:<br />
<a href="http://chargedweb.com/labs/files/2010/05/cp1251.jpg"><img src="http://chargedweb.com/labs/files/2010/05/cp1251-300x147.jpg" alt="" title="cp1251" width="300" height="147" class="alignnone size-medium wp-image-453" /></a><br/><br />
Really simple, but still there might be someone who&#8217;d need it.</p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/05/10/csv-xls-and-utf8-fail/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>ResourceMonitor v2 = ResourceMonitorUtil [updated to 2.1]</title>
		<link>http://chargedweb.com/labs/2010/05/06/resourcemonitor-v2-resourcemonitorutil/</link>
		<comments>http://chargedweb.com/labs/2010/05/06/resourcemonitor-v2-resourcemonitorutil/#comments</comments>
		<pubDate>Thu, 06 May 2010 20:51:16 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[class]]></category>
		<category><![CDATA[fps]]></category>
		<category><![CDATA[memory]]></category>
		<category><![CDATA[monitor]]></category>
		<category><![CDATA[resource]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=427</guid>
		<description><![CDATA[UPD: i&#8217;ve updated the class to version 2.1, fixed some bugs, added new features, switched the license to MIT ! yellow &#8211; current fps cyan &#8211; current memory usage red &#8211; max memory usage graph As lots of you asked me to add some new features like the font color changing, performance increasement etc, i [...]]]></description>
			<content:encoded><![CDATA[<p><span style="color: #ff0000;"><span style="text-decoration: underline;"><strong>UPD:</strong></span></span> i&#8217;ve updated the class to version 2.1, fixed some bugs, added new features, switched the license to <a href="http://www.opensource.org/licenses/mit-license.php">MIT</a> !</p>
<p><a href="http://chargedweb.com/labs/files/2010/05/resourcemonitor_v2.png"><img class="alignnone size-full wp-image-431" title="resourcemonitor_v2" src="http://chargedweb.com/labs/files/2010/05/resourcemonitor_v2.png" alt="" width="150" height="150" /></a></p>
<p><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="200" height="300" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowFullScreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://chargedweb.com/labs/files/2010/05/ResourceMonitorUtil.swf" /><param name="allowfullscreen" value="true" /><embed type="application/x-shockwave-flash" width="200" height="300" src="http://chargedweb.com/labs/files/2010/05/ResourceMonitorUtil.swf" allowscriptaccess="always" allowfullscreen="true"></embed></object><br />
<em>yellow &#8211; current fps<br />
cyan &#8211; current memory usage<br />
red &#8211; max memory usage graph</em></p>
<p>As lots of you asked me to add some new features like the font color changing, performance increasement etc, i decided to make a new version of the ResourceMonitor class. I&#8217;ve added a few new features, made the code more ammm more readable (well, it&#8217;s an os class, so probably u&#8217;d like to edit smth there) and i&#8217;ve even made a documentation this time <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
And i also decided to rename it to <strong>ResourceMonitorUtil</strong>.</p>
<p>Class usage also has shorten.</p>
<p><strong>Flex:</strong></p>
<pre class="brush: as3; ">

import com.chargedweb.utils.ResourceMonitorUtil;

rawChildren.addChild(new ResourceMonitorUtil());
</pre>
<p><strong>Flash:</strong></p>
<pre class="brush: as3; ">

import com.chargedweb.utils.ResourceMonitorUtil;

addChild(new ResourceMonitorUtil());
</pre>
<p>Blah-blah-blah, just let me <strong><a href="http://chargedweb.com/labs/files/2010/05/ResourceMonitorUtil.zip">download the ResourceMonitorUtil source code</a></strong> already</p>
<p><span id="more-427"></span><br />
And here&#8217;s the source code in case for some reason u don&#8217;t want to download the archive:</p>
<pre class="brush: as3; ">

////////////////////////////////////////////////////////////////////////////////
//
//  Copyright 2010 Julius Loa | jloa@chargedweb.com
//  All Rights Reserved.
//  license:	MIT {http://www.opensource.org/licenses/mit-license.php}
//  notice: 	just keep the header plz
//
////////////////////////////////////////////////////////////////////////////////

package com.chargedweb.utils
{
import flash.display.JointStyle;
import flash.display.Shape;
import flash.display.Sprite;
import flash.events.Event;
import flash.events.TimerEvent;
import flash.system.System;
import flash.text.TextField;
import flash.text.TextFieldAutoSize;
import flash.text.TextFormat;
import flash.utils.Timer;

/**
* &lt;img src=&quot;http://chargedweb.com/labs/files/2010/02/resourcemonitor.png&quot; alt=&quot;&quot; /&gt;

*

ResourceMonitorUtil class provides the fps and used memory information &lt;a href=&quot;http://chargedweb.com/labs/2010/05/06/resourcemonitor-v2-resourcemonitorutil/&quot; target=&quot;_blank&quot;&gt;more info online&lt;/a&gt;

*
*

Version: 2.1

*

Changes in version 2.1:

*
&lt;ul&gt; *
&lt;li&gt;fixed the avg memory count algorithm (just had to switch to Number istead of int)&lt;/li&gt;
*
&lt;li&gt;fixed the graphics limit exceeder bug&lt;/li&gt;
*
&lt;li&gt;added max used ram memory throughout the history memoryMaxUsed()&lt;/li&gt;
*
&lt;li&gt;added max used ram memory graphic&lt;/li&gt;
*
&lt;li&gt;added max used ram memory graphic line size property memoryMaxUsedLineSize()&lt;/li&gt;
*
&lt;li&gt;added max used ram memory graphic line color property memoryMaxUsedLineColor()&lt;/li&gt;
*
&lt;li&gt;added a new replace tag to the info text MEMORY_INFO&lt;/li&gt;
*
&lt;li&gt;license switched GNU -&gt; &lt;a href=&quot;http://www.opensource.org/licenses/mit-license.php&quot;&gt;MIT&lt;/a&gt;&lt;/li&gt;
*&lt;/ul&gt;
*
*

&lt;img src=&quot;http://chargedweb.com/labs/files/2010/02/smile.png&quot; alt=&quot;&quot; /&gt;

*
* @availability 	flash/flex, as3
* @version 		2.1
*
* @example Flex sample:
*

* import com.chargedweb.utils.ResourceMonitorUtil;
*
* rawChildren.addChild(new ResourceMonitorUtil());
*  	 *
* @example Flash sample:
*
* import com.chargedweb.utils.ResourceMonitorUtil;
*
* addChild(new ResourceMonitorUtil());
*  	 */
public class ResourceMonitorUtil extends Sprite
{
////////////////
//
//	Infos
//
////////////////

/**
* Fps info text
* %fps% replaced by the current fps value
* %fpsMax% replaced by the current fpsMax value
*/
public static var FPS_INFO:String = &quot;Fps: %fps%/%fpsMax%&quot;;

/**
* Fps average info text %fpsAVG% replaced by the current average fps value
*/
public static var FPS_AVG_INFO:String = &quot;FpsAVG: %fpsAVG%&quot;;

/**
* Memory info text
* %memory% 		replaced by the current memory value [mb]
* %memoryMaxUsed% 	replaced by the max memory used so far [mb]
* %memoryMax% 		replaced by the current memoryMax value [mb]
*/
public static var MEMORY_INFO:String = &quot;Ram: %memory% (%memoryMaxUsed%) mb&quot;;

/**
* Memory average info text %memoryAVG% replaced by the current average memory value [mb]
*/
public static var MEMORY_AVG_INFO:String = &quot;RamAVG: %memoryAVG% mb&quot;;

////////////////
//
//	Styles
//
////////////////

// grid color
private var _gridColor:uint = 0xFFFFFF;

// grid alpha
private var _gridAlpha:Number = .25;

// background color
private var _backgroundColor:uint = 0x000000;

// background alpha
private var _backgroundAlpha:Number = 1;

// fps line size
private var _fpsLineSize:int = 2;

// fps line color
private var _fpsLineColor:uint = 0xFFCC00;

// memory line size
private var _memoryLineSize:int = 2;

// memory line color
private var _memoryLineColor:uint = 0x00CCFF;

// memory max used line size
private var _memoryMaxUsedLineSize:int = 1;

// memory max used line color
private var _memoryMaxUsedLineColor:uint = 0xFF0000;

////////////////
//
//	Misc
//
////////////////

// current memory used [bytes]
private var _memory:int = 0;

// current average memory used [bytes]
private var _memoryAVG:int = 0;

// max value of the used memory so far (the highest value stored in history for _historyLength steps)
private var _memoryMaxUsed:int = 0;

// maximum memory value [bytes] there always has to be a limit
private var _memoryMax:int = 500*1024*1024;

// max fps value
private var _fpsMax:int = 0;

// current fps value
private var _fps:int = 0;

// current average fps value
private var _fpsAVG:int = 0;

// whether to show the average fps value
private var _showFpsAVG:Boolean = true;

// whether to show the average memory value
private var _showMemoryAVG:Boolean = true;

// whether to show the grid
private var _showGrid:Boolean = true;

// whether to show the text field
private var _showText:Boolean = true;

// history {fps:int, memory:Number}
private var _history:Array;

// history length (steps to store i.e. records for the last &#039;n&#039; seconds)
private var _historyLength:int = 40;

// monitor timer
private var _monitorTimer:Timer;

// text format
private var _format:TextFormat = new TextFormat(&quot;Verdana&quot;, 10, 0x000000);

// textfield instance
private var _tf:TextField;

// background
private var _bg:Sprite;

// fps graph
private var _bgFps:Shape;

// memory graph
private var _bgMemory:Shape;

// memory graph
private var _bgMemoryMaxUsed:Shape;

// grid
private var _grid:Shape;

// frames counter
private var _frames:int = 0;

// width holder
private var _width:int = 160;

// height holder
private var _height:int = 150;

////////////////
//
//	PUBLIC
//
////////////////

/**
* Converts value from kilobytes to megabytes
* @param	value:int			kilobytes to convert
* @param	fractionDigits:int	an integer between 0 and 20, inclusive, that represents the desired number of decimal places @default 1
*/
public static function kbToMb(value:int, fractionDigits:int = 1):Number
{
if(fractionDigits &lt; 0 || fractionDigits &gt; 20) throw new Error(&quot;fractionDigits values must be between 0 and 20&quot;, 0);
return Number((value/(1024*1024)).toFixed(fractionDigits));
}

/**
* Constructor
* @return	nothing
*/
public function ResourceMonitorUtil()
{
super();
addEventListener(Event.ADDED_TO_STAGE, onAddedToStage);
}

/**
* Starts monitoring resource usage @see #stop()
* @return	nothing
*/
public function monitor():void
{
_monitorTimer.start();
if(!hasEventListener(Event.ENTER_FRAME)) addEventListener(Event.ENTER_FRAME, onFpsTimer);
dispatchEvent(new Event(Event.INIT));
}

/**
* Stops monitoring resource usage @see #monitor()
* @return 	nothing
*/
public function stop():void
{
_monitorTimer.stop();
if(hasEventListener(Event.ENTER_FRAME)) removeEventListener(Event.ENTER_FRAME, onFpsTimer);
}

/**
* Redraws everything
* @return	nothing
*/
public function redraw():void
{
redrawTextField();
redrawBackground();
redrawGrid();
redrawFpsGraph();
redrawMemoryGraph();
redrawMemoryMaxUsedGraph();
}

////////////////////////////////
//
//	SETTERS/GETTERS
//
////////////////////////////////

/**
* Overriden width property @default 160
* @param	value:Number	new width value
* @return	Number			current width value
*/
override public function set width(value:Number):void
{
_width = value;
redraw();
}
override public function get width():Number
{
return _width;
}

/**
* Overriden height property @default 150
* @param	value:Number	new height value
* @return	Number			current height value
*/
override public function set height(value:Number):void
{
_height = value;
redraw();
}
override public function get height():Number
{
return _height;
}

/**
* Sets/gets the textFormat for the TextField @default new TextFormat(&quot;Verdana&quot;, 10, 0x000000);
* @param	value:TextFormat	new text format
* @return	TextFormat			current text format
*/
public function set textFormat(value:TextFormat):void
{
_format = value;
redraw();
}
public function get textFormat():TextFormat
{
return _format;
}

/**
* Returns the history array of objects {fps:int, memory:Number}
* memory in bytes
* @return	Array		current history array
*/
public function get history():Array
{
return _history;
}

/**
* Sets/gets the history length (number of records to store in the history array 1 step = 1 sec) value @default 40
* @param	value:int	new history length value
* @return	int			current history length value
*/
public function set historyLength(value:int):void
{
_historyLength = value;
initHistory();
redraw();
}
public function get historyLength():int
{
return _historyLength;
}

/**
* Returns the current fps value
* @return	int		current fps value
*/
public function get fps():int
{
return _fps;
}

/**
* Returns the current average fps value
* @return	int		current average fps value
*/
public function get fpsAVG():int
{
return _fpsAVG;
}

/**
* Returns the max fps value
* @return	int		max fps value
*/
public function get fpsMax():int
{
return _fpsAVG;
}

/**
* Returns the current memory used value [bytes]
* @return	int		current memory used value [bytes]
*/
public function get memory():int
{
return _memory;
}

/**
* Returns the current average memory used value [bytes]
* @return	int		current average memory used value [bytes]
*/
public function get memoryAVG():int
{
return _memoryAVG;
}

/**
* Returs the max registered memory usage so far for the last &#039;n&#039; defined by the historyLength steps @see #historyLength
*/
public function get memoryMaxUsed():int
{
return _memoryMaxUsed;
}

/**
* Sets/gets the max memory value @default 500*1024*1024
* @param	value:int	new max memory value [bytes]
* @return	int			current max memory value [bytes]
*/
public function set memoryMax(value:int):void
{
_memoryMax = value;
redraw();
}
public function get memoryMax():int
{
return _memoryMax;
}

/**
* Sets/gets whether to show or not the average fps @default true
* @param	value:Boolean	new value
* @return	Boolean			current value
*/
public function set showFpsAVG(value:Boolean):void
{
_showFpsAVG = value;
redraw();
}
public function get showFpsAVG():Boolean
{
return _showFpsAVG;
}

/**
* Sets/gets whether to show or not the average memory @default true
* @param	value:Boolean	new value
* @return	Boolean			current value
*/
public function set showMemoryAVG(value:Boolean):void
{
_showMemoryAVG = value;
redraw();
}
public function get showMemoryAVG():Boolean
{
return _showMemoryAVG;
}

/**
* Sets/gets whether to show or not the textField info @default true
* @param	value:Boolean	new value
* @return	Boolean			current value
*/
public function set showText(value:Boolean):void
{
_showText = value;
redraw();
}
public function get showText():Boolean
{
return _showText;
}

/**
* Sets/gets whether to show or not the grid @default true
* @param	value:Boolean	new value
* @return	Boolean			current value
*/
public function set showGrid(value:Boolean):void
{
_showGrid = value;
redrawGrid();
}
public function get showGrid():Boolean
{
return _showGrid;
}

/**
* Sets/gets the grid color @default 0xFFFFFF
* @param	value:uint	new grid color value
* @return	uint		current grid color value
*/
public function set gridColor(value:uint):void
{
_gridColor = value;
redrawGrid();
}
public function get gridColor():uint
{
return _gridColor;
}

/**
* Sets/gets the grid alpha @default 0.25
* @param	value:Number	new grid alpha value
* @return	Number			current grid alpha value
*/
public function set gridAlpha(value:Number):void
{
_gridAlpha = value;
redrawGrid();
}
public function get gridAlpha():Number
{
return _gridAlpha;
}

/**
* Sets/gets the background color @default 0x000000
* @param	value:uint	new background color value
* @return	uint		current background color value
*/
public function set backgroundColor(value:uint):void
{
_backgroundColor = value;
redrawBackground();
}
public function get backgroundColor():uint
{
return _backgroundColor;
}

/**
* Sets/gets the background alpha @default 1
* @param	value:Number	new background alpha value
* @return	Number			current background alpha value
*/
public function set backgroundAlpha(value:Number):void
{
_backgroundAlpha = value;
redrawBackground();
}
public function get backgroundAlpha():Number
{
return _backgroundAlpha;
}

/**
* Sets/gets the fps line size @default 2
* @param	value:int	new fps line size value
* @return	int			current fps line size value
*/
public function set fpsLineSize(value:int):void
{
_fpsLineSize = value;
redrawFpsGraph();
}
public function get fpsLineSize():int
{
return _fpsLineSize;
}

/**
* Sets/gets the fps line color @default 0xFFCC00
* @param	value:uint	new fps line color value
* @return	uint		current fps line color value
*/
public function set fpsLineColor(value:uint):void
{
_fpsLineColor = value;
redrawFpsGraph();
}
public function get fpsLineColor():uint
{
return _fpsLineColor;
}

/**
* Sets/gets the memory line size @default 2
* @param	value:int	new memory line size value
* @return	int			current memory line size value
*/
public function set memoryLineSize(value:int):void
{
_memoryLineSize = value;
redrawMemoryGraph();
}
public function get memoryLineSize():int
{
return _memoryLineSize;
}

/**
* Sets/gets the memory line color @default 0x00CCFF
* @param	value:uint	new memory line color value
* @return	uint		current memory line color value
*/
public function set memoryLineColor(value:uint):void
{
_memoryLineColor = value;
redrawMemoryGraph();
}
public function get memoryLineColor():uint
{
return _memoryLineColor;
}

/**
* Sets/gets the max used memory line size @default 1
* @param	value:int	new memory line size value
* @return	int			current memory line size value
*/
public function set memoryMaxUsedLineSize(value:int):void
{
_memoryMaxUsedLineSize = value;
redrawMemoryMaxUsedGraph();
}
public function get memoryMaxUsedLineSize():int
{
return _memoryMaxUsedLineSize;
}

/**
* Sets/gets max used memory line color @default 0xFF0000
* @param	value:uint	new memory line color value
* @return	uint		current memory line color value
*/
public function set memoryMaxUsedLineColor(value:uint):void
{
_memoryMaxUsedLineColor = value;
redrawMemoryMaxUsedGraph();
}
public function get memoryMaxUsedLineColor():uint
{
return _memoryMaxUsedLineColor;
}

////////////////
//
//	PRIVATE
//
////////////////

/**
* @private Inits the history array
* @return 	nothing
*/
private function initHistory():void
{
_history = new Array();

for(var i:int = 0; i &lt; _historyLength; i++)
_history.push({fps: _fpsMax, memory: 0, memoryMaxUsed: 0});
}

/**
* @private Creates children
* @return nothing
*/
private function createChildren():void
{
_tf = new TextField();
_tf.defaultTextFormat = _format;
_tf.autoSize = TextFieldAutoSize.LEFT;
_tf.multiline = true;
_tf.wordWrap = true;
_tf.selectable = false;
this.addChild(_tf);

_bg = new Sprite();
this.addChild(_bg);

_grid = new Shape();
_bg.addChild(_grid);

_bgFps = new Shape();
_bg.addChild(_bgFps);

_bgMemoryMaxUsed = new Shape();
_bg.addChild(_bgMemoryMaxUsed);

_bgMemory = new Shape();
_bg.addChild(_bgMemory);

redraw();
monitor();
}

/**
* @private Redraws the textField
* @return	nothing
*/
private function redrawTextField():void
{
if(!_tf) return;
_tf.width = _width;

if(_showText)
{
_tf.text = FPS_INFO.replace(&quot;%fps%&quot;, _fps).replace(&quot;%fpsMax%&quot;, _fpsMax);
if(_showFpsAVG) _tf.appendText(&quot;\n&quot;+FPS_AVG_INFO.replace(&quot;%fpsAVG%&quot;, _fpsAVG));
_tf.appendText(&quot;\n&quot;+MEMORY_INFO.replace(&quot;%memory%&quot;, kbToMb(_memory)).replace(&quot;%memoryMaxUsed%&quot;, kbToMb(_memoryMaxUsed)).replace(&quot;%memoryMax%&quot;, kbToMb(_memoryMax)));
if(_showMemoryAVG) _tf.appendText(&quot;\n&quot;+MEMORY_AVG_INFO.replace(&quot;%memoryAVG%&quot;, kbToMb(_memoryAVG)));
}else{
_tf.text = &quot;&quot;;
}
}

/**
* @private Redraws the background
* @return	nothing
*/
private function redrawBackground():void
{
if(!_bg) return;
_bg.x = 0;
_bg.y = int(_tf.height);
_bg.graphics.clear();
_bg.graphics.beginFill(_backgroundColor, _backgroundAlpha);
_bg.graphics.drawRect(0, 0, _width, _height - _bg.y);
_bg.graphics.endFill();
}

/**
* @private Redraws the grid
* @return	nothing
*/
private function redrawGrid():void
{
if(!_grid) return;
var step:Number = _width/_historyLength;

_grid.graphics.clear();
_grid.visible = _showGrid;
if(!_showGrid) return;

for(var i:int = 0; i &lt; _historyLength; i++)
{
_grid.graphics.lineStyle(1, _gridColor, _gridAlpha, false, &quot;normal&quot;, &quot;none&quot;, JointStyle.MITER);
_grid.graphics.moveTo(i*step, 0);
_grid.graphics.lineTo(i*step, _height - _bg.y);
_grid.graphics.endFill();
}
}

/**
* @private Redraws the fps graph
* @return	nothing
*/
private function redrawFpsGraph():void
{
if(!_bgFps) return;
var step:Number = _width/_historyLength;
var h:int = _height - _bg.y;

_bgFps.graphics.clear();
_bgFps.graphics.lineStyle(_fpsLineSize, _fpsLineColor, 1, false, &quot;normal&quot;, &quot;none&quot;, JointStyle.MITER);

for(var i:int = 0; i &lt; _historyLength; i++)
{
if(i == 0) _bgFps.graphics.moveTo(step*i, (_history[i].fps/_fpsMax)*h);
else _bgFps.graphics.lineTo(step*i, (_history[i].fps/_fpsMax)*h);
}

_bgFps.graphics.endFill();
}

/**
* @private Redraws the memory graph
* @return	nothing
*/
private function redrawMemoryGraph():void
{
if(!_bgMemory) return;
var step:Number = _width/_historyLength;
var h:int = _height - _bg.y;

_bgMemory.graphics.clear();
_bgMemory.graphics.lineStyle(_memoryLineSize, _memoryLineColor, 1, false, &quot;normal&quot;, &quot;none&quot;, JointStyle.MITER);

for(var i:int = 0; i &lt; _historyLength; i++)
{
if(i == 0) _bgMemory.graphics.moveTo(step*i, h - (_history[i].memory/_memoryMax)*h);
else _bgMemory.graphics.lineTo(step*i, h - (_history[i].memory/_memoryMax)*h);
}

_bgMemory.graphics.endFill();
}

/**
* @private Redraws the memory graph
* @return	nothing
*/
private function redrawMemoryMaxUsedGraph():void
{
if(!_bgMemory) return;
var step:Number = _width/_historyLength;
var h:int = _height - _bg.y;

_bgMemoryMaxUsed.graphics.clear();
_bgMemoryMaxUsed.graphics.lineStyle(_memoryMaxUsedLineSize, _memoryMaxUsedLineColor, 1, false, &quot;normal&quot;, &quot;none&quot;, JointStyle.MITER);

for(var i:int = 0; i &lt; _historyLength; i++)
{
if(i == 0) _bgMemoryMaxUsed.graphics.moveTo(step*i, h - (_history[i].memoryMaxUsed/_memoryMax)*h);
else _bgMemoryMaxUsed.graphics.lineTo(step*i, h - (_history[i].memoryMaxUsed/_memoryMax)*h);
}

_bgMemoryMaxUsed.graphics.endFill();
}

/**
* @private Counts the current average fps value
* @return	int		current average fps value
*/
private function countFpsAVG():int
{
var f:int = 0;
var n:int = 0
for(var i:int = 0; i &lt; _historyLength; i++) 			{ 				f += _history[i].fps; 				if(_history[i].fps &gt; 0) n++;
}

return (f/n &gt; 0) ? (f/n) : 0;
}

/**
* @private Counts the current average memory value
* @return	int		current average memory value
*/
private function countMemoryAVG():int
{
var m:Number = 0;
var n:int = 0
for(var i:int = 0; i &lt; _historyLength; i++) 			{ 				m += _history[i].memory; 				if(_history[i].memory &gt; 0) n++;
}

return (n &gt; 0) ? (m/n) : 0;
}

/**
* @private Counts the max memory used so far
* @return	int		max used memory so far value
*/
private function countMemoryMaxUsed():int
{
var m:int = 0
for(var i:int = 0; i &lt; _historyLength; i++) 			{ 				if(_history[i].memory &gt; m) m = _history[i].memory;
}

return m;
}

/**
* @private Monitor timer handler
* @return	nothing
*/
private function onMonitorTimer(event:TimerEvent):void
{
_fpsMax = stage.frameRate;
_fps = (_frames &gt; _fpsMax) ? _fpsMax : _frames;
_fpsAVG = countFpsAVG();
_memory = System.totalMemory;
_memory = (_memory &gt; _memoryMax) ? _memoryMax : _memory; // else the graph will exceed the limits
_memoryAVG = countMemoryAVG();
_memoryMaxUsed = countMemoryMaxUsed();
_memoryMaxUsed = (_memoryMaxUsed &gt; _memoryMax) ? _memoryMax : _memoryMaxUsed; // else the graph will exceed the limits
_frames = 0;

_history.splice(0,1);
_history.push({fps: _fps, memory: _memory, memoryMaxUsed: _memoryMaxUsed});

redraw();
dispatchEvent(new Event(Event.CHANGE));
}

/**
* @private Fps timer handler
* @return	nothing
*/
private function onFpsTimer(event:Event):void
{
_frames++;
}

/**
* @private ADDED_TO_STAGE handler
* @param	event:Event		event
* @return	nothing
*/
private function onAddedToStage(event:Event):void
{
if(!_monitorTimer)
{
_monitorTimer = new Timer(1000);
_monitorTimer.addEventListener(TimerEvent.TIMER, onMonitorTimer);
}

if(!hasEventListener(Event.ENTER_FRAME)) addEventListener(Event.ENTER_FRAME, onFpsTimer);

_fpsMax = stage.frameRate;
initHistory();
createChildren();
removeEventListener(Event.ADDED_TO_STAGE, onAddedToStage);
}
}
}
</pre>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/05/06/resourcemonitor-v2-resourcemonitorutil/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>The com.chargedweb.* package, sort of</title>
		<link>http://chargedweb.com/labs/2010/05/05/comchargedweb-package/</link>
		<comments>http://chargedweb.com/labs/2010/05/05/comchargedweb-package/#comments</comments>
		<pubDate>Wed, 05 May 2010 22:20:46 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[chargedweb]]></category>
		<category><![CDATA[com]]></category>
		<category><![CDATA[package]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=418</guid>
		<description><![CDATA[I&#8217;ve decided to make a sort of a mini package containing some handy utils (but not only) classes in one place. Includes such classes like: VectorUtil, ResourceMonitor, MatrixUtil, LoaderUtil, Cache, VimeoPlayer, SkypeStatusIcon etc. Download the com.chargedweb.* package UPD1: now with docs UPD2: - added AlignUtil class (more info here) ps: i wish i had some [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve decided to make a sort of a mini package containing some handy utils (but not only) classes in one place.</p>
<p>Includes such classes like: VectorUtil, ResourceMonitor, MatrixUtil, LoaderUtil, Cache, VimeoPlayer, SkypeStatusIcon etc.<br />
<strong><br />
<a href="http://chargedweb.com/labs/files/2010/05/com.chargedweb.zip">Download the com.chargedweb.* package</a></strong></p>
<h3><strong>UPD1: </strong>now with docs</h3>
<h3><strong>UPD2: </strong></h3>
<p>- added AlignUtil class (more info <a href="http://chargedweb.com/labs/2010/07/27/alignutil_align_objects_easily/">here</a>)</p>
<p>ps: i wish i had some free time to collect all my classes in one huge package <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/05/05/comchargedweb-package/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>An approach that every CEO should follow</title>
		<link>http://chargedweb.com/labs/2010/05/05/approach-ceo-follow/</link>
		<comments>http://chargedweb.com/labs/2010/05/05/approach-ceo-follow/#comments</comments>
		<pubDate>Wed, 05 May 2010 21:29:44 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[thoughts]]></category>
		<category><![CDATA[approach]]></category>
		<category><![CDATA[ceo]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=413</guid>
		<description><![CDATA[Some time ago i came across http://startupquote.com/ and decided to post my own quote here.Hope, i ever get to startupquote.com &#8220;Being a CEO doesn&#8217;t imply being an ass.&#8221; Me]]></description>
			<content:encoded><![CDATA[<p>Some time ago i came across <a href="http://startupquote.com/">http://startupquote.com/</a> and decided to post my own quote here.<br/>Hope, i ever get to startupquote.com <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> <br/><br/></p>
<table>
<tbody>
<tr>
<td><em><strong>&#8220;Being a CEO doesn&#8217;t imply being an ass.&#8221;</strong></em></td>
</tr>
<tr>
<td style="text-align: right;"><em>Me</em></td>
</tr>
</tbody>
</table>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/05/05/approach-ceo-follow/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Freebie icons</title>
		<link>http://chargedweb.com/labs/2010/05/03/freebie-icons-2/</link>
		<comments>http://chargedweb.com/labs/2010/05/03/freebie-icons-2/#comments</comments>
		<pubDate>Mon, 03 May 2010 10:26:03 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[graphics]]></category>
		<category><![CDATA[disk]]></category>
		<category><![CDATA[icon]]></category>
		<category><![CDATA[paper]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=406</guid>
		<description><![CDATA[I&#8217;m not a designer actually, i just love drawing from time to time Overview Download icons + source]]></description>
			<content:encoded><![CDATA[<p><a href="http://chargedweb.com/labs/files/2010/05/disk_paper_ow.jpg"><img src="http://chargedweb.com/labs/files/2010/05/disk_paper_ow-300x300.jpg" alt="" title="disk_paper_ow" width="300" height="300"  /></a></p>
<p>I&#8217;m not a designer actually, i just love drawing from time to time <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> <br/><br />
<a href="http://chargedweb.com/labs/files/2010/05/page_disk_overview.jpg">Overview</a><br />
<a href="http://chargedweb.com/labs/files/2010/05/dp_icons.zip">Download icons + source</a></p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/05/03/freebie-icons-2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Apple truth revealed</title>
		<link>http://chargedweb.com/labs/2010/05/03/apple-truth-revealed/</link>
		<comments>http://chargedweb.com/labs/2010/05/03/apple-truth-revealed/#comments</comments>
		<pubDate>Mon, 03 May 2010 09:31:56 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[thoughts]]></category>
		<category><![CDATA[adobe]]></category>
		<category><![CDATA[apple]]></category>
		<category><![CDATA[Flash]]></category>
		<category><![CDATA[truth]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=396</guid>
		<description><![CDATA[Well, i guess everybody knows now about the &#8220;apple vs adobe&#8221; conflict. And, probably, you&#8217;ve already read the Steve&#8217;s open letter. I won&#8217;t reveal the &#8220;truth&#8221; of the statments mentioned in this letter. But, actually, you can figure that out on your own, by watching for example this video about &#8220;how FAST and GOOD html5 [...]]]></description>
			<content:encoded><![CDATA[<p>Well, i guess everybody knows now about the &#8220;apple vs adobe&#8221; conflict.<br />
And, probably, you&#8217;ve already read the <a href="http://www.apple.com/hotnews/thoughts-on-flash/">Steve&#8217;s open letter</a>.<br />
I won&#8217;t reveal the &#8220;<em>truth</em>&#8221; of the statments mentioned in this letter.<br />
But, actually, you can figure that out on your own, by watching for example this video about &#8220;how FAST and GOOD html5 is on iPad&#8221;.<br />
No comments just lol <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><object width="400" height="300"><param name="movie" value="http://www.youtube.com/v/rfmbZkqORX4&#038;hl=en_GB&#038;fs=1&#038;"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/rfmbZkqORX4&#038;hl=en_GB&#038;fs=1&#038;" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="400" height="300"></embed></object></p>
<p>Now compare it to the &#8220;SLOW flashplayer&#8221;</p>
<p><object width="400" height="225"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="movie" value="http://vimeo.com/moogaloop.swf?clip_id=9596010&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=&amp;fullscreen=1" /><embed src="http://vimeo.com/moogaloop.swf?clip_id=9596010&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=&amp;fullscreen=1" type="application/x-shockwave-flash" allowfullscreen="true" allowscriptaccess="always" width="400" height="225"></embed></object></p>
<p>ps: Back to the Mesozoic era? O.o</p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/05/03/apple-truth-revealed/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Fast brightness, contrast, saturation</title>
		<link>http://chargedweb.com/labs/2010/04/30/fast_brightness_contrast_saturation/</link>
		<comments>http://chargedweb.com/labs/2010/04/30/fast_brightness_contrast_saturation/#comments</comments>
		<pubDate>Fri, 30 Apr 2010 08:44:14 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[brightness]]></category>
		<category><![CDATA[ColorMatrixFilter]]></category>
		<category><![CDATA[contrast]]></category>
		<category><![CDATA[saturation]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=386</guid>
		<description><![CDATA[Sorry for the late update. I had lots of work &#038; devs recently and there&#8217;re still more to go. But, still i&#8217;ve found some spare time to post this little (hope useful) utility class. //////////////////////////////////////////////////////////////////////////////// // // Copyright 2010 Julius Loa &#124; jloa@chargedweb.com // All Rights Reserved. // license: GNU {http://www.opensource.org/licenses/gpl-2.0.php} // notice: just keep [...]]]></description>
			<content:encoded><![CDATA[<p>Sorry for the late update. I had lots of work &#038; devs recently and there&#8217;re still more to go.<br />
But, still i&#8217;ve found some spare time to post this little (hope useful) utility class.</p>
<pre class="brush: as3; ">

////////////////////////////////////////////////////////////////////////////////
//
//  Copyright 2010 Julius Loa | jloa@chargedweb.com
//  All Rights Reserved.
//  license: GNU {http://www.opensource.org/licenses/gpl-2.0.php}
//  notice: just keep the header plz
//
////////////////////////////////////////////////////////////////////////////////

package com.chargedweb.utils
{
	import flash.filters.ColorMatrixFilter;

	/**
	 * Matrix utility class
	 * @version 1.0
	 * so far added:
	 * - brightness
	 * - contrast
	 * - saturation
	 */
	public class MatrixUtil
	{
		/**
		 * sets brightness value available are -100 ~ 100 @default is 0
		 * @param 		value:int	brightness value
		 * @return		ColorMatrixFilter
		 */
		public static function setBrightness(value:Number):ColorMatrixFilter
		{
			value = value*(255/250);

			var m:Array = new Array();
    		m = m.concat([1, 0, 0, 0, value]);	// red
   		 	m = m.concat([0, 1, 0, 0, value]);	// green
   		 	m = m.concat([0, 0, 1, 0, value]);	// blue
    		m = m.concat([0, 0, 0, 1, 0]);		// alpha

    		return new ColorMatrixFilter(m);
		}

		/**
		 * sets contrast value available are -100 ~ 100 @default is 0
		 * @param 		value:int	contrast value
		 * @return		ColorMatrixFilter
		 */
		public static function setContrast(value:Number):ColorMatrixFilter
		{
			value /= 100;
			var s: Number = value + 1;
    		var o : Number = 128 * (1 - s);

			var m:Array = new Array();
			m = m.concat([s, 0, 0, 0, o]);	// red
			m = m.concat([0, s, 0, 0, o]);	// green
			m = m.concat([0, 0, s, 0, o]);	// blue
			m = m.concat([0, 0, 0, 1, 0]);	// alpha

			return new ColorMatrixFilter(m);
		}

		/**
		 * sets saturation value available are -100 ~ 100 @default is 0
		 * @param 		value:int	saturation value
		 * @return		ColorMatrixFilter
		 */
		public static function setSaturation(value:Number):ColorMatrixFilter
		{
			const lumaR:Number = 0.212671;
    		const lumaG:Number = 0.71516;
    		const lumaB:Number = 0.072169;

			var v:Number = (value/100) + 1;
			var i:Number = (1 - v);
   		 	var r:Number = (i * lumaR);
    		var g:Number = (i * lumaG);
    		var b:Number = (i * lumaB);

			var m:Array = new Array();
			m = m.concat([(r + v), g, b, 0, 0]);	// red
			m = m.concat([r, (g + v), b, 0, 0]);	// green
			m = m.concat([r, g, (b + v), 0, 0]);	// blue
			m = m.concat([0, 0, 0, 1, 0]);			// alpha

 			return new ColorMatrixFilter(m);
		}
	}
}
</pre>
<p>And the sample usage code:</p>
<pre class="brush: as3; ">

import com.chargedweb.utils.MatrixUtil;

var bmp:Bitmap = new Bitmap(new Image(0,0));
addChild(bmp);
bmp.filters = [MatrixUtil.setBrightness(20),
			   MatrixUtil.setContrast(20),
			   MatrixUtil.setSaturation(-100)];
</pre>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/04/30/fast_brightness_contrast_saturation/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>Revolutionary actionscript editor</title>
		<link>http://chargedweb.com/labs/2010/04/10/revolutionary-actionscript-editor/</link>
		<comments>http://chargedweb.com/labs/2010/04/10/revolutionary-actionscript-editor/#comments</comments>
		<pubDate>Sat, 10 Apr 2010 14:57:39 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[news]]></category>
		<category><![CDATA[actionscript]]></category>
		<category><![CDATA[editor]]></category>
		<category><![CDATA[mps]]></category>
		<category><![CDATA[realaxy]]></category>
		<category><![CDATA[revolutionary]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=358</guid>
		<description><![CDATA[I&#8217;ve already twitted/faced about this editor a while ago, but still, now that i&#8217;ve contacted Ivan Dembicki, the CEO and developer of Realaxy LTD (you might know Iv by his bezier project) and Evgeniy Potapenko (CEO), i&#8217;ve sniffed out some new details about their revolutionary actionscript editor called Realaxy ActionScript Editor. So, for those of [...]]]></description>
			<content:encoded><![CDATA[<table>
<tbody>
<tr>
<td><img title="realaxy as editor" src="http://pics.livejournal.com/ivan_dembicki/pic/000019kt/s320x240" alt="" width="240" height="240" /></td>
</tr>
<tr bgcolor="#000000">
<td align="center"><img title="realaxy" src="http://realaxy.com/images/realaxy.gif" alt="" width="215" height="42" /><br />
<img title="as editor" src="http://realaxy.com/images/ase.gif" alt="" width="255" height="42" /></td>
</tr>
</tbody>
</table>
<p>I&#8217;ve already twitted/faced about this editor a while ago, but still, now that i&#8217;ve contacted <a href="http://www.facebook.com/ivan.dembicki">Ivan Dembicki</a>, the CEO and developer of <a href="http://realaxy.com/">Realaxy LTD</a> (you might know Iv by his <a href="http://code.google.com/p/bezier/">bezier project</a>) and <a href="http://www.facebook.com/profile.php?id=100000195071028#!/profile.php?id=100000195071028">Evgeniy Potapenko</a> (CEO), i&#8217;ve sniffed out some new details about their revolutionary actionscript editor called <a href="http://realaxy.com/">Realaxy ActionScript Editor</a>.</p>
<p>So, for those of you that don&#8217;t know what&#8217;s this all about &#8211; it&#8217;s all about the new revolutionary actionscript editor called the <a href="http://realaxy.com/">Realaxy ActionScript Editor</a> developed by the <a href="http://realaxy.com/">Realaxy team</a>.</p>
<h3><a href="http://chargedweb.com/labs/2010/04/10/revolutionary-actionscript-editor/#update"><span style="color: #ff0000;"><span style="text-decoration: underline;"><strong>UPDATED</strong></span></span> (clickable)</a></h3>
<p><span id="more-358"></span></p>
<p>So, what is so revolutionary about it?<br />
Well, here are its advantages at first sight:</p>
<ul>
<li>written on <a href="http://www.jetbrains.com/mps/index.html">JetBrains MPS</a></li>
<li>smart autocomplite</li>
<li>autocomplete E4X</li>
<li>metadata autocomplete</li>
<li>extended smart E4X</li>
<li>rapid development of methods, fields, and other language constructs only by pressing Enter</li>
<li>method parameters suggestion in code</li>
<li>getters/setters generation</li>
<li>toString generation</li>
<li>event handlers generation</li>
<li>override/implements methods</li>
<li>lots of Refactorings features</li>
<li>powerful bug tracing (FlexUnit, Debugger and Profiler in dev)</li>
<li><strong>Language extensions</strong> (Realaxy Action Script Editor is the only ActionScript editor allowing you to create and use language extensions. Even today Enums, Collection Language and Generics language extensions are available for you. Next in turn are Flow Language, plug-in architecture support, pattern support and caching language. But even that is not all. You can create language extensions and share them with other editor users.)</li>
</ul>
<p>&#8230;and <strong>MORE</strong></p>
<p>Here&#8217;s the &#8220;Smart auto complete demo&#8221; that i just love <span style="text-decoration: line-through;">say hi to adobe <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </span></p>
<p><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="400" height="255" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://vimeo.com/moogaloop.swf?clip_id=7502594&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=&amp;fullscreen=1" /><embed type="application/x-shockwave-flash" width="400" height="255" src="http://vimeo.com/moogaloop.swf?clip_id=7502594&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=&amp;fullscreen=1" allowscriptaccess="always" allowfullscreen="true"></embed></object></p>
<h3><strong><a href="http://vimeo.com/tag:realaxy">See other Realaxy editor demos here</a>.</strong></h3>
<h3><span style="text-decoration: underline;"><strong>Release date:</strong></span> <span style="color: #ff0000;"><strong>Realaxy Action Script Editor 1.0 is planned to the<span style="color: #c10000;"><span style="text-decoration: underline;"> end of august 2010</span></span></strong>.</span></h3>
<p>That&#8217;s it for now, guys. All that i can tell for now.<br />
I&#8217;ll keep you in touch. <img title="smile_wink" src="http://www.senocular.com/smilies/wink.gif" alt="" width="17" height="17" /></p>
<p>ps: can&#8217;t wait to get my hands on the private demo <img title="smile_wide" src="http://www.senocular.com/smilies/smilewide.gif" alt="" width="23" height="22" /></p>
<h3 id="update"><span style="color: #ff0000;"><span style="text-decoration: underline;"><strong>UPDATE:</strong></span></span></h3>
<p>I&#8217;ve just sneaked out some new <strong>vital &amp; hillarious</strong> Realaxy features.<br />
You will be able to code <strong>java</strong> and <strong>objective C</strong> applications on your favourite <strong>ActionScript 3.0</strong>. Unbelievable, isn&#8217;t it? <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>The whole thing is that there&#8217;s a retranslation mechanism which will automatically generate a java/objective c code for ya, as i&#8217;ve understood. And what that means is that you WILL be able to dev apps for the Apple AppStore.<br />
Say &#8220;hi&#8221; to Steveeee <img title="tongue" src="http://chargedweb.com/ff/forum/skins/smilies/icon_razz.png" alt="" width="15" height="15" /></p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/04/10/revolutionary-actionscript-editor/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Just a short poll guys</title>
		<link>http://chargedweb.com/labs/2010/04/09/short-poll-guys/</link>
		<comments>http://chargedweb.com/labs/2010/04/09/short-poll-guys/#comments</comments>
		<pubDate>Fri, 09 Apr 2010 10:46:35 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[misc]]></category>
		<category><![CDATA[content]]></category>
		<category><![CDATA[poll]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=352</guid>
		<description />
			<content:encoded><![CDATA[Note: There is a poll embedded within this post, please visit the site to participate in this post's poll.
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/04/09/short-poll-guys/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Google decides to intergrate Flash Player in Google Chrome</title>
		<link>http://chargedweb.com/labs/2010/03/31/google-decides-intergrate-flash-player-google-chrome/</link>
		<comments>http://chargedweb.com/labs/2010/03/31/google-decides-intergrate-flash-player-google-chrome/#comments</comments>
		<pubDate>Wed, 31 Mar 2010 15:07:21 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[news]]></category>
		<category><![CDATA[thoughts]]></category>
		<category><![CDATA[chrome]]></category>
		<category><![CDATA[flash player]]></category>
		<category><![CDATA[google]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=341</guid>
		<description><![CDATA[Google is a key participant in the Open Screen Project and shares our commitment to driving innovation on the Web. With this common goal in mind, Adobe and Google are collaborating to take the Flash Player experience to the next level by supporting a deeper integration with Google&#8217;s Chrome browser. Today, Google is releasing the [...]]]></description>
			<content:encoded><![CDATA[<p>Google is a key participant in the Open Screen Project and shares our commitment to driving innovation on the Web. With this common goal in mind, Adobe and Google are collaborating to take the Flash Player experience to the next level by supporting a deeper integration with Google&#8217;s Chrome browser. Today, Google is releasing the initial integration of Flash Player with Chrome in their developer channel, behind a command line flag. Moving forward, Google will be including Flash Player in Chrome so users will always have the most current release and a safer and more seamless experience.</p>
<blockquote><p>
We believe this initiative will help our users in the following ways:<br />
    * When users download Chrome, they will also receive the latest version of Adobe Flash Player. There will be no need to install Flash Player separately.<br />
    * Users will automatically receive updates related to Flash Player using Google Chrome’s auto-update mechanism. This eliminates the need to manually download separate updates and reduces the security risk of using outdated versions.<br />
    * With Adobe&#8217;s help, we plan to further protect users by extending Chrome&#8217;s “sandbox” to web pages with Flash content.</p></blockquote>
<p>More about it here:<br />
<a href="http://blog.chromium.org/2010/03/bringing-improved-support-for-adobe.html">Bringing improved support for Adobe Flash Player to Google Chrome</a><br />
<a href="http://blogs.adobe.com/flashplayer/2010/03/improved_flash_player_support.html">Improved Flash Player Support in Chrome</a></p>
<p>ps: ain&#8217;t that awesome? No need for player detection, version updates in Chrome now ^_^</p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/03/31/google-decides-intergrate-flash-player-google-chrome/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hex face color</title>
		<link>http://chargedweb.com/labs/2010/03/28/hex-face-color/</link>
		<comments>http://chargedweb.com/labs/2010/03/28/hex-face-color/#comments</comments>
		<pubDate>Sun, 28 Mar 2010 10:30:54 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[graphics]]></category>
		<category><![CDATA[misc]]></category>
		<category><![CDATA[color]]></category>
		<category><![CDATA[face]]></category>
		<category><![CDATA[hex]]></category>
		<category><![CDATA[skin]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=337</guid>
		<description><![CDATA[Amusing overlap i&#8217;ve discovered. Q: What hex color do i use to get the face skin color? A: Use the &#8216;#FACED0&#8216; value lol]]></description>
			<content:encoded><![CDATA[<p>Amusing overlap i&#8217;ve discovered.<br />
<strong>Q: What hex color do i use to get the face skin color?</strong><br />
<strong>A: Use the &#8216;<span style="color: #faced0;">#FACED0</span>&#8216; value </strong> lol <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/03/28/hex-face-color/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Flex4 finally shipped</title>
		<link>http://chargedweb.com/labs/2010/03/22/flex4-finally-shipped/</link>
		<comments>http://chargedweb.com/labs/2010/03/22/flex4-finally-shipped/#comments</comments>
		<pubDate>Mon, 22 Mar 2010 22:41:44 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[misc]]></category>
		<category><![CDATA[news]]></category>
		<category><![CDATA[flash builder]]></category>
		<category><![CDATA[flex4]]></category>
		<category><![CDATA[gumbo]]></category>
		<category><![CDATA[release]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=328</guid>
		<description><![CDATA[Flex 4, Gumbo or Flash Builder or whatever u like 2 call it is finally out http://opensource.adobe.com/wiki/display/site/Home Flex 4 has 3 primary themes: Design in Mind: provide a framework meant for continuous collaboration between designer and developer. Developer Productivity: improve compiler performance and add productivity enhancements to language features like data binding Framework Evolution: take [...]]]></description>
			<content:encoded><![CDATA[<p>Flex 4, Gumbo or Flash Builder or whatever u like 2 call it is finally out <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
<a href="http://opensource.adobe.com/wiki/display/site/Home">http://opensource.adobe.com/wiki/display/site/Home</a><br/><br />
<object width="425" height="256"><param name="movie" value="http://images.tv.adobe.com/swf/player.swf"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><param name="FlashVars" value="fileID=5510&#038;context=76&#038;embeded=true&#038;environment=production"></param><embed src="http://images.tv.adobe.com/swf/player.swf" flashvars="fileID=5510&#038;context=76&#038;embeded=true&#038;environment=production" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="256"></embed></object><br />
<br/>Flex 4 has 3 primary themes:</p>
<ul>
<li>Design in Mind: provide a framework meant for continuous collaboration between designer and developer.</li>
<li>Developer Productivity: improve compiler performance and add productivity enhancements to language features like data binding</li>
<li>Framework Evolution: take advantage of new Flash Player capabilities and add features required by common use-cases</li>
</ul>
<p>ps: sry too tired to write more. But soon.</p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/03/22/flex4-finally-shipped/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Fast black’n'white trick</title>
		<link>http://chargedweb.com/labs/2010/03/18/fast-blacknwhite-trick/</link>
		<comments>http://chargedweb.com/labs/2010/03/18/fast-blacknwhite-trick/#comments</comments>
		<pubDate>Fri, 19 Mar 2010 01:39:04 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[misc]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[black'n'white]]></category>
		<category><![CDATA[saturation]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=325</guid>
		<description><![CDATA[Sometimes i need a fast black&#8217;n'white saturation method and this one&#8217;s the shortest i presume. I can&#8217;t remember whose this method originally was, but it&#8217;s nice. private var rc:Number = 1/3, gc:Number = 1/3, bc:Number = 1/3; private var sf:ColorMatrixFilter = new ColorMatrixFilter([rc, gc, bc, 0, 0, rc, gc, bc, 0, 0, rc, gc, bc, [...]]]></description>
			<content:encoded><![CDATA[<p>Sometimes i need a fast black&#8217;n'white saturation method and this one&#8217;s the shortest i presume.<br />
I can&#8217;t remember whose this method originally was, but it&#8217;s nice.</p>
<pre class="brush: as3; ">

private var rc:Number = 1/3, gc:Number = 1/3, bc:Number = 1/3;
private var sf:ColorMatrixFilter = new ColorMatrixFilter([rc, gc, bc, 0, 0, rc, gc, bc, 0, 0, rc, gc, bc, 0, 0, 0, 0, 0, 1, 0]);

private function blackAndWhite(target:UIComponent, enabled:Boolean):void
{
   if(enabled) target.filters = [sf];
   else target.filters = [];
}
</pre>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/03/18/fast-blacknwhite-trick/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Flex CursorManager vs jloa</title>
		<link>http://chargedweb.com/labs/2010/03/12/flex-cursormanager-vs-jloa/</link>
		<comments>http://chargedweb.com/labs/2010/03/12/flex-cursormanager-vs-jloa/#comments</comments>
		<pubDate>Fri, 12 Mar 2010 17:30:33 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[cursor]]></category>
		<category><![CDATA[CursorManager]]></category>
		<category><![CDATA[flex]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=316</guid>
		<description><![CDATA[So there i was, trying to build my latest application which involved run-time cursor loading/usage. I knew that the flex sdk had that static CursorManager class (i.e. mx.core.CursorManager), but as i looked up the manual &#8211; there&#8217;s no loadIcon() method, only setters that require class references which is sooooo unhandy if u deal with run-time [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://chargedweb.com/labs/files/2010/03/cursormanager.png"><img class="alignnone size-medium wp-image-317" title="cursormanager" src="http://chargedweb.com/labs/files/2010/03/cursormanager-300x250.png" alt="" width="300" height="250" /></a></p>
<p><strong>So</strong> there i was, trying to build my latest application which involved run-time cursor loading/usage.<br />
I knew that the flex sdk had that static CursorManager class (i.e. mx.core.CursorManager), but as i looked up the manual &#8211; there&#8217;s no loadIcon() method, only setters that require class references which is sooooo unhandy if u deal with run-time loading assets (like i do).<br />
So, i got myself some coffee, opened the eclipse and after some time spend &#8211; eureka!<br />
I came to this slight solution which besides is elementary. <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><span id="more-316"></span><br />
Ok, less words &#8211; more action.<br />
Here&#8217;s the class and the usage below:</p>
<pre class="brush: as3; ">

////////////////////////////////////////////////////////////////////////////////
//
//  Copyright 2009 Julius Loa | jloa@chargedweb.com
//  All Rights Reserved.
//  license: GNU {http://www.opensource.org/licenses/gpl-2.0.php}
//  notice: just keep the header plz
//
////////////////////////////////////////////////////////////////////////////////

package com.chargedweb.utils
{
import flash.net.URLRequest;
import flash.display.Loader;

/**
 * CursorFactory class for usage with @see mx.core.CursorManager
 *
 * @example
 * &lt;pre&gt;
 * import com.chargedweb.utils.CursorFactory;
 * import mx.core.CursorManager;
 *
 * CursorFactory.URL = &quot;../assets/skins/icons/my_cursor.png&quot;;
 * CursorManager.setCursor(CursorFactory);
 * &lt;/pre&gt;
 */

public class CursorFactory extends Loader
 {
   /**
    * Custom cursor url value
    */
   public static var URL:String;

   /**
    * Constructor
    */
   public function CursorFactory()
   {
      super();
      if(URL) load(new URLRequest(URL));
   }
 }
}
</pre>
<p>And the sample usage code (in case u didn&#8217;t notice it in the class comments):</p>
<pre class="brush: as3; ">

import com.chargedweb.utils.CursorFactory;
import mx.core.CursorManager;

CursorFactory.URL = &quot;../assets/skins/icons/my_cursor.png&quot;;
CursorManager.setCursor(CursorFactory);
</pre>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/03/12/flex-cursormanager-vs-jloa/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The new FWA</title>
		<link>http://chargedweb.com/labs/2010/03/01/thefwa/</link>
		<comments>http://chargedweb.com/labs/2010/03/01/thefwa/#comments</comments>
		<pubDate>Tue, 02 Mar 2010 00:38:45 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[misc]]></category>
		<category><![CDATA[news]]></category>
		<category><![CDATA[thoughts]]></category>
		<category><![CDATA[new]]></category>
		<category><![CDATA[thefwa]]></category>
		<category><![CDATA[version]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=297</guid>
		<description><![CDATA[Yes, i was very excited to see the new version of TheFWA&#8217;s website (they planned to release it on march 1st, besides i knew that group94 were doin it). And 2day was the release date actually. And i&#8217;ve just seen it and i should say that i&#8217;m VERY dissapointed with it (not with the dev, [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://cdn.thefwa.com/library/track-83U0.jpg" alt="TheFWA" /><br />
Yes, i was very excited to see the new version of TheFWA&#8217;s website (they planned to release it on march 1st, besides i knew that <a href="http://www.group94.com/">group94</a> were doin it). And 2day was the release date actually. And i&#8217;ve just seen it and i should say that i&#8217;m VERY dissapointed with it (not with the dev, but the concept). Why u&#8217;d ask? Well, i&#8217;ve got an explanation for that. The navigation is not that convinient as it used to, selected work description loads and replaces the whole content now (which&#8217;s damn unhandy), and there&#8217;re PAGE RELOADS now which i HATE. My opinion&#8217;s that TheFWA&#8217;s ruined 4 now.<br />
Pluses: yeah, SEO increased, more ads space. Bravo 1/4.</p>
<p>I liked the previous version <strong>more</strong>. <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' /><br />
Honestly, guys, the previous version was better.</p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/03/01/thefwa/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Adobe + Android = friends</title>
		<link>http://chargedweb.com/labs/2010/02/22/adobe-android-friends/</link>
		<comments>http://chargedweb.com/labs/2010/02/22/adobe-android-friends/#comments</comments>
		<pubDate>Mon, 22 Feb 2010 18:51:35 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[misc]]></category>
		<category><![CDATA[news]]></category>
		<category><![CDATA[air]]></category>
		<category><![CDATA[android]]></category>
		<category><![CDATA[Flash]]></category>
		<category><![CDATA[player]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=276</guid>
		<description><![CDATA[Yes! Adobe officially announced Flash Player 10.1 and Adobe AIR for Android. Kevin Hoyt recorded a great video showing some air apps demos running on Motorola&#8217;s Droid device. Read more at Lee Brimelow&#8217;s blog UPD: Thibault Imbert and Michael tryed out the flash player 10.1 on the Google Nexus One phone. They tested out some [...]]]></description>
			<content:encoded><![CDATA[<p>Yes! Adobe officially announced Flash Player 10.1 and Adobe AIR for Android.<br />
<a href="http://blog.kevinhoyt.org/">Kevin Hoyt</a> recorded a great video showing some air apps demos running on Motorola&#8217;s Droid device.</p>
<p><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="450" height="300" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowFullScreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="FlashVars" value="fileID=5135&amp;context=76&amp;embeded=true&amp;environment=production" /><param name="src" value="http://tv.adobe.com/assets//swf/player.swf" /><param name="flashvars" value="fileID=5135&amp;context=76&amp;embeded=true&amp;environment=production" /><param name="allowfullscreen" value="true" /><embed type="application/x-shockwave-flash" width="450" height="300" src="http://tv.adobe.com/assets//swf/player.swf" flashvars="fileID=5135&amp;context=76&amp;embeded=true&amp;environment=production" allowscriptaccess="always" allowfullscreen="true"></embed></object></p>
<p><a href="http://theflashblog.com/?p=1758">Read more at Lee Brimelow&#8217;s blog</a></p>
<p><strong>UPD:</strong> <a href="http://www.bytearray.org/">Thibault Imbert</a> and <a href="http://codemoiunmouton.wordpress.com/">Michael</a> tryed out the flash player 10.1 on the <a href="http://www.google.com/phone/">Google Nexus One</a> phone. They tested out some flash web sites, games which weren&#8217;t actually optimized for the mobile platform i.e. those r typical web sites from <a href="http://thefwa.com/">the fwa</a>. And the nexus one managed to get that content work nice and smoth.</p>
<p><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="400" height="225" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://vimeo.com/moogaloop.swf?clip_id=9596010&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=&amp;fullscreen=1" /><embed type="application/x-shockwave-flash" width="400" height="225" src="http://vimeo.com/moogaloop.swf?clip_id=9596010&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=&amp;fullscreen=1" allowscriptaccess="always" allowfullscreen="true"></embed></object></p>
<p><a href="http://vimeo.com/9596010">Flash Player 10.1 on Google Nexus One</a> from <a href="http://vimeo.com/user880002">michael chaize</a> on <a href="http://vimeo.com">Vimeo</a>.</p>
<p>ps: don&#8217;t forget that cs5 (which will improve dev for the mobile devices including iphone) is about to release soon <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/02/22/adobe-android-friends/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Skype status icon class</title>
		<link>http://chargedweb.com/labs/2010/02/22/skype-status-icon/</link>
		<comments>http://chargedweb.com/labs/2010/02/22/skype-status-icon/#comments</comments>
		<pubDate>Mon, 22 Feb 2010 17:50:33 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[class]]></category>
		<category><![CDATA[skype]]></category>
		<category><![CDATA[status]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=265</guid>
		<description><![CDATA[Today i had some free time to make a skype status icon class (don&#8217;t know who&#8217;d need that). Anyways, it&#8217;s a simple class that connects to the skype service, retrieves the status code for a specified account name and displays the status icon. All parameters customizable. I&#8217;ve even created a sample page with a php [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://chargedweb.com/labs/files/2010/02/skypestatusicon.png"><img src="http://chargedweb.com/labs/files/2010/02/skypestatusicon.png" alt="" title="skypestatusicon" width="150" height="150" class="alignnone size-full wp-image-266" /></a><br/><br />
Today i had some free time to make a skype status icon class (<del datetime="2010-02-22T17:41:29+00:00">don&#8217;t know who&#8217;d need that</del>).<br />
Anyways, it&#8217;s a simple class that connects to the skype service, retrieves the status code for a specified account name and displays the status icon. All parameters customizable. I&#8217;ve even created a sample page with a php proxy (see the archive)</p>
<p><a href='http://chargedweb.com/labs/files/2010/02/skypestatusicon.zip'>Download SkypeStatusIcon sources</a></p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/02/22/skype-status-icon/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Flex Button icon load failed?</title>
		<link>http://chargedweb.com/labs/2010/02/20/button-load-icon-failed/</link>
		<comments>http://chargedweb.com/labs/2010/02/20/button-load-icon-failed/#comments</comments>
		<pubDate>Sat, 20 Feb 2010 19:44:12 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[flex]]></category>
		<category><![CDATA[icon]]></category>
		<category><![CDATA[load]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=221</guid>
		<description><![CDATA[The only thing why flex sucks is that components can&#8217;t actually load icons (Button class for example) i thought. Yes, but that was until i found Ben Stucki&#8216;s slight solution to this issue. He wrote a nice utility class called IconUtility which creates BitmapAssets at run-time. This class is huge. Sample button icon load up [...]]]></description>
			<content:encoded><![CDATA[<p>The only thing why flex sucks is that components can&#8217;t actually load icons (Button class for example) i thought.</p>
<p>Yes, but that was until i found <a href="http://blog.benstucki.net/">Ben Stucki</a>&#8216;s slight solution to this issue.<br />
He wrote a nice utility class called IconUtility which creates BitmapAssets at run-time. This class is huge.<br />
Sample button icon load up code:</p>
<pre class="brush: as3; ">

var myBtn:Button = new Button();

myBtn.label = &quot;press me&quot;;
myBtn.setStyle(&quot;icon&quot;, IconUtility.getClass(myBtn, &quot;assets/my_icon.png&quot;));
addChild(myBtn);
</pre>
<p><a href="http://blog.benstucki.net/?p=42">IconUtility Component for Dynamic Run-Time Icons</a></p>
<p><a href="http://lab.benstucki.net/archives/IconUtility.zip">Download: IconUtility Class (302 kb)</a></p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/02/20/button-load-icon-failed/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Building air2beta2 apps howto</title>
		<link>http://chargedweb.com/labs/2010/02/20/building-air2beta2-apps-howto/</link>
		<comments>http://chargedweb.com/labs/2010/02/20/building-air2beta2-apps-howto/#comments</comments>
		<pubDate>Sat, 20 Feb 2010 17:37:17 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[air]]></category>
		<category><![CDATA[air2beta2]]></category>
		<category><![CDATA[compile]]></category>
		<category><![CDATA[dmg]]></category>
		<category><![CDATA[exe]]></category>
		<category><![CDATA[rpm]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=197</guid>
		<description><![CDATA[Greetings 2 all. As some of you probably now, adobe has released the air2beta2 at their labs, which brings new ablities like: Enhanced support for interacting with printers (beta 2) Support for TLS/SSL socket communication (beta 2) Support for the detection of mass storage devices. Advanced networking capabilities like secure sockets, UDP support, and the [...]]]></description>
			<content:encoded><![CDATA[<p>Greetings 2 all.</p>
<p>As some of you probably now, adobe has released the air2beta2 at their labs, which brings new ablities like:</p>
<ul>
<li> Enhanced support for interacting with printers (beta 2)</li>
<li>Support for TLS/SSL socket communication (beta 2)</li>
<li>Support for the detection of mass storage devices.</li>
<li>Advanced networking capabilities like secure sockets, UDP support, and the ability to listen on sockets.</li>
<li>Support for native code integration.</li>
<li>The ability to open a file with its default application.</li>
<li>Multi-touch and gesture support.</li>
<li>New APIs for access to raw microphone data.</li>
<li>Webkit update with HTML5/CSS3 support.</li>
<li>Global error handling.</li>
<li>Improved cross-platform printing</li>
<li>Improved security and support for enterprise and government standards.</li>
<li>Native process support</li>
</ul>
<p>I&#8217;ve spend the whole day yesturday playing with the new api and in order that you not waste your time adjusting the sdk&#8217;s, figuring out how to build an exe/dmg file with full sdk support i&#8217;ve decided to post a little tutorial here.</p>
<p><span id="more-197"></span></p>
<p>So, first of all you should start with downloading the air sdk @ <a href="http://labs.adobe.com/downloads/air2.html" target="_blank">http://labs.adobe.com/downloads/air2.html</a> and overlay it for use with Flex SDK.</p>
<p><a href="http://labs.adobe.com/wiki/index.php/AIR_2:Release_Notes#How_to_overlay_the_Adobe_AIR_SDK_for_use_with_the_Flex_SDK" target="_blank">Here</a>&#8216;s a nice instruction on how to overlay the air sdk.</p>
<p>Once you&#8217;ve done that you are ready to start building apps using the new api.</p>
<p>How to create an air2beta2 file:</p>
<p>1. open your application xml file and make sure you&#8217;ve added the extended desktop support:</p>
<pre class="brush: as3; ">
&lt;supportedProfiles&gt;extendedDesktop   desktop&lt;/supportedProfiles&gt;
</pre>
<p><a href="http://chargedweb.com/labs/files/2010/02/app_xml.png"><img class="alignnone size-medium wp-image-200" title="app_xml" src="http://chargedweb.com/labs/files/2010/02/app_xml-300x171.png" alt="" width="300" height="171" /></a></p>
<p>2. compile your application at an AIR file (use the &#8220;<em><strong>export release build</strong></em>&#8221; option for example)</p>
<p><a href="http://chargedweb.com/labs/files/2010/02/props.png"><img class="alignnone size-full wp-image-202" title="props" src="http://chargedweb.com/labs/files/2010/02/props.png" alt="" width="552" height="439" /></a></p>
<p><a href="http://chargedweb.com/labs/files/2010/02/proj_release.png"><img class="alignnone size-full wp-image-201" title="proj_release" src="http://chargedweb.com/labs/files/2010/02/proj_release.png" alt="" width="239" height="197" /></a></p>
<p>3. once you&#8217;ve created an AIR file u just compile it to an exe/dmg/rpm file (that&#8217;s needed for your app to be able to use the new sdk abilities) using the console (well, i did it that way)</p>
<pre class="brush: php; ">
adt  -package -target native exported_file_path your_air_file_path
</pre>
<p>Example (for exe):</p>
<pre class="brush: php; ">
adt -package -target native  C:\AIRSample.exe  C:\dev\air\AIRSample.air
</pre>
<p>Example (for dmg)</p>
<pre class="brush: php; ">
adt  -package -target native  C:\AIRSample.dmg  C:\dev\air\AIRSample.air
</pre>
<p>Example (for rpm)</p>
<pre class="brush: php; ">
adt  -package -target native  C:\AIRSample.rpm  C:\dev\air\AIRSample.air
</pre>
<p><strong>Useful links:</strong></p>
<p><a href="http://labs.adobe.com/wiki/index.php/AIR_2eveloper_FAQ" target="_blank">Developer faq</a><a href="http://labs.adobe.com/wiki/index.php/AIR_2eveloper_FAQ" target="_blank"></a></p>
<p><a href="http://labs.adobe.com/downloads/air2.html" target="_blank">Download air2beta2 sdk</a></p>
<p><a href="http://labs.adobe.com/wiki/index.php/AIR_2:Release_Notes#How_to_overlay_the_Adobe_AIR_SDK_for_use_with_the_Flex_SDK" target="_blank">How to overlay air sdk</a></p>
<p><a href="http://blog.everythingflex.com/2009/11/17/your-first-air-2-0-exe-file/?utm_source=feedburner&amp;utm_medium=feed&amp;utm_campaign=Feed:+Everythingflex+%28EverythingFlex%29" target="_blank">Your first air2 exe file</a></p>
<p>If you&#8217;r on windows, you can use my small app that converts air =&gt; exe/dmg/rpm i.e. it&#8217;s a GUI for the adt for those who don&#8217;t like console usage. I called it AIRPackager.</p>
<p><a href="http://chargedweb.com/labs/2010/02/20/airpackager-easy-air-to-exedmgrpm/" target="_blank">Read more about AIRPackager.</a></p>
<p>Hope 2 help/save yr time.</p>
<p>Nice apps building</p>
<p>Ps: you can also download the source files of my sample PowerOff application that uses the NativeProcess class and use it as a sample air2beta2 app.</p>
<p><a href="http://chargedweb.com/labs/2010/02/20/poweroff-app-testing-air2beta2-api/" target="_blank">Read more about PowerOff app.</a></p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/02/20/building-air2beta2-apps-howto/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Vector.sortOn()?</title>
		<link>http://chargedweb.com/labs/2010/02/20/vector-sorton/</link>
		<comments>http://chargedweb.com/labs/2010/02/20/vector-sorton/#comments</comments>
		<pubDate>Sat, 20 Feb 2010 17:05:09 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[sort]]></category>
		<category><![CDATA[sorton]]></category>
		<category><![CDATA[vector]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=193</guid>
		<description><![CDATA[As you probably know the new fp10 api provides a new Vector class (wonder my didn&#8217;t they just make typed Arrays like in C#) that increases performace about x2 times. But, still among with the performance you could face some difficulties working with Vectors, for example it doesn&#8217;t implement a sortOn() method which, i think [...]]]></description>
			<content:encoded><![CDATA[<p>As you probably know the new fp10 api provides a new Vector class (wonder my didn&#8217;t they just make typed Arrays like in C#) that increases performace about x2 times.<br />
But, still among with the performance you could face some difficulties working with Vectors, for example it doesn&#8217;t implement a sortOn() method which, i think you&#8217;d agree, is very handy.</p>
<p><strong>UPD:</strong> lots of people use very strange/complicated methods to sort vectors.<br />
Guys, stop complicating yr life &#8211; the task is way much easier.</p>
<p>So, here&#8217;s how i do the sortOn() with Vectors:</p>
<pre class="brush: as3; ">

/**
* Converts vector to an array
* @param    v:*        vector to be converted
* @return    Array    converted array
*/
function vectorToArray(v:*):Array
{
var n:int = v.length; var a:Array = new Array();
for(var i:int = 0; i &lt; n; i++) a[i] = v[i];
return a;
}
</pre>
<pre class="brush: as3; ">

/**
* Here&#039;s a little example on how to sort a Vector using sortOn
*/
var v:Vector.&lt;Object&gt; = new Vector.&lt;Object&gt;();
v.push({id:5, email:&quot;andrew@someweb.com&quot;});
v.push({id:35, email:&quot;david@someweb.com&quot;});
v.push({id:12, email:&quot;jill@someweb.com&quot;});

// now to sort the Vector on the &quot;id&quot; property
var vSorted:Vector.&lt;Object&gt; = Vector.&lt;Object&gt;(vectorToArray(v).sortOn(&quot;id&quot;, Array.NUMERIC));
// easy and convinient isn&#039;t it? ^_^
</pre>
<p>Hope might be useful.<br />
Cheers</p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/02/20/vector-sorton/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>My Brute’s coming back</title>
		<link>http://chargedweb.com/labs/2010/02/20/my-brutes-coming-back/</link>
		<comments>http://chargedweb.com/labs/2010/02/20/my-brutes-coming-back/#comments</comments>
		<pubDate>Sat, 20 Feb 2010 15:42:51 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[misc]]></category>
		<category><![CDATA[crouching]]></category>
		<category><![CDATA[Flash]]></category>
		<category><![CDATA[game]]></category>
		<category><![CDATA[hidden]]></category>
		<category><![CDATA[panda]]></category>
		<category><![CDATA[swine]]></category>

		<guid isPermaLink="false">http://chargedweb.com/labs/?p=184</guid>
		<description><![CDATA[Do u guys remember the MyBrute casual flash game? Valentin Simonov recently showed me a sort of modification of MyBrute called Crouching panda hidden swine (wonder who came to that name . Anyways, the game is awesome! Nice graphics, animation, gameplay. It really makes u relax a bit. Totally recommend it. Try it your own. [...]]]></description>
			<content:encoded><![CDATA[<p><img alt="" src="http://profile.ak.fbcdn.net/object2/1239/18/n260822929637_651.jpg" title="crouching panda hidden swine" class="alignnone" width="200" height="91" /></p>
<p>Do u guys remember the <a href="http://mybrute.com/"><strong>MyBrute</strong></a> casual flash game?</p>
<p><a href="http://va.lent.in/blog/">Valentin Simonov</a> recently showed me a sort of modification of MyBrute called <a href="http://apps.facebook.com/hidden_swine/"><strong>Crouching panda hidden swine</strong></a> (wonder who came to that name <img src='http://chargedweb.com/labs/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>
<p>Anyways, the game is awesome! Nice graphics, animation, gameplay.<br />
It really makes u relax a bit. Totally recommend it.<br />
Try it your own.</p>
<p>ps: btw mybrute has just emailed me to &#8220;stay tuned&#8221; omg my account is still there <a href="http://julius-loa.mybrute.com/cellule">http://julius-loa.mybrute.com/cellule</a></p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/02/20/my-brutes-coming-back/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>AirPackager, easy air-to-exe/dmg/rpm [updated]</title>
		<link>http://chargedweb.com/labs/2010/02/20/airpackager-easy-air-to-exedmgrpm/</link>
		<comments>http://chargedweb.com/labs/2010/02/20/airpackager-easy-air-to-exedmgrpm/#comments</comments>
		<pubDate>Sat, 20 Feb 2010 13:11:24 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[app]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[air]]></category>
		<category><![CDATA[air2beta2]]></category>
		<category><![CDATA[airpackager]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[dmg]]></category>
		<category><![CDATA[exe]]></category>
		<category><![CDATA[rpm]]></category>

		<guid isPermaLink="false">http://localhost/blog/wordpress/?p=140</guid>
		<description><![CDATA[UPD: now works with air 2 runtime AirPackager is a small app that will help you generate exe/dmg/rpm files out of your air package in other words &#8211; it&#8217;s just a GUI for the adt. To install the app you need the AIR2 beta2 runtime AIR2 runtime Again, works only on windows. Download AirPackager.exe]]></description>
			<content:encoded><![CDATA[<p><a href="http://chargedweb.com/labs/files/2010/02/airpackager.png"><img class="alignnone size-full wp-image-142" title="airpackager" src="http://chargedweb.com/labs/files/2010/02/airpackager.png" alt="" width="150" height="150" /></a></p>
<p><span style="color: #ff0000;"><u><strong>UPD:</strong></u></span> now works with air 2 runtime
</p>
<p><strong>AirPackager </strong>is a small app that will help you generate exe/dmg/rpm files out of your air package in other words &#8211; it&#8217;s just a GUI for the adt.<br />
To install the app you need the <del>AIR2 beta2 runtime</del> <a href="http://get.adobe.com/air/" target="_blank"><strong>AIR2 runtime</strong></a><br />
Again, works only on windows.</p>
<p><a href="http://chargedweb.com/labs/files/2010/02/airpackager.exe">Download AirPackager.exe</a></p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/02/20/airpackager-easy-air-to-exedmgrpm/feed/</wfw:commentRss>
		<slash:comments>15</slash:comments>
		</item>
		<item>
		<title>PowerOff app – testing air2beta2 api</title>
		<link>http://chargedweb.com/labs/2010/02/20/poweroff-app-testing-air2beta2-api/</link>
		<comments>http://chargedweb.com/labs/2010/02/20/poweroff-app-testing-air2beta2-api/#comments</comments>
		<pubDate>Sat, 20 Feb 2010 13:02:44 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[app]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[air]]></category>
		<category><![CDATA[air2beta2]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[exe]]></category>
		<category><![CDATA[poweroff]]></category>

		<guid isPermaLink="false">http://localhost/blog/wordpress/?p=134</guid>
		<description><![CDATA[UPD: now works with air 2 runtime PowerOff is a simple shutdown timer, which i created just to reveal (test) some of the new features of AIR2 beta2 api.To install the app you need the AIR2 beta2 runtime AIR2 runtimeAnd, btw, it works only on windows. Download PowerOff.exe Download PowerOff source files]]></description>
			<content:encoded><![CDATA[<p><a href="http://chargedweb.com/labs/files/2010/02/poweroff.png"><img src="http://chargedweb.com/labs/files/2010/02/poweroff.png" alt="" title="poweroff" width="150" height="150" class="alignnone size-full wp-image-135" /></a><br/><br />
<span style="color: #ff0000;"><u><strong>UPD:</strong></u></span> now works with air 2 runtime
</p>
<p><strong>PowerOff </strong>is a simple shutdown timer, which i created just to reveal (test) some of the new features of AIR2 beta2 api.<br />To install the app you need the <del>AIR2 beta2 runtime</del> <a href="http://get.adobe.com/air/" target="_blank"><strong>AIR2 runtime</strong></a><br />And, btw, it works only on windows.</p>
<p><a href='http://chargedweb.com/labs/files/2010/02/poweroff.exe'>Download PowerOff.exe</a><br/><br />
<a href='http://chargedweb.com/labs/files/2010/02/poweroff.zip'>Download PowerOff source files</a></p>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/02/20/poweroff-app-testing-air2beta2-api/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>SWFSize lib – working with browser/controlling swf metrics at run-time</title>
		<link>http://chargedweb.com/labs/2010/02/20/swfsize-lib-working-with-browsercontrolling-swf-metrics-at-run-time/</link>
		<comments>http://chargedweb.com/labs/2010/02/20/swfsize-lib-working-with-browsercontrolling-swf-metrics-at-run-time/#comments</comments>
		<pubDate>Sat, 20 Feb 2010 12:59:19 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[js]]></category>
		<category><![CDATA[metrics]]></category>
		<category><![CDATA[scrollbar]]></category>
		<category><![CDATA[swf]]></category>
		<category><![CDATA[swfsize]]></category>

		<guid isPermaLink="false">http://localhost/blog/wordpress/?p=131</guid>
		<description><![CDATA[SWFSize is a simple, lightweight library to control the swf&#8217;s container metrics &#038; use the browser&#8217;s native scrollbars. Project page http://chargedweb.com/swfsize/. UPD: version updated to 1.1 UPD: version updated to 1.2 UPD: version updated to 1.3 UPD: version updated to 1.4.0 UPD: version updated to 1.4.1]]></description>
			<content:encoded><![CDATA[<p><img alt="" src="http://chargedweb.com/swfsize/i/ico_swfsize_logo.png" title="SWFsize / as3 + js lib / control swf&#039;s metrics / use browser&#039;s native scrollbars / solve mac mouse wheel issue" width="220" height="60" /><br/><br/></p>
<p><strong>SWFSize </strong>is a simple, lightweight library to control the swf&#8217;s container metrics &#038; use the browser&#8217;s native scrollbars.<br />
Project page <a href="http://chargedweb.com/swfsize/">http://chargedweb.com/swfsize/</a></b>.</p>
<p><strong>UPD:</strong> version updated to 1.1<br />
<strong>UPD:</strong> version updated to 1.2<br />
<strong>UPD:</strong> version updated to 1.3<br />
<strong>UPD:</strong> version updated to 1.4.0<br />
<strong>UPD:</strong> version updated to 1.4.1<br />
<br/><br />
<a href="http://chargedweb.com/labs/files/2010/02/swfsize_qr.png"><img src="http://chargedweb.com/labs/files/2010/02/swfsize_qr.png" alt="" title="swfsize lib" width="155" height="155" /></a></p>
 <p><a href="http://chargedweb.com/labs/?flattrss_redirect&amp;id=131&amp;md5=843b3c4516db7572dd97ed2eb439ae08" title="Flattr" target="_blank"><img src="http://chargedweb.com/labs/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/02/20/swfsize-lib-working-with-browsercontrolling-swf-metrics-at-run-time/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>A proper as3 captcha validator</title>
		<link>http://chargedweb.com/labs/2010/02/20/a-proper-as3-captcha-validator/</link>
		<comments>http://chargedweb.com/labs/2010/02/20/a-proper-as3-captcha-validator/#comments</comments>
		<pubDate>Sat, 20 Feb 2010 12:53:10 +0000</pubDate>
		<dc:creator>jloa</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[as3]]></category>
		<category><![CDATA[captcha]]></category>
		<category><![CDATA[class]]></category>
		<category><![CDATA[validator]]></category>

		<guid isPermaLink="false">http://localhost/blog/wordpress/?p=125</guid>
		<description><![CDATA[Some time ago i was surfing the net and i noticed that flash captchas are very popular on such components stores like flashden etc, but just few of them are actually made properly and can prevent spammers from doing their magic ^_^. So, i&#8217;ve decided to write a little sample catcha validator class for those [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://chargedweb.com/labs/files/2010/02/captcha.png"><img class="alignnone size-full wp-image-129" title="captcha" src="http://chargedweb.com/labs/files/2010/02/captcha.png" alt="" width="150" height="150" /></a></p>
<p>Some time ago i was surfing the net and i noticed that flash captchas are very popular on such components stores like flashden etc, but just few of them are actually made properly and can prevent spammers from doing their magic ^_^.</p>
<p>So, i&#8217;ve decided to write a little sample catcha validator class for those of u that need or would need one.</p>
<p><span id="more-125"></span></p>
<p>Demo available <a href="http://chargedweb.com/labs/files/CaptchaValidator.swf" target="_blank">here</a></p>
<p><a href="http://chargedweb.com/labs/files/2010/02/captcha.zip">Download source files</a></p>
<p><strong>How to use CaptchaValidator (flash sample):</strong></p>
<pre class="brush: as3; ">

import fl.controls.Button;
import flash.display.Loader;
import flash.display.SimpleButton;
import flash.text.TextField;
import flash.text.TextFormat;
import flash.events.MouseEvent;
import com.chargedweb.net.CaptchaValidator;
import com.chargedweb.events.CaptchaValidatorEvent;

var tFo:TextFormat = new TextFormat(&quot;Verdana&quot;, 10);
var capVal:CaptchaValidator = new CaptchaValidator();
capVal.addEventListener(CaptchaValidatorEvent.SUCCESS, onCaptchaSuccess);
capVal.addEventListener(CaptchaValidatorEvent.ERROR_VARS, onErrorVars);
capVal.addEventListener(CaptchaValidatorEvent.ERROR_CAPTCHA, onErrorCaptcha);

var titleTF:TextField = new TextField();
titleTF.multiline = false;
titleTF.autoSize = &quot;left&quot;;
titleTF.text = &quot;Try to input the captcha code and click the send button | Click on the image to reload the captcha&quot;;
titleTF.x = titleTF.y = 10;
titleTF.setTextFormat(tFo);
addChild(titleTF);

var inputTF:TextField = new TextField();
inputTF.multiline = false;
inputTF.type = &quot;input&quot;;
inputTF.width = 100;
inputTF.height = 20;
inputTF.border = true;
inputTF.defaultTextFormat = tFo;
inputTF.setTextFormat(tFo);
inputTF.x = titleTF.x;
inputTF.y = titleTF.y + int(titleTF.height + 5);
addChild(inputTF);

var statusTF:TextField = new TextField();
statusTF.multiline = true;
statusTF.text = &quot;Server results go here&quot;;
statusTF.width = 200;
statusTF.height = 100;
statusTF.border = true;
statusTF.setTextFormat(tFo);
statusTF.x = stage.stageWidth - statusTF.width;
statusTF.y = stage.stageHeight - statusTF.height;
addChild(statusTF);

var captchaLdr:Loader = new Loader();
captchaLdr.addEventListener(MouseEvent.CLICK, captchaLdrClick);
captchaLdr.x = inputTF.x;
captchaLdr.y = inputTF.y + int(inputTF.height + 5);
addChild(captchaLdr);

var sendBtn:Button = new Button();
sendBtn.addEventListener(MouseEvent.CLICK, sendBtnClick);
sendBtn.setStyle(&quot;textFormat&quot;, tFo);
sendBtn.label = &quot;verify captcha&quot;;
sendBtn.x = inputTF.x + int(inputTF.width + 5);
sendBtn.y = inputTF.y;
sendBtn.width = 150;
sendBtn.height = inputTF.height;
addChild(sendBtn);

loadCaptchaImage();

function loadCaptchaImage():void
{
captchaLdr.load(new URLRequest(&quot;base/captcha.php&quot;));
}

function captchaLdrClick(event:MouseEvent):void
{
loadCaptchaImage();
}

function sendBtnClick(event:MouseEvent):void
{
capVal.captcha = inputTF.text;
capVal.load();
}

function onCaptchaSuccess(event:CaptchaValidatorEvent):void
{
statusTF.appendText(&quot;\nOk, captcha verivied&quot;);
}

function onErrorVars(event:CaptchaValidatorEvent):void
{
statusTF.appendText(&quot;\n#error: Captcha variable not set/wrong send method&quot;);
}

function onErrorCaptcha(event:CaptchaValidatorEvent):void
{
statusTF.appendText(&quot;\n#error: Wrong captcha code&quot;);
}
</pre>
]]></content:encoded>
			<wfw:commentRss>http://chargedweb.com/labs/2010/02/20/a-proper-as3-captcha-validator/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
		</item>
	</channel>
</rss>

