<?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: Two Examples of Layout Animations</title>
	<atom:link href="http://evtimmy.com/2010/04/two-examples-of-layout-animations/feed/" rel="self" type="application/rss+xml" />
	<link>http://evtimmy.com/2010/04/two-examples-of-layout-animations/</link>
	<description>Evtim on Flex SDK</description>
	<lastBuildDate>Thu, 17 Nov 2011 17:57:25 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
	<item>
		<title>By: Tim</title>
		<link>http://evtimmy.com/2010/04/two-examples-of-layout-animations/comment-page-1/#comment-11675</link>
		<dc:creator>Tim</dc:creator>
		<pubDate>Thu, 17 Nov 2011 17:57:25 +0000</pubDate>
		<guid isPermaLink="false">http://evtimmy.com/?p=318#comment-11675</guid>
		<description>p.s. When I said descendant, I meant subclass.</description>
		<content:encoded><![CDATA[<p>p.s. When I said descendant, I meant subclass.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tim</title>
		<link>http://evtimmy.com/2010/04/two-examples-of-layout-animations/comment-page-1/#comment-11674</link>
		<dc:creator>Tim</dc:creator>
		<pubDate>Thu, 17 Nov 2011 17:55:01 +0000</pubDate>
		<guid isPermaLink="false">http://evtimmy.com/?p=318#comment-11674</guid>
		<description>Hi Evtim,

Is there a simple way that a layout can determine whether its target is a ListBase (or descendant) so that it can automatically deal with selection?

Thanks,
Tim</description>
		<content:encoded><![CDATA[<p>Hi Evtim,</p>
<p>Is there a simple way that a layout can determine whether its target is a ListBase (or descendant) so that it can automatically deal with selection?</p>
<p>Thanks,<br />
Tim</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Yang</title>
		<link>http://evtimmy.com/2010/04/two-examples-of-layout-animations/comment-page-1/#comment-11671</link>
		<dc:creator>Yang</dc:creator>
		<pubDate>Thu, 17 Nov 2011 04:23:21 +0000</pubDate>
		<guid isPermaLink="false">http://evtimmy.com/?p=318#comment-11671</guid>
		<description>Hi Evtim,
Thanks for sharing so much cool tips about layouts.
Are there any scenarios where positioning elements in the component class is appropriate?
For example in a tab bar component I created, I allow the user to click and drag the tab bar buttons to reorder the tabs (like Chrome). Therefore the positions of the tabs depend on user interaction (drag and drop) which should be the responsibility of the component class. Now if I were to move the positioning code to the layout class, I would need to either reference the layout class directly from the component class or use events to tell the layout class the desired position of an element (based on mouseX) and when to change the positions. Your thoughts?

Regards,
Yang</description>
		<content:encoded><![CDATA[<p>Hi Evtim,<br />
Thanks for sharing so much cool tips about layouts.<br />
Are there any scenarios where positioning elements in the component class is appropriate?<br />
For example in a tab bar component I created, I allow the user to click and drag the tab bar buttons to reorder the tabs (like Chrome). Therefore the positions of the tabs depend on user interaction (drag and drop) which should be the responsibility of the component class. Now if I were to move the positioning code to the layout class, I would need to either reference the layout class directly from the component class or use events to tell the layout class the desired position of an element (based on mouseX) and when to change the positions. Your thoughts?</p>
<p>Regards,<br />
Yang</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tim</title>
		<link>http://evtimmy.com/2010/04/two-examples-of-layout-animations/comment-page-1/#comment-11633</link>
		<dc:creator>Tim</dc:creator>
		<pubDate>Tue, 16 Aug 2011 11:16:30 +0000</pubDate>
		<guid isPermaLink="false">http://evtimmy.com/?p=318#comment-11633</guid>
		<description>Thanks again Evtim - this is all solid gold advice!
&lt;a href=&quot;#comment-11630&quot; rel=&quot;nofollow&quot;&gt;@Evtim &lt;/a&gt;</description>
		<content:encoded><![CDATA[<p>Thanks again Evtim &#8211; this is all solid gold advice!<br />
<a href="#comment-11630" rel="nofollow">@Evtim </a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Evtim</title>
		<link>http://evtimmy.com/2010/04/two-examples-of-layout-animations/comment-page-1/#comment-11630</link>
		<dc:creator>Evtim</dc:creator>
		<pubDate>Wed, 10 Aug 2011 05:41:19 +0000</pubDate>
		<guid isPermaLink="false">http://evtimmy.com/?p=318#comment-11630</guid>
		<description>Hi Tim,

This is a very good question!  With custom layouts (or even custom layout code withing components), usually the most common pitfall is to cause unnecessary invalidations.  For example a simple 2D layout should use setLayoutBoundsPosition() instead of setting the x/y properties.  Setting x/y will actually invalidate properties, size and display list which will cause the layout to run again - inefficient (and sometimes could even lead to infinite loops).  The same rule applies to 3D layouts - don&#039;t set properties like x, y, z, rotationX, rotationY, transform, transform.matrix3D, etc. from within the layout&#039;s updateDisplayList() method.  Instead, the ILayoutElement interface should be used.  For the 3D case in particular, there are two equally correct choices - ILayoutElement::setLayoutMatrix3D() and ILayoutElement::transformAround().  Just make sure you&#039;re passing &quot;false&quot; to the &quot;invalidateLayout&quot; parameter.

Cheers,
Evtim</description>
		<content:encoded><![CDATA[<p>Hi Tim,</p>
<p>This is a very good question!  With custom layouts (or even custom layout code withing components), usually the most common pitfall is to cause unnecessary invalidations.  For example a simple 2D layout should use setLayoutBoundsPosition() instead of setting the x/y properties.  Setting x/y will actually invalidate properties, size and display list which will cause the layout to run again &#8211; inefficient (and sometimes could even lead to infinite loops).  The same rule applies to 3D layouts &#8211; don&#8217;t set properties like x, y, z, rotationX, rotationY, transform, transform.matrix3D, etc. from within the layout&#8217;s updateDisplayList() method.  Instead, the ILayoutElement interface should be used.  For the 3D case in particular, there are two equally correct choices &#8211; ILayoutElement::setLayoutMatrix3D() and ILayoutElement::transformAround().  Just make sure you&#8217;re passing &#8220;false&#8221; to the &#8220;invalidateLayout&#8221; parameter.</p>
<p>Cheers,<br />
Evtim</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tim</title>
		<link>http://evtimmy.com/2010/04/two-examples-of-layout-animations/comment-page-1/#comment-11629</link>
		<dc:creator>Tim</dc:creator>
		<pubDate>Tue, 09 Aug 2011 17:45:35 +0000</pubDate>
		<guid isPermaLink="false">http://evtimmy.com/?p=318#comment-11629</guid>
		<description>Hi Evtim,

Thank you for posting these examples and the presentation you gave on custom Spark layouts. They&#039;ve been invaluable in helping me understand the concepts involved.

There are many different ways that examples are laying out their elements in 3D space. I noticed you&#039;re using setLayoutMatrix3D(). Would you consider this the best/correct way to do so in a custom layout?

Thanks,

Tim</description>
		<content:encoded><![CDATA[<p>Hi Evtim,</p>
<p>Thank you for posting these examples and the presentation you gave on custom Spark layouts. They&#8217;ve been invaluable in helping me understand the concepts involved.</p>
<p>There are many different ways that examples are laying out their elements in 3D space. I noticed you&#8217;re using setLayoutMatrix3D(). Would you consider this the best/correct way to do so in a custom layout?</p>
<p>Thanks,</p>
<p>Tim</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Evtim</title>
		<link>http://evtimmy.com/2010/04/two-examples-of-layout-animations/comment-page-1/#comment-11615</link>
		<dc:creator>Evtim</dc:creator>
		<pubDate>Wed, 20 Apr 2011 03:04:15 +0000</pubDate>
		<guid isPermaLink="false">http://evtimmy.com/?p=318#comment-11615</guid>
		<description>@Philo
Hi Philo,
If you want to load images from disk, take a look at FlickrThumbnail.mxml - this is the Item Renderer source. You see the image is being loaded by the mx:Image component, through its source property like this &quot;source=&quot;{data.thumbnail.url}&quot;&quot;. Modify that line to something like &quot;data.imagePath&quot; and then modify your dataProvider to be an ArrayCollection of Objects, one Object per image, and each Object having a property &quot;imagePath&quot; of type String that is set to the path to the image.  Hope that helps.</description>
		<content:encoded><![CDATA[<p>@Philo<br />
Hi Philo,<br />
If you want to load images from disk, take a look at FlickrThumbnail.mxml &#8211; this is the Item Renderer source. You see the image is being loaded by the mx:Image component, through its source property like this &#8220;source=&#8221;{data.thumbnail.url}&#8221;". Modify that line to something like &#8220;data.imagePath&#8221; and then modify your dataProvider to be an ArrayCollection of Objects, one Object per image, and each Object having a property &#8220;imagePath&#8221; of type String that is set to the path to the image.  Hope that helps.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Evtim</title>
		<link>http://evtimmy.com/2010/04/two-examples-of-layout-animations/comment-page-1/#comment-11613</link>
		<dc:creator>Evtim</dc:creator>
		<pubDate>Wed, 20 Apr 2011 02:49:21 +0000</pubDate>
		<guid isPermaLink="false">http://evtimmy.com/?p=318#comment-11613</guid>
		<description>@Bruno
Hi Bruno,
I&#039;m not exactly sure what you mean by &quot;in the middle&quot;, but I think it should be possible.  I imagine that you can add additional property on the WheelLayout - like index of the item to be specially treated. Then in updateDisplayList() you&#039;ll layout that item in the special way you describe. From your application you&#039;ll set/update that property on the WheelLayout and the layout would need to invalidate and re-layout - take a look at how the rest of the WheelLayout properties do the invalidations.</description>
		<content:encoded><![CDATA[<p>@Bruno<br />
Hi Bruno,<br />
I&#8217;m not exactly sure what you mean by &#8220;in the middle&#8221;, but I think it should be possible.  I imagine that you can add additional property on the WheelLayout &#8211; like index of the item to be specially treated. Then in updateDisplayList() you&#8217;ll layout that item in the special way you describe. From your application you&#8217;ll set/update that property on the WheelLayout and the layout would need to invalidate and re-layout &#8211; take a look at how the rest of the WheelLayout properties do the invalidations.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Evtim</title>
		<link>http://evtimmy.com/2010/04/two-examples-of-layout-animations/comment-page-1/#comment-11611</link>
		<dc:creator>Evtim</dc:creator>
		<pubDate>Wed, 20 Apr 2011 02:42:19 +0000</pubDate>
		<guid isPermaLink="false">http://evtimmy.com/?p=318#comment-11611</guid>
		<description>@Bula
Hi Bula, sorry took so long to reply.  I think this might be a bug in DataGroup&#039;s updateDisplayList(), I just gave it a quick look and I see that we don&#039;t check the &quot;autoLayout&quot; flag in there... If that&#039;s the problem indeed, we should get this logged - https://bugs.adobe.com/flex/
A work-around would be to subclass DataGroup, override updateDisplayList() and if &quot;autoLayout&quot; is false, return, else call the super.updateDisplayList().</description>
		<content:encoded><![CDATA[<p>@Bula<br />
Hi Bula, sorry took so long to reply.  I think this might be a bug in DataGroup&#8217;s updateDisplayList(), I just gave it a quick look and I see that we don&#8217;t check the &#8220;autoLayout&#8221; flag in there&#8230; If that&#8217;s the problem indeed, we should get this logged &#8211; <a href="https://bugs.adobe.com/flex/" rel="nofollow">https://bugs.adobe.com/flex/</a><br />
A work-around would be to subclass DataGroup, override updateDisplayList() and if &#8220;autoLayout&#8221; is false, return, else call the super.updateDisplayList().</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bruno</title>
		<link>http://evtimmy.com/2010/04/two-examples-of-layout-animations/comment-page-1/#comment-11607</link>
		<dc:creator>Bruno</dc:creator>
		<pubDate>Thu, 20 Jan 2011 12:14:54 +0000</pubDate>
		<guid isPermaLink="false">http://evtimmy.com/?p=318#comment-11607</guid>
		<description>more one thing, the image can be on two positions, at the middle when viewing the imagens on a 2D perpective by rotating the axis to the depth plane. OR above the others when viewing the images on 3D with the axis on a Vertical plane ...

Thanks,

Bruno</description>
		<content:encoded><![CDATA[<p>more one thing, the image can be on two positions, at the middle when viewing the imagens on a 2D perpective by rotating the axis to the depth plane. OR above the others when viewing the images on 3D with the axis on a Vertical plane &#8230;</p>
<p>Thanks,</p>
<p>Bruno</p>
]]></content:encoded>
	</item>
</channel>
</rss>

