<?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: Displaying icons in a Flex List control</title>
	<atom:link href="http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/</link>
	<description>Just a bunch of Adobe Flex Examples</description>
	<lastBuildDate>Fri, 19 Mar 2010 20:35:16 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Anton</title>
		<link>http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/comment-page-1/#comment-652</link>
		<dc:creator>Anton</dc:creator>
		<pubDate>Thu, 04 Jun 2009 13:39:46 +0000</pubDate>
		<guid isPermaLink="false">http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/#comment-652</guid>
		<description>thanks for this example.

does the list_iconFunc have to return a class? I would like to have a function that draws and returns a sprite.  I have tried to convert a sprite to a class - but cant find how to do that, and it seems a little ineffecient to do that.</description>
		<content:encoded><![CDATA[<p>thanks for this example.</p>
<p>does the list_iconFunc have to return a class? I would like to have a function that draws and returns a sprite.  I have tried to convert a sprite to a class &#8211; but cant find how to do that, and it seems a little ineffecient to do that.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Resh</title>
		<link>http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/comment-page-1/#comment-653</link>
		<dc:creator>Resh</dc:creator>
		<pubDate>Mon, 18 May 2009 22:12:52 +0000</pubDate>
		<guid isPermaLink="false">http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/#comment-653</guid>
		<description>Found the answer for my own question: In case anyone wants-
You can change the looks by overriding set Data method of the itemRenderer:
 override public function set data(value:Object):void {

if (value.type is A1)
  set A1&#039;s image
if( value.type is A2)
 set A2&#039;s image
}</description>
		<content:encoded><![CDATA[<p>Found the answer for my own question: In case anyone wants-<br />
You can change the looks by overriding set Data method of the itemRenderer:<br />
 override public function set data(value:Object):void {</p>
<p>if (value.type is A1)<br />
  set A1&#8217;s image<br />
if( value.type is A2)<br />
 set A2&#8217;s image<br />
}</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Resh</title>
		<link>http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/comment-page-1/#comment-657</link>
		<dc:creator>Resh</dc:creator>
		<pubDate>Tue, 12 May 2009 21:39:25 +0000</pubDate>
		<guid isPermaLink="false">http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/#comment-657</guid>
		<description>Hi,

Any ideas about how I would have a different itemrenderer for only the first item in the list and the rest of the items follow a 2nd itemrenderer? Right now I only found a way to set the itemrender to the whole List.

Thanks for all the great samples!</description>
		<content:encoded><![CDATA[<p>Hi,</p>
<p>Any ideas about how I would have a different itemrenderer for only the first item in the list and the rest of the items follow a 2nd itemrenderer? Right now I only found a way to set the itemrender to the whole List.</p>
<p>Thanks for all the great samples!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Adam</title>
		<link>http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/comment-page-1/#comment-656</link>
		<dc:creator>Adam</dc:creator>
		<pubDate>Thu, 04 Sep 2008 20:50:41 +0000</pubDate>
		<guid isPermaLink="false">http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/#comment-656</guid>
		<description>I have this working perfectly... but how do I change the width and height if the icons need to be resized?

--Great tutorials, Google always seems to guide me to this blog.</description>
		<content:encoded><![CDATA[<p>I have this working perfectly&#8230; but how do I change the width and height if the icons need to be resized?</p>
<p>&#8211;Great tutorials, Google always seems to guide me to this blog.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: scsfdev</title>
		<link>http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/comment-page-1/#comment-655</link>
		<dc:creator>scsfdev</dc:creator>
		<pubDate>Sun, 10 Aug 2008 13:39:33 +0000</pubDate>
		<guid isPermaLink="false">http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/#comment-655</guid>
		<description>Hello guys..

i&#039;m new to RIA, Flex.
Currently i&#039;m using Flex 3.
I have some difficulty in my work.
I want to add icon to Advanced Datagrid control.
I just don&#039;t know how to add it. (I found this sample which added icons to List)
but in ADG, it has not such icon or iconFunction.

So, do u have any idea of how can i add icons to ADG?

(P.S: I want to add icons in other columns except first, tree column)

If u guys can help me, pls guide me.
Thanks</description>
		<content:encoded><![CDATA[<p>Hello guys..</p>
<p>i&#8217;m new to RIA, Flex.<br />
Currently i&#8217;m using Flex 3.<br />
I have some difficulty in my work.<br />
I want to add icon to Advanced Datagrid control.<br />
I just don&#8217;t know how to add it. (I found this sample which added icons to List)<br />
but in ADG, it has not such icon or iconFunction.</p>
<p>So, do u have any idea of how can i add icons to ADG?</p>
<p>(P.S: I want to add icons in other columns except first, tree column)</p>
<p>If u guys can help me, pls guide me.<br />
Thanks</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Vijay</title>
		<link>http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/comment-page-1/#comment-651</link>
		<dc:creator>Vijay</dc:creator>
		<pubDate>Sun, 27 Jul 2008 22:02:28 +0000</pubDate>
		<guid isPermaLink="false">http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/#comment-651</guid>
		<description>Figured out the answer to my question. You dont need to extend ListItemRenderer. The default one is good enough.
The currentTarget property of the ListEvent.Click (Not ListEvent.ItemClick) will tell you whether you clicked on the icon (if it exists) or the textfield.</description>
		<content:encoded><![CDATA[<p>Figured out the answer to my question. You dont need to extend ListItemRenderer. The default one is good enough.<br />
The currentTarget property of the ListEvent.Click (Not ListEvent.ItemClick) will tell you whether you clicked on the icon (if it exists) or the textfield.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Vijay</title>
		<link>http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/comment-page-1/#comment-654</link>
		<dc:creator>Vijay</dc:creator>
		<pubDate>Wed, 23 Jul 2008 04:26:46 +0000</pubDate>
		<guid isPermaLink="false">http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/#comment-654</guid>
		<description>The default ListItemRender is defined as icon:IFlexDisplayObject and labelText:IUITextField

Now,how do you  make the icon(image) clickable?
Not the whole ListItem just the icon only.


http://www.mail-archive.com/flexcoders@yahoogroups.com/msg99162.html

Am i missing anything because the myClickHandler is not getting invoked.
&lt;pre class=&quot;code&quot;&gt;
public class MyListItemRenderer extends ListItemRenderer {

private function myClickHandler(e:MouseEvent):void{
               trace(&#039;myClickHandler invoked&#039;);
 }

override protected function commitProperties():void{
         super.commitProperties();
         if(icon){
              trace(&#039;icon is NOT null&#039;);
               icon.addEventListener(MouseEvent.CLICK,myClickHandler);

         } else {
              trace(&#039; icon is null&#039;);
         }
}
}
&lt;/pre&gt;</description>
		<content:encoded><![CDATA[<p>The default ListItemRender is defined as icon:IFlexDisplayObject and labelText:IUITextField</p>
<p>Now,how do you  make the icon(image) clickable?<br />
Not the whole ListItem just the icon only.</p>
<p><a href="http://www.mail-archive.com/flexcoders@yahoogroups.com/msg99162.html" rel="nofollow">http://www.mail-archive.com/flexcoders@yahoogroups.com/msg99162.html</a></p>
<p>Am i missing anything because the myClickHandler is not getting invoked.</p>
<pre class="code">
public class MyListItemRenderer extends ListItemRenderer {

private function myClickHandler(e:MouseEvent):void{
               trace('myClickHandler invoked');
 }

override protected function commitProperties():void{
         super.commitProperties();
         if(icon){
              trace('icon is NOT null');
               icon.addEventListener(MouseEvent.CLICK,myClickHandler);

         } else {
              trace(' icon is null');
         }
}
}
</pre>
]]></content:encoded>
	</item>
	<item>
		<title>By: Alex</title>
		<link>http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/comment-page-1/#comment-649</link>
		<dc:creator>Alex</dc:creator>
		<pubDate>Wed, 22 Aug 2007 18:13:44 +0000</pubDate>
		<guid isPermaLink="false">http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/#comment-649</guid>
		<description>I&#039;d like to do this with a datagrid... has anyone done it?  I&#039;m trying it now with no luck.

Alex</description>
		<content:encoded><![CDATA[<p>I&#8217;d like to do this with a datagrid&#8230; has anyone done it?  I&#8217;m trying it now with no luck.</p>
<p>Alex</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: peterd</title>
		<link>http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/comment-page-1/#comment-650</link>
		<dc:creator>peterd</dc:creator>
		<pubDate>Wed, 22 Aug 2007 14:33:10 +0000</pubDate>
		<guid isPermaLink="false">http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/#comment-650</guid>
		<description>Sher Ali,

I believe the skin property was added in Flex 3. See the documentation for the Flex 2.0.1 &lt;a href=&quot;http://livedocs.adobe.com/flex/201/langref/mx/controls/Button.html#styleSummary&quot; rel=&quot;nofollow&quot;&gt;Button control on LiveDocs&lt;/a&gt; for more information.

I created all these samples using the Flex 3 beta and apparently didn&#039;t test in earlier versions (as I&#039;m sure you noticed by now). ;)

I&#039;d imagine you could just set each of the skin styles individually to do the same thing. In that case, I&#039;m sure it would be easier to set the styles in an &lt;nobr&gt;&lt;mx:Style /&amp;gt&lt;/nobr&gt; block on the Button class, or create a new custom style and use the &lt;code&gt;styleName&lt;/code&gt; property.

Peter</description>
		<content:encoded><![CDATA[<p>Sher Ali,</p>
<p>I believe the skin property was added in Flex 3. See the documentation for the Flex 2.0.1 <a href="http://livedocs.adobe.com/flex/201/langref/mx/controls/Button.html#styleSummary" rel="nofollow">Button control on LiveDocs</a> for more information.</p>
<p>I created all these samples using the Flex 3 beta and apparently didn&#8217;t test in earlier versions (as I&#8217;m sure you noticed by now). ;)</p>
<p>I&#8217;d imagine you could just set each of the skin styles individually to do the same thing. In that case, I&#8217;m sure it would be easier to set the styles in an <nobr>&lt;mx:Style /&#038;gt</nobr> block on the Button class, or create a new custom style and use the <code>styleName</code> property.</p>
<p>Peter</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sher Ali</title>
		<link>http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/comment-page-1/#comment-648</link>
		<dc:creator>Sher Ali</dc:creator>
		<pubDate>Wed, 22 Aug 2007 11:38:30 +0000</pubDate>
		<guid isPermaLink="false">http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/#comment-648</guid>
		<description>Thanks for small and quick learning tips.

I have a question regarding the skin property for the Button component.

Is the skin property for the Button component available in Flex 2 or it has been added in Flex 3?

Because when I use skin property in Flex 2 it doesn&#039;t recognize it and gives the following compile time error:

Cannot resolve attribute &#039;skin&#039; for component type mx.controls.Button.


Regards,
S.Ali</description>
		<content:encoded><![CDATA[<p>Thanks for small and quick learning tips.</p>
<p>I have a question regarding the skin property for the Button component.</p>
<p>Is the skin property for the Button component available in Flex 2 or it has been added in Flex 3?</p>
<p>Because when I use skin property in Flex 2 it doesn&#8217;t recognize it and gives the following compile time error:</p>
<p>Cannot resolve attribute &#8217;skin&#8217; for component type mx.controls.Button.</p>
<p>Regards,<br />
S.Ali</p>
]]></content:encoded>
	</item>
</channel>
</rss>
