<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Don&#8217;t use width or height properties of Loader with AVM Captivate SWFs</title>
	<atom:link href="http://elearninglive.com/wordpress/2009/01/dont-use-width-or-heigh-properties-of-loader-with-avm-captivate-swfs/feed/" rel="self" type="application/rss+xml" />
	<link>http://elearninglive.com/wordpress/2009/01/dont-use-width-or-heigh-properties-of-loader-with-avm-captivate-swfs/</link>
	<description>Quality web solutions.</description>
	<lastBuildDate>Thu, 15 Jul 2010 03:12:30 -0700</lastBuildDate>
	
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: ji</title>
		<link>http://elearninglive.com/wordpress/2009/01/dont-use-width-or-heigh-properties-of-loader-with-avm-captivate-swfs/comment-page-1/#comment-1307</link>
		<dc:creator>ji</dc:creator>
		<pubDate>Wed, 01 Jul 2009 07:27:54 +0000</pubDate>
		<guid isPermaLink="false">http://elearninglive.com/wordpress/?p=215#comment-1307</guid>
		<description>After search a lot, I found the reason. 
There are two ways to deal with such problem.
1:  set the scaleX/Y property of the Loader.
2: We all do wrong using about the &quot;Loader&quot; Object to directly set the height and width of it.
You can not set the hight and width before the loading process finishing.

import flash.display.Loader;
import flash.net.URLLoader;
import flash.events.*;
var _loader:Loader=new Loader();
_loader.contentLoaderInfo.addEventListener(Event.COMPLETE,onLoadingComplete);
_loader.load(new URLRequest(&quot;http://www.thesquashracket.com/wallpapers/nature/165858ducks.jpg&quot;));
addChild(_loader);
function onLoadingComplete(evt:Event) {
trace([&quot;before resize&quot;,evt.target.content.height,evt.target.content.width]);
evt.target.content.height=100;
evt.target.content.width=100;
trace([&quot;After resize&quot;,evt.target.content.height,evt.target.content.width]);
}

reference: http://www.actionscript.org/forums/archive/index.php3/t-150974.html</description>
		<content:encoded><![CDATA[<p>After search a lot, I found the reason.<br />
There are two ways to deal with such problem.<br />
1:  set the scaleX/Y property of the Loader.<br />
2: We all do wrong using about the &#8220;Loader&#8221; Object to directly set the height and width of it.<br />
You can not set the hight and width before the loading process finishing.</p>
<p>import flash.display.Loader;<br />
import flash.net.URLLoader;<br />
import flash.events.*;<br />
var _loader:Loader=new Loader();<br />
_loader.contentLoaderInfo.addEventListener(Event.COMPLETE,onLoadingComplete);<br />
_loader.load(new URLRequest(&#8221;http://www.thesquashracket.com/wallpapers/nature/165858ducks.jpg&#8221;));<br />
addChild(_loader);<br />
function onLoadingComplete(evt:Event) {<br />
trace(["before resize",evt.target.content.height,evt.target.content.width]);<br />
evt.target.content.height=100;<br />
evt.target.content.width=100;<br />
trace(["After resize",evt.target.content.height,evt.target.content.width]);<br />
}</p>
<p>reference: <a href="http://www.actionscript.org/forums/archive/index.php3/t-150974.html" rel="nofollow">http://www.actionscript.org/forums/archive/index.php3/t-150974.html</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: ji</title>
		<link>http://elearninglive.com/wordpress/2009/01/dont-use-width-or-heigh-properties-of-loader-with-avm-captivate-swfs/comment-page-1/#comment-1306</link>
		<dc:creator>ji</dc:creator>
		<pubDate>Wed, 01 Jul 2009 06:52:07 +0000</pubDate>
		<guid isPermaLink="false">http://elearninglive.com/wordpress/?p=215#comment-1306</guid>
		<description>I also meet such a problem .... in Flash AVM3</description>
		<content:encoded><![CDATA[<p>I also meet such a problem &#8230;. in Flash AVM3</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: RaiulBaztepo</title>
		<link>http://elearninglive.com/wordpress/2009/01/dont-use-width-or-heigh-properties-of-loader-with-avm-captivate-swfs/comment-page-1/#comment-1175</link>
		<dc:creator>RaiulBaztepo</dc:creator>
		<pubDate>Sat, 28 Mar 2009 22:42:21 +0000</pubDate>
		<guid isPermaLink="false">http://elearninglive.com/wordpress/?p=215#comment-1175</guid>
		<description>Hello!
Very Interesting post! Thank you for such interesting resource! 
PS: Sorry for my bad english, I&#039;v just started to learn this language ;)
See you! 
Your, Raiul Baztepo</description>
		<content:encoded><![CDATA[<p>Hello!<br />
Very Interesting post! Thank you for such interesting resource!<br />
PS: Sorry for my bad english, I&#8217;v just started to learn this language <img src='http://elearninglive.com/wordpress/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /><br />
See you!<br />
Your, Raiul Baztepo</p>
]]></content:encoded>
	</item>
</channel>
</rss>
