<?xml version="1.0" encoding="utf-8"?>
			
			<rss version="2.0" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:cc="http://web.resource.org/cc/" xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd">

			<channel>
			<title>Leave That Thing Alone Blog</title>
			<link>http://www.leavethatthingalone.com/blog/index.cfm</link>
			<description>Leave That Thing Alone Blog - ColdFusion,Flex,Gumbo,Flash,Maps,CSS,Photography and other topics by Seth Duffey</description>
			<language>en-us</language>
			<pubDate>Thu, 17 May 2012 16:37:02 -0400</pubDate>
			<lastBuildDate>Mon, 23 Nov 2009 10:41:00 -0400</lastBuildDate>
			<generator>BlogCFC</generator>
			<docs>http://blogs.law.harvard.edu/tech/rss</docs>
			<managingEditor>sethduffey@gmail.com</managingEditor>
			<webMaster>sethduffey@gmail.com</webMaster>
			<itunes:subtitle></itunes:subtitle>
			<itunes:summary></itunes:summary>
			<itunes:category text="Technology" />
			<itunes:category text="Technology">
				<itunes:category text="Podcasting" />
			</itunes:category>
			<itunes:category text="Technology">
				<itunes:category text="Tech News" />
			</itunes:category>
			<itunes:keywords></itunes:keywords>
			<itunes:author></itunes:author>
			<itunes:owner>
				<itunes:email>sethduffey@gmail.com</itunes:email>
				<itunes:name></itunes:name>
			</itunes:owner>
			<itunes:image href="" />
			<image>
				<url></url>
				<title>Leave That Thing Alone Blog</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm</link>
			</image>
			<itunes:explicit>no</itunes:explicit>
			
			<item>
				<title>Viewing Camera RAW Images with ColdFusion</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2009/11/23/ColdFusionReadCameraRAW</link>
				<description>
				
				&lt;p&gt;
	This example demonstrates how to open/save/view Camera RAW images with ColdFusion and &lt;a href=&quot;http://jrawio.rawdarkroom.org/home.html&quot;&gt;jrawio&lt;/a&gt;. 
	jrawio is a Service Provider Implementation for the java ImageIO it provides the ability to read camera raw image formats such as Canon CR2/CRW and Nikon NEF. 
	Check the jrawio site for a list of currently supported cameras.
&lt;/p&gt;

&lt;h3&gt;Setup jrawio&lt;/h3&gt;
&lt;p&gt;
	The first step is to download the &lt;a href=&quot;http://jrawio.rawdarkroom.org/home.html&quot;&gt;jrawio&lt;/a&gt; binary.&lt;br /&gt;
	Take the jar (it.tidalwave.imageio.raw-[version].jar) and place it in ColdFusion&apos;s &amp;quot;\lib\&amp;quot; directory.
&lt;/p&gt;

&lt;h3&gt;Read RAW image and write to JPG&lt;/h3&gt;

&lt;p&gt;
	This first example reads a camera raw file and converts it to a JPG and writes it to a file.
	The benefit of writing the file as a JPG is that this process is relatively fast.
&lt;/p&gt;

&lt;pre class=&quot;coldfusion&quot;&gt;&amp;lt;cfscript&gt;
	//input file
	filename = expandPath(&quot;CRW_3933.CRW&quot;);
	fileio = createObject(&quot;Java&quot;,&quot;java.io.File&quot;).init(filename);
	//read RAW
	imageio = createObject(&quot;Java&quot;,&quot;javax.imageio.ImageIO&quot;).read(fileio);
	//write jpg
	outname = expandPath(&quot;CRW_3933.jpg&quot;);
	output = createObject(&quot;Java&quot;,&quot;java.io.File&quot;).init(outname);
	createObject(&quot;Java&quot;,&quot;javax.imageio.ImageIO&quot;).write(imageio, &quot;jpg&quot;, output);
&amp;lt;/cfscript&gt;
&lt;/pre&gt;

&lt;h3&gt;Read RAW image, resize, and writetobrowser&lt;/h3&gt;

&lt;p&gt;
	This next example reads a camera raw image, resizes the image to a thumbnail, then writes that image to browser. 
	Warning this can be very slow.
&lt;/p&gt;

&lt;pre class=&quot;coldfusion&quot;&gt;&amp;lt;cfscript&gt;
	//input file
	filename = expandPath(&quot;CRW_3933.CRW&quot;);
	fileio = createObject(&quot;Java&quot;,&quot;java.io.File&quot;).init(filename);
	//read RAW
	imageio = createObject(&quot;Java&quot;,&quot;javax.imageio.ImageIO&quot;).read(fileio);
	//resize
	imageWidth = 200;
	imageHeight = 200;
	scaledImage = imageio.getScaledInstance(JavaCast(&quot;int&quot;, imageWidth), JavaCast(&quot;int&quot;, imageHeight), imageio.SCALE_FAST);
	bufferedImage = createObject(&quot;java&quot;, &quot;java.awt.image.BufferedImage&quot;).init(JavaCast(&quot;int&quot;, imageWidth), JavaCast(&quot;int&quot;, imageHeight), imageio.TYPE_INT_RGB);
	graphics = bufferedImage.createGraphics();
	graphics.drawImage(scaledImage, 0, 0, Javacast(&quot;null&quot;, &quot;&quot;));
	//create cfimage from buffered image
	cfimage = imageNew(bufferedImage);
&amp;lt;/cfscript&gt;

&amp;lt;cfimage action=&quot;writeToBrowser&quot; source=&quot;#cfimage#&quot;&gt;
&lt;/pre&gt;

&lt;h3&gt;Can be slow...&lt;/h3&gt;
&lt;p&gt;
	Be aware that processing of RAW images can be very slow and processor intensive.
	For example the second code sample may take 10-30 seconds with a large raw image.
&lt;/p&gt; 
				</description>
				
				<category>ColdFusion</category>				
				
				<category>Photography</category>				
				
				<category>Camera RAW</category>				
				
				<pubDate>Mon, 23 Nov 2009 10:41:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2009/11/23/ColdFusionReadCameraRAW</guid>
				
			</item>
			
			<item>
				<title>Flex 4 Custom Preloader</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2009/11/11/Flex4CustomPreloader</link>
				<description>
				
				&lt;p&gt;
In this example were going to look at a way to create a custom preloader SWC in Flash Professional and use it 
inside of a Flex 4 application by extending the SparkDownloadProgressBar class.
&lt;br /&gt;
This preloader will display the progress percentage of loading and also a count of RSLs as they are being loaded, after loading is complete 
the progress of initialization will be displayed. Both of the progresses will be displayed by a graphical progress bas and in text.
&lt;/p&gt;

&lt;p&gt;
	&lt;a href=&quot;http://www.leavethatthingalone.com/examples/flex/Flex4PreloaderExample/Flex4PreloaderExample.html&quot; target=&quot;_blank&quot;&gt;&lt;strong&gt;View Demo Preloader App&lt;/strong&gt; (right click for source view)&lt;/a&gt;
&lt;/p&gt;

&lt;p&gt;
	The preloader may fly by, so lets first take a look at how this progress bar looks as it is loading the Flex app:
	&lt;br/&gt;
	&lt;img src=&quot;/examples/flex/Flex4PreloaderExample/flex4_preloader01.png&quot; width=&quot;331&quot; height=&quot;171&quot; alt=&quot;flex 4 preloader&quot; /&gt;
&lt;/p&gt;
&lt;p&gt;
	The next screenshot shows the progress as RSLs are being loaded:
	&lt;br/&gt;
	&lt;img src=&quot;/examples/flex/Flex4PreloaderExample/flex4_preloader02.png&quot; width=&quot;331&quot; height=&quot;171&quot; alt=&quot;flex 4 preloader&quot; /&gt;
&lt;/p&gt;
&lt;p&gt;
	Finally the progress of initialization, with a second progress bar:
	&lt;br/&gt;
	&lt;img src=&quot;/examples/flex/Flex4PreloaderExample/flex4_preloader03.png&quot; width=&quot;331&quot; height=&quot;171&quot; alt=&quot;flex 4 preloader&quot; /&gt;
&lt;/p&gt;





&lt;h4&gt;Creating the Preloader SWC in Flash Pro&lt;/h4&gt;

&lt;p&gt;
	In Flash professional we create a custom preloader. In this example there are several layers which the design is created from.
	The layer &apos;prog_bar&apos; and &apos;initilize_bar&quot; hold shapes that we will use to resize to show progress.
	The &apos;loading text&apos; layer contains some dynamic text that has Character Embedding for upper/lower/numbers.
	The layers look like this:
&lt;/p&gt;

&lt;img src=&quot;/examples/flex/Flex4PreloaderExample/flex4_preloader_flash.png&quot; width=&quot;218&quot; height=&quot;159&quot; alt=&quot;flex 4 preloader&quot; /&gt;
&lt;p&gt;
	The custom preloader FLA can be found in the example by viewing source.
&lt;/p&gt;

&lt;p&gt;
	The FLA preloader is a movie clip and its properties are set for &amp;quot;Export for ActioScript&amp;quot; the &amp;quot;Class&amp;quot; property is set to &amp;quot;PreloaderDisplay&amp;quot; this allows us to have a PreloaderDisplay.swc created when this FLA is published.
&lt;/p&gt;

&lt;a href=&quot;/examples/flex/Flex4PreloaderExample/flex4_preloader_flash_prop_large.png&quot;&gt;&lt;img src=&quot;/examples/flex/Flex4PreloaderExample/flex4_preloader_flash_prop_small.png&quot; width=&quot;230&quot; height=&quot;148&quot; alt=&quot;flex 4 preloader&quot; border=&quot;none&quot; /&gt;&lt;/a&gt;

&lt;p&gt;
	In the first frame of the FLA &amp;quot;actions&amp;quot; layer we create the functions to set the two different progress bars:
&lt;/p&gt;

&lt;pre lang=&quot;actionscript3&quot;&gt;
//reset
setMainProgress(0);
setInitalizeProgress(0);
loading_txt.text = &quot;&quot;;

//function for setting main prgress bar
function setMainProgress(percent:Number):void {
	prog_bar.width = percent * 275;
}

//function for setting the initilize bar
function setInitalizeProgress(percent:Number):void {
	initialize_bar.width = percent * 275;
}
&lt;/pre&gt;

&lt;p&gt;
	The final step is to &amp;quot;Publish&amp;quot; the FLA so that the SWC file is create, this SWC will be used in Flash Builder.
&lt;/p&gt;



&lt;h4&gt;Creating the Custom Preloader in Flex 4&lt;/h4&gt;
&lt;p&gt;
	The first step is to place the PreloaderDisplay.swc in the &amp;quot;libs&amp;quot; folder, this will make the PreloaderDisplay and its methods available to Flex:
&lt;/p&gt;
&lt;img src=&quot;/examples/flex/Flex4PreloaderExample/flex4_preloader_libs.png&quot; width=&quot;189&quot; height=&quot;55&quot; alt=&quot;preloader swc libs&quot; /&gt;
&lt;p&gt;
	To define a custom preloader we will do this in the Flex application&apos;s Application file, we simply specify the preloader class:
&lt;/p&gt;
&lt;pre lang=&quot;actionscript3&quot;&gt;
&amp;lt;s:Application preloader=&quot;com.themorphicgroup.preload.Preloader&quot; ...
&lt;/pre&gt;

&lt;p&gt;
	In the Preloader class we will extend &amp;quot;SparkDownloadProgressBar&amp;quot;.
	
	The SparkDownloadProgressBar class displays download progress. &lt;br /&gt;
	
	From Flex 4 docs: It is used by the Preloader control to provide user feedback while the application is downloading and loading. 
	The download progress bar displays information about two different phases of the application: the download phase and the initialization phase. 
&lt;/p&gt;
&lt;p&gt;
	The Preloader.as extends &amp;quot;SparkDownloadProgressBar&amp;quot; and we will use the FLA PreloaderDisplay.swc by creating a variable called &amp;quot;preloaderDisplay&amp;quot;:
&lt;/p&gt;
&lt;pre lang=&quot;actionscript3&quot;&gt;
public class Preloader extends SparkDownloadProgressBar {
	private var preloaderDisplay:PreloaderDisplay;
	...
&lt;/pre&gt;

&lt;p&gt;
	To add the PreloaderDisplay we will override the SparkDownloadProgressBar&apos;s &amp;quot;createChildren&amp;quot; method, in this method we will create a new PreloaderDisplay and 
	use the &amp;quot;addChild&amp;quot; method (SparkDownloadProgressBar inherits addChild from DisplayObjectContainer):
&lt;/p&gt;
&lt;pre lang=&quot;actionscript3&quot;&gt;
override protected function createChildren():void
{
	if (!preloaderDisplay) {
		preloaderDisplay = new PreloaderDisplay();
		
		var startX:Number = Math.round((stageWidth - preloaderDisplay.width) / 2);
		var startY:Number = Math.round((stageHeight - preloaderDisplay.height) / 2);
		
		preloaderDisplay.x = startX;
		preloaderDisplay.y = startY;
		addChild(preloaderDisplay);
	}
}
&lt;/pre&gt;

&lt;p&gt;
	There are several methods that will override so that we can make updates to the PreloaderDisplay.swc. 
	The rslProgressHandler method will be called each time a RSL is being loaded. We will use this method to set text indicating the current count of RSL being loaded:
&lt;/p&gt;

&lt;pre lang=&quot;actionscript3&quot;&gt;
private var rslBaseText:String = &quot;loading: &quot;;
override protected function rslProgressHandler(evt:RSLEvent):void {
	if (evt.rslIndex &amp;&amp; evt.rslTotal) {
		//create text to track the RSLs being loaded
		rslBaseText = &quot;loading RSL &quot; + evt.rslIndex + &quot; of &quot; + evt.rslTotal + &quot;: &quot;;
	}
}
&lt;/pre&gt;


&lt;p&gt;
	The next method we will override is setDownloadProgress. This method indicates the current download progress. in this method we will set the 
	PreloaderDisplay.swc main progress bar and set the text:
&lt;/p&gt;

&lt;pre lang=&quot;actionscript3&quot;&gt;
override protected function setDownloadProgress(completed:Number, total:Number):void {
	if (preloaderDisplay) {
		//set the main progress bar inside PreloaderDisplay
		preloaderDisplay.setMainProgress(completed/total);
		//set percetage text to display, if loading RSL the rslBaseText will indicate the number
		setPreloaderLoadingText(rslBaseText + Math.round((completed/total)*100).toString() + &quot;%&quot;);
	}
}
&lt;/pre&gt;

&lt;p&gt;
	Finally we will look at overriding setInitProgress, this method indicates the progress of the Flex app as it initializes.
	We will set the text in PreloaderDisplay.swc and change the progress of the second initialize progress bar:
&lt;/p&gt;
&lt;pre lang=&quot;actionscript3&quot;&gt;
override protected function setInitProgress(completed:Number, total:Number):void {
	if (preloaderDisplay) {
		//set the initialization progress bar inside PreloaderDisplay
		preloaderDisplay.setInitalizeProgress(completed/total);
		//set loading text
		if (completed &gt; total) {
			setPreloaderLoadingText(&quot;almost done&quot;);
		} else {
			setPreloaderLoadingText(&quot;initializing &quot; + completed + &quot; of &quot; + total);
		}
	}
}
&lt;/pre&gt;
&lt;p&gt;&amp;nbsp;&lt;p&gt;
&lt;p&gt;
	This blog entry does not cover every bit of code used in the preloader, so
	&lt;a href=&quot;http://www.leavethatthingalone.com/examples/flex/Flex4PreloaderExample/Flex4PreloaderExample.html&quot; target=&quot;_blank&quot;&gt;&lt;strong&gt;View Demo Preloader App&lt;/strong&gt; right click for source view&lt;/a&gt;
&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;p&gt; 
				</description>
				
				<category>Flex</category>				
				
				<category>Flash</category>				
				
				<pubDate>Wed, 11 Nov 2009 10:05:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2009/11/11/Flex4CustomPreloader</guid>
				
			</item>
			
			<item>
				<title>Example of Feature Rich Item Renderers in Flex 4</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2009/10/15/flex4ItemRenderers</link>
				<description>
				
				&lt;p&gt;
This is an example of creating feature rich item renderers in Flex 4. The example retrieves this blog&apos;s RSS feed and displays each entry in a list. This example will demonstrate:

&lt;/p&gt;

&lt;ul style=&quot;list-style:square&quot;&gt;
	&lt;li&gt;Skinning and item renderer&lt;/li&gt;
	&lt;li&gt;States in an item renderer&lt;/li&gt;
	&lt;li&gt;Pass callback function into item renderer&lt;/li&gt;
	&lt;li&gt;Override ItemRenderer &apos;set data&apos; have data as a known ValueObject&lt;/li&gt;
	&lt;li&gt;Swap icons/images based on data values&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;
	&lt;a href=&quot;http://www.themorphicgroup.net/examples/Flex4ItemRenderer01/Flex4ItemRenderer01.html&quot;&gt;&lt;img src=&quot;http://www.themorphicgroup.net/blog/wp-content/uploads/2009/10/itemrenderer_flex4_01_post.png&quot; width=&quot;444&quot; height=&quot;175&quot; border=&quot;none&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;
	&lt;br /&gt;
	&amp;nbsp;&lt;a href=&quot;http://www.themorphicgroup.com/examples/Flex4ItemRenderer01/Flex4ItemRenderer01.html&quot;&gt;&lt;strong&gt;View the Example&lt;/strong&gt; with source view enabled&lt;/a&gt;
&lt;/p&gt;
	This blog post will cover the main points of the example but not the entire code, so view the example&apos;s source view to see all the code in full.
&lt;p&gt;

&lt;/p&gt;

&lt;h3&gt;Getting Blog Entries From RSS&lt;/h3&gt;
&lt;p&gt;
	I won&apos;t go into too much detail about how the data is retrieved, view the source for all the details. The RSSService class makes a request to this blog&apos;s RSS url. That XML responce is turned into an ArrayCollection of BlogEntryVO value objects. The result ArrayCollection is set as the data provider for the Spark List.
&lt;/p&gt;

&lt;h3&gt;Skinning the Spark List&lt;/h3&gt;
&lt;p&gt;
	&lt;strong&gt;Spark List:&lt;/strong&gt; 
	The first step in skinning the Spark List is to define the &apos;skinClass&apos;:
&lt;/p&gt;

&lt;code&gt;
&lt;s:List id=&quot;blogList&quot; 
	skinClass=&quot;com.themorphicgroup.skins.list.ListSkin&quot;
	change=&quot;blogList_selectionHandler(event)&quot;
	caretChange=&quot;blogList_selectionHandler(event)&quot; /&gt;
&lt;/code&gt;
&lt;p&gt;
	&lt;strong&gt;Skinning Spark List:&lt;/strong&gt; 
	Lets look at the &apos;com.themorphicgroup.skins.list.ListSkin&apos; List skin class. The most important parts of this skin is the &apos;Scroller&apos; and &apos;DataGroup&apos; it surrounds.
	The DataGroup is a simple container class in Flex 4 for holding data items and item renderers. The Scroller enables the DataGroup items to be scrolled. Full List skin code:
&lt;/p&gt;


&lt;code&gt;
&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt;
&lt;s:SparkSkin xmlns:fx=&quot;http://ns.adobe.com/mxml/2009&quot;
			 xmlns:s=&quot;library://ns.adobe.com/flex/spark&quot;
			 xmlns:mx=&quot;library://ns.adobe.com/flex/halo&quot;&gt;

	&lt;fx:Metadata&gt;
		[HostComponent(&quot;spark.components.List&quot;)]
	&lt;/fx:Metadata&gt;
	
	&lt;s:states&gt;
		&lt;s:State name=&quot;normal&quot; /&gt;
		&lt;s:State name=&quot;over&quot;/&gt;
	&lt;/s:states&gt;
	
	&lt;!-- background --&gt;
	&lt;s:Rect top=&quot;0&quot; right=&quot;0&quot; bottom=&quot;0&quot; left=&quot;0&quot;&gt;
		&lt;s:stroke&gt;
			&lt;s:SolidColorStroke color=&quot;0x999999&quot; weight=&quot;2&quot;/&gt;
		&lt;/s:stroke&gt;
		&lt;s:fill&gt;
			&lt;s:SolidColor color=&quot;0xffffff&quot; color.over=&quot;0xf8f8f8&quot; /&gt;
		&lt;/s:fill&gt;
	&lt;/s:Rect&gt;
	
	&lt;!-- scroller --&gt;
	&lt;s:Scroller id=&quot;scroller&quot;
				left=&quot;0&quot;
				top=&quot;0&quot;
				right=&quot;0&quot;
				bottom=&quot;0&quot; 
				horizontalScrollPolicy=&quot;off&quot;
				minViewportInset=&quot;1&quot;
				focusEnabled=&quot;false&quot;&gt;
		
		&lt;!-- container for data--&gt;
		&lt;s:DataGroup id=&quot;dataGroup&quot;&gt;
			&lt;s:layout&gt;
				&lt;s:VerticalLayout gap=&quot;0&quot; horizontalAlign=&quot;contentJustify&quot; /&gt;
			&lt;/s:layout&gt;
		&lt;/s:DataGroup&gt;
		
	&lt;/s:Scroller&gt;
	
&lt;/s:SparkSkin&gt;
&lt;/code&gt;

&lt;p&gt;
	&lt;strong&gt;Skinning Spark List and global vertical scrollers:&lt;/strong&gt; 
	The last thing we will look at in skinning the List is the skin for the Scroller (VScroll). The skin classes for the scroller are in com.themorphicgroup.skins.scroller.vertical 
	To define the &apos;VerticalScrollbar&apos; Skin to all Spark VScrollBar we do that in the css file:
&lt;/p&gt;

&lt;code&gt;
s|VScrollBar {
	skinClass: ClassReference(&quot;com.themorphicgroup.skins.scroller.vertical.VerticalScrollbar&quot;);
}
&lt;/code&gt;


&lt;h3&gt;Define an ItemRenderer for the Spark List&lt;/h3&gt;

&lt;p&gt;
	In creationComplete we will create the item renderer for the Spark List, we will also define any needed properties.
	In this case we want to pass in a callback funtion for when the delete icon is clicked in an item renderer.
&lt;/p&gt;


&lt;code&gt;
//create itemrenderer
protected function application_creationCompleteHandler(event:FlexEvent):void {
	//create itemrenderer
	blogListItemRenderer = new ClassFactory(BlogEntryItemRenderer);
	//define properties (callback for item delete)
	blogListItemRenderer.properties = {deleteHandlerFunction:itemDeleteClick_handler};
	//set itemrenderer to List
	blogList.itemRenderer = blogListItemRenderer;
	.... }

//callback function for delete click
private function itemDeleteClick_handler(blogEntryItem:BlogEntryVO):void {
	...
&lt;/code&gt;

&lt;p&gt;
Inside the Item Renderer when the delete icon is clicked the callback function is passed the current item renderer&apos;s data (a value object):
&lt;/p&gt;

&lt;code&gt;
public var deleteHandlerFunction:Function;
private function trash_btn_clickHandler(event:MouseEvent):void {
	//callback function pass BlogEntryVO value object
	deleteHandlerFunction(blogEntry);
}
&lt;/code&gt;

&lt;h3&gt;The ItemRenderer&lt;/h3&gt;

&lt;p&gt;
	&lt;strong&gt;Setting data in the ItemRenderer: &lt;/strong&gt;
	In the &apos;BlogEntryItemRenderer&apos; we will override the the set data function and set a BlogEntryVO with the data of the item renderer:
&lt;/p&gt;

&lt;code&gt;
private var blogEntry:BlogEntryVO

override public function set data(value:Object):void {
	super.data = value;
	if (value is BlogEntryVO) {
		blogEntry = BlogEntryVO(value);
	}
}
&lt;/code&gt;


&lt;p&gt;
	&lt;strong&gt;Displaying data in the ItemRenderer: &lt;/strong&gt;
	To display the data values in the itemrenderer we will override updateDisplayList and set values to Labels etc:
&lt;/p&gt;
&lt;code&gt;
override protected function updateDisplayList(unscaledWidth:Number, unscaledHeight:Number):void {
	super.updateDisplayList(unscaledWidth,unscaledHeight);
	
	if (title_lbl) {
		title_lbl.text = blogEntry.title;
		...
&lt;/code&gt;

&lt;h3&gt;Skinning and States in the ItemRenderer&lt;/h3&gt;
&lt;p&gt;
	To make the item renderer more attractive and interactive we will create some states. In Flex 4 you can specify not only the name of a state but a name that will define a group of states:
&lt;/p&gt;

&lt;code&gt;
&lt;s:states&gt;
	&lt;s:State name=&quot;normal&quot; /&gt;
	&lt;s:State name=&quot;hovered&quot; stateGroups=&quot;[hoveredStates]&quot; /&gt;
	&lt;s:State name=&quot;selected&quot; stateGroups=&quot;[selectedStates]&quot; /&gt;
	&lt;s:State name=&quot;normalAndShowsCaret&quot; /&gt;
	&lt;s:State name=&quot;hoveredAndShowsCaret&quot; stateGroups=&quot;[hoveredStates]&quot; /&gt;
	&lt;s:State name=&quot;selectedAndShowsCaret&quot; stateGroups=&quot;[selectedStates]&quot; /&gt;
&lt;/s:states&gt;
&lt;/code&gt;

&lt;p&gt;
	Having the state and stateGroups names means we can define properties for those states. For example with can set the alpha of the background color as &lt;em&gt;alpha=&apos;0&apos;&lt;/em&gt; and them the when we are in one of the hovered states as &lt;em&gt;alpha.hoveredStates=&apos;.1&apos;&lt;/em&gt;:
&lt;/p&gt;

&lt;code&gt;
&lt;s:Rect width=&quot;100%&quot; height=&quot;100%&quot;&gt;
	&lt;s:fill&gt;
		&lt;s:SolidColor color=&quot;0x6699cc&quot; alpha=&quot;0&quot; alpha.hoveredStates=&quot;.1&quot; alpha.selectedStates=&quot;.25&quot; /&gt;
	&lt;/s:fill&gt;
&lt;/s:Rect&gt;

&lt;s:Label id=&quot;title_lbl&quot;
		 maxDisplayedLines=&quot;1&quot;
		 styleName=&quot;myriad&quot;
		 left=&quot;10&quot;
		 top=&quot;10&quot;
		 right=&quot;26&quot; 
		 textDecoration.hoveredStates=&quot;underline&quot;
		 fontWeight.selectedStates=&quot;bold&quot;
		 color=&quot;#000000&quot;
		 fontSize=&quot;14&quot;/&gt;
&lt;/code&gt;

&lt;h3&gt;Summary&lt;/h3&gt;
&lt;p&gt;
	This blog post does not cover every bit of code in the example so &lt;a href=&quot;http://www.themorphicgroup.net/examples/Flex4ItemRenderer01/Flex4ItemRenderer01.html&quot;&gt;&lt;strong&gt;View the Example&lt;/strong&gt; with source view enabled&lt;/a&gt;.
&lt;/p&gt; 
				</description>
				
				<category>Flex</category>				
				
				<pubDate>Thu, 15 Oct 2009 08:18:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2009/10/15/flex4ItemRenderers</guid>
				
			</item>
			
			<item>
				<title>ColdFusion devcamp in San Francisco Nov. 7th, 2009</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2009/10/13/cfdevcamp2009</link>
				<description>
				
				&lt;p&gt;
Sign up for &lt;strong&gt;cfdevcamp&lt;/strong&gt; in San Francisco November 7th 2009.
&lt;/p&gt;

&lt;a href=&quot;http://www.cfdevcamp.org/&quot;&gt;&lt;img src=&quot;http://www.leavethatthingalone.com/blog/images/cfdevcamp.png&quot; style=&quot;border:none;&quot; /&gt;&lt;/a&gt;

&lt;p&gt;
&lt;a href=&quot;http://www.cfdevcamp.org/&quot;&gt;cfdevcamp&lt;/a&gt; is a gathering of people passionate about learning through  collaboration.  Attendees will work in small teams to code projects  ideas from the team members or from a suggested list of projects.   This will not be a lecture style event or a traditional classroom with  a set curriculum and learning materials.  We want you to ask questions, hack away and have fun.
&lt;/p&gt;&lt;p&gt;
This is a great event for ColdFusion beginners, experts, and everyone in between.
&lt;/p&gt;&lt;p&gt;
For more information and to sign up for this &lt;strong&gt;free event&lt;/strong&gt; visit: &lt;a href=&quot;http://www.cfdevcamp.org/&quot;&gt;www.cfdevcamp.org&lt;/a&gt;&lt;/p&gt; 
				</description>
				
				<category>ColdFusion</category>				
				
				<pubDate>Tue, 13 Oct 2009 07:09:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2009/10/13/cfdevcamp2009</guid>
				
			</item>
			
			<item>
				<title>ColdFusion Security at Sacramento ColdFusion User Group Oct. 13, 2009</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2009/10/12/saccfugOctober2009Meeting</link>
				<description>
				
				&lt;p&gt;
Join the Sacramento ColdFusion User Group Oct. 13, 2009 for a presentation on how to secure your ColdFusion applications and server. We will cover a broad range of topics from preventing SQL injection and cross site scripting attacks, to form validation, server settings, and more.
&lt;/p&gt;&lt;p&gt;
We will also be doing one of our giant Adobe software giveaways...
&lt;/p&gt;&lt;p&gt;
More info and directions here: &lt;a href=&quot;http://www.saccfug.com/&quot;&gt;www.saccfug.com&lt;/a&gt;
&lt;/p&gt;&lt;p&gt; 
				</description>
				
				<category>ColdFusion</category>				
				
				<category>SacCFUG</category>				
				
				<pubDate>Mon, 12 Oct 2009 07:45:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2009/10/12/saccfugOctober2009Meeting</guid>
				
			</item>
			
			<item>
				<title>Sean Corfield and Railo at Sacramento ColdFusion User Group</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2009/6/4/Sean-Corfield-and-Railo-at-Sacramento-ColdFusion-User-Group</link>
				<description>
				
				Join the Sacramento ColdFusion User Group on Tuesday June 9th 2009 for &lt;a href=&quot;http://corfield.org/blog/index.cfm&quot;&gt;Sean Corfield&lt;/a&gt; who will be speaking about &lt;a href=&quot;http://www.getrailo.org/&quot;&gt;Railo&apos;s&lt;/a&gt; CFML engine. 

For more details on the meeting visit the &lt;a href=&quot;http://www.saccfug.com/&quot;&gt;&lt;b&gt;SacCFUG website&lt;/b&gt;&lt;/a&gt;. 
				</description>
				
				<category>ColdFusion</category>				
				
				<category>SacCFUG</category>				
				
				<pubDate>Thu, 04 Jun 2009 22:45:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2009/6/4/Sean-Corfield-and-Railo-at-Sacramento-ColdFusion-User-Group</guid>
				
			</item>
			
			<item>
				<title>CFCPhotoBlog Adds Railo Support</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2009/4/28/CFCPhotoBlogAddsRailoSupport</link>
				<description>
				
				&lt;img src=&quot;/projects/CFCPhotoBLog/img/cfcphotoblog.png&quot; style=&quot;float:right;&quot; /&gt;

&lt;a href=&quot;/projects/CFCPhotoBLog&quot;&gt;CFCPhotoBlog&lt;/a&gt; has been updated to support &lt;a href=&quot;http://www.getrailo.org/&quot;&gt;Railo&lt;/a&gt;

There were actually very few changes required to make Railo happy. The main problem was that I had used several Adobe ColdFusion specific cfform tags that were not really needed.

View a demo and download from &lt;a href=&quot;/projects/CFCPhotoBLog&quot;&gt;&lt;strong&gt;CFCPhotoBlog project page&lt;/strong&gt;&lt;/a&gt;

&lt;div class=&quot;clear&quot;&gt;&amp;nbsp;&lt;/div&gt; 
				</description>
				
				<category>CFCPhotoBlog</category>				
				
				<category>ColdFusion</category>				
				
				<category>Photography</category>				
				
				<pubDate>Tue, 28 Apr 2009 21:56:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2009/4/28/CFCPhotoBlogAddsRailoSupport</guid>
				
			</item>
			
			<item>
				<title>Example of Feature Rich Dynamic Item Renderers in Flex 3</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2009/2/20/FeatureRichDynamicItemRenderers</link>
				<description>
				
				&lt;p&gt;
	In the &lt;a href=&quot;http://www.leavethatthingalone.com/blog/index.cfm/2008/9/15/ExampleofFeatureRichItemRenderersinFlex&quot;&gt;last Flex 3 rich feature item renderer example&lt;/a&gt; we looked at item renderers that had some nice visual and functional features, in this example we will take it to the next step and introduce some dynamic abilities to the item renderers. 
    
    By using dynamic item renderers you can create more flexible &amp;amp; reusable itemrenderers, you can also do neat stuff like pass callback functions to handle events in the itemrenderer.&lt;/p&gt;

&lt;p&gt;
	Here are some of the things this dynamic item renderer example will demonstrate:
&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;Reuse the same item renderer for a DataGrid and a List, each with a different data provider&lt;/li&gt;
    &lt;li&gt;Pass delete/click function into item renderer&lt;/li&gt;
    &lt;li&gt;Dynamically change icons&lt;/li&gt;
    &lt;li&gt;Dynamically change the label function&lt;/li&gt;
    &lt;li&gt;Set label title style&lt;/li&gt;
&lt;/ul&gt;


&lt;p style=&quot;margin-left:20px;&quot;&gt;

  &lt;a href=&quot;http://www.leavethatthingalone.com/examples/flex/itemrenderer02&quot;&gt;&lt;img src=&quot;http://www.leavethatthingalone.com/examples/flex/itemrenderer02/itemrenderer_02_post.png&quot; width=&quot;200&quot; height=&quot;105&quot; alt=&quot;&quot; border=&quot;0&quot; /&gt;&lt;/a&gt;
	&lt;br /&gt;
    &lt;a href=&quot;http://www.leavethatthingalone.com/examples/flex/itemrenderer02&quot;&gt;&lt;strong&gt;View Example&lt;/strong&gt; (right click for source)&lt;/a&gt;
&lt;/p&gt;
&lt;p&gt;In this post we won&apos;t go over every detail of the code, so check out the source in the example. &lt;/p&gt;
&lt;p&gt;To start of with the basics, here is how to setup a  itemrenderer using  ClassFactory:&lt;/p&gt;

&lt;pre&gt;
private var personItemRendererFactory:ClassFactory;
private function onInitialize():void {
	personItemRendererFactory = new ClassFactory(MyItemRenderer);
	peopleColumn.itemRenderer = personItemRendererFactory;
}
...
&amp;lt;mx:DataGrid id=&amp;quot;peopleDataGrid&amp;quot; dataProvider=&amp;quot;{peopleDataProvider}&amp;quot;&gt;
	&amp;lt;mx:columns&gt;
		&amp;lt;mx:DataGridColumn id=&quot;peopleColumn&quot; /&gt;
	&amp;lt;/mx:columns&gt;
&amp;lt;/mx:DataGrid&gt;
&lt;/pre&gt;
&lt;p&gt;The example above doesn&apos;t really do much more than setting in itemrenderer in the DataGrid tag itself would, so lets set a property of the itemrenderer:&lt;/p&gt;

&lt;pre&gt;
private function onInitialize():void {
	personItemRendererFactory = new ClassFactory(MyItemRenderer);
	personItemRendererFactory.properties = {doStuff: true};
	peopleColumn.itemRenderer = personItemRendererFactory;
}
&lt;/pre&gt; 
&lt;p&gt;
In the above example we are now creating an itemrenderer and setting the &apos;doStuff&apos; property using the ClassFactory properties object. Using the class factory properties we can set many things at once including functions. Let&apos;s say we want  to listen for a click event inside the itemrenderer we can pass in a callback function that gets called from the item renderer when clicked:
&lt;/p&gt;

&lt;pre&gt;
private function onInitialize():void {
	personItemRendererFactory = new ClassFactory(MyItemRenderer);
	personItemRendererFactory.properties = {clickFunction: itemrendererClick_handler};
	peopleColumn.itemRenderer = personItemRendererFactory;
}

private function itemrendererClick_handler(evt:MouseEvent):void {
	Alert.show(&apos;clicked&apos;);
}

/* this in item renderer */
//inside the itemrenderer we need to define the click function
public var clickFunction:Function;

//and then for this example lets call the clickFunction when the canvas is clicked
&amp;lt;mx:Canvas click=&amp;quot;clickFunction(event)&amp;quot;...
&lt;/pre&gt;

&lt;p&gt;
	The above example allows a function to set on the itemrenderer. When the itemrenderer is clicked the event is handled in the same component that the holds DataGrid, this can be very convenient.&lt;/p&gt;

&lt;p&gt;When using the properties of ClassFactory there is a something to be aware of; your itemrenderer may require a property to be set, but the ClassFactory and properties will not enforce that property to be required. For example if a click handler function is required in the ItemRenderer but not set in the properties there will be a runtime error when the ItemRenderer is clicked.&lt;/p&gt;

&lt;p&gt;
	View the example and right click for source to see
	more details on how to do things like dynamically change icons and label functions.&lt;br /&gt;
	&lt;a href=&quot;http://www.leavethatthingalone.com/examples/flex/itemrenderer02&quot;&gt;&lt;strong&gt;View Example&lt;/strong&gt; (right click for source)&lt;/a&gt;
&lt;/p&gt;
&lt;p&gt;This example is not intended to be a best practices for the most efficient item renderers, for further reading: &lt;a href=&quot;http://www.adobe.com/devnet/flex/articles/itemrenderers_pt5_print.html&quot;&gt;Efficient Item Renderers&lt;/a&gt;,  &lt;a href=&quot;http://livedocs.adobe.com/flex/3/html/help.html?content=ascomponents_advanced_3.html&quot;&gt;Advanced visual components&lt;/a&gt;&lt;/p&gt; 
				</description>
				
				<category>Flex</category>				
				
				<pubDate>Fri, 20 Feb 2009 09:46:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2009/2/20/FeatureRichDynamicItemRenderers</guid>
				
			</item>
			
			<item>
				<title>Edmund Event-Driven Framework At SacCFUG</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2009/2/9/saccfugFeb2009</link>
				<description>
				
				&lt;p&gt;
Join the &lt;a href=&quot;http://www.saccfug.com/&quot;&gt;Sacramento ColdFusion User Group&lt;/a&gt; Tuesday Feb. 10, 2009 for a presentation on the &amp;quot;&lt;a href=&quot;http://edmund.riaforge.org/&quot;&gt;Edmund&lt;/a&gt;&amp;quot; Event-Driven Framework by &lt;a href=&quot;http://patweb99.avatu.com/&quot;&gt;Patrick Santora&lt;/a&gt;.
&lt;/p&gt;

&lt;p&gt;
	For more details on the meeting visit the &lt;a href=&quot;http://www.saccfug.com/&quot;&gt;SacCFUG&lt;/a&gt; website.
&lt;/p&gt; 
				</description>
				
				<category>ColdFusion</category>				
				
				<category>SacCFUG</category>				
				
				<pubDate>Mon, 09 Feb 2009 07:19:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2009/2/9/saccfugFeb2009</guid>
				
			</item>
			
			<item>
				<title>Retrieve Exif Metadata from Camera RAW and TIFF in ColdFusion 8</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2009/1/31/coldfusionCameraRawAndTiffExif</link>
				<description>
				
				&lt;p&gt;
	This example demonstrates how to get Exif metadata from Camera RAW and TIFF files in ColdFusion. 
	In this sample I&apos;m using a raw CR2 file from a Canon D30.
	Please note this example only reads RAW exif metdata, it does not read/process the RAW image
&lt;/p&gt;
&lt;p&gt;
update: &lt;a href=&quot;http://www.leavethatthingalone.com/blog/index.cfm/2009/11/23/ColdFusionReadCameraRAW&quot;&gt;Viewing Camera RAW Images with ColdFusion&lt;/a&gt;
&lt;/p&gt;
&lt;p&gt;
	ColdFusion 8&apos;s  image tags allow the retrieval of Exif metadata from only certain image types, 
	ColdFusion actually uses &lt;a href=&quot;http://www.drewnoakes.com/code/exif/&quot;&gt;Drew Noakes Metadata Extract&lt;/a&gt; library. 
	There is now a beta version (metadata-extractor-2.4.0-beta-1.jar) that introduces code for processing camera RAW images and TIFF files.
&lt;/p&gt;

&lt;p&gt;
	One way to use this beta library is to go into the [coldfusion8]\lib\ folder and rename the &apos;metadata-extractor-2.2.2.jar&apos; file to .bak then copy the latest metadata-extractor JAR file into that directory.
&lt;/p&gt;

&lt;p&gt;
	However, in this example i&apos;m going to use Mark Mandel&apos;s &lt;a href=&quot;http://javaloader.riaforge.org/&quot;&gt;JavaLoader&lt;/a&gt; so I can use the beta library separately from the stable version cfimage uses.
&lt;/p&gt;
&lt;p&gt;
	The code below reads a camera Raw image then iterates through all the metadata:
&lt;/p&gt;
&lt;pre class=&quot;coldfusion&quot; style=&quot;min-height:500px;&quot;&gt;
&amp;lt;cfscript&gt;
	//read Canon RAW CR2 file
	photoFile = createObject(&quot;java&quot;,&quot;java.io.File&quot;).init(&quot;#expandpath(&apos;IMG_7913.CR2&apos;)#&quot;);
	//set the path
	paths[1] = &quot;D:\test\metadata-extractor-2.4.0-beta-1.jar&quot;;
	//create the loader
	javaLoader = createObject(&quot;component&quot;, &quot;JavaLoader&quot;).init(paths);
	//create the TiffMetadataReader instace
	tiffMetadataReader = javaLoader.create(&quot;com.drew.imaging.tiff.TiffMetadataReader&quot;);
	//read metadata
	metadata = tiffMetadataReader.readMetadata(photoFile);
	//get directories
	directories = metadata.getDirectoryIterator();
&amp;lt;/cfscript&gt;

&amp;lt;cfoutput&gt;
&amp;lt;table cellspacing=&quot;0&quot;&gt;
&amp;lt;cfloop condition=&quot;directories.hasNext()&quot;&gt;
	&amp;lt;cfset currentDirectory = directories.next() /&gt;
	&amp;lt;cfset tags = currentDirectory.getTagIterator() /&gt;
	&amp;lt;cfloop condition=&quot;tags.hasNext()&quot;&gt;
		&amp;lt;cfset currentTag = tags.next()&gt;
			&amp;lt;tr&gt;
				&amp;lt;td valign=&quot;top&quot;&gt;#currentTag.getTagType()#&amp;lt;/td&gt;
				&amp;lt;td style=&quot;vertical-align:top;width:150px;&quot;&gt;#currentTag.getTagName()#&amp;lt;/td&gt;
				&amp;lt;td valign=&quot;top&quot;&gt;#currentTag.getDescription()# &amp;lt;/td&gt;
				&amp;lt;td&gt;#currentTag.getTagTypeHex()#&amp;lt;/td&gt;
			&amp;lt;/tr&gt;
	&amp;lt;/cfloop&gt;
&amp;lt;/cfloop&gt;
&amp;lt;/table&gt;
&amp;lt;/cfoutput&gt;
&lt;/pre&gt;

&lt;p&gt;
Sample output:
&lt;/p&gt;
&lt;img src=&quot;http://www.leavethatthingalone.com/examples/samples/coldfusion_raw_exif.png&quot; width=&quot;421&quot; height=&quot;571&quot; alt=&quot;coldfusion raw tiff exif&quot; /&gt; 
				</description>
				
				<category>ColdFusion</category>				
				
				<category>Photography</category>				
				
				<category>Camera RAW</category>				
				
				<pubDate>Sat, 31 Jan 2009 22:51:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2009/1/31/coldfusionCameraRawAndTiffExif</guid>
				
			</item>
			
			<item>
				<title>CFCPhotoBlog 1.1 Update</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2009/1/19/cfcphotoblog1.1</link>
				<description>
				
				&lt;p&gt;
	&lt;a href=&quot;/projects/CFCPhotoBLog&quot;&gt;CFCPhotoBlog&lt;/a&gt; has been updated to version 1.1. Here is what is new:
&lt;/p&gt;

&lt;ul&gt;
	&lt;li&gt;New dark photoblog skin&lt;/li&gt;
	&lt;li&gt;New light photoblog skin&lt;/li&gt;
	&lt;li&gt;Support for &lt;a href=&quot;http://www.cooliris.com/product/&quot;&gt;cooliris/piclens&lt;/a&gt;&lt;/li&gt;
	&lt;li&gt;Update to &lt;a href=&quot;http://javaloader.riaforge.org/&quot;&gt;JavaLoader&lt;/a&gt; version 0.6 &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;
	This is not a huge update mainly I wanted a new look on my photoblog, so I added two new skins &apos;moderndark&apos; and &apos;modernlight&apos;. 
	For fun I added support for cooliris/piclens, this adds a special RSS feed that allows cooliris to view the photos.
&lt;/p&gt;

&lt;p&gt;
	As always suggestions and feature requests are welcomed. I am planning now for version 2.0.
&lt;/p&gt;

&lt;p&gt;
	&lt;a href=&quot;/projects/CFCPhotoBLog&quot;&gt;&lt;strong&gt;CFCPhotoBlog project page&lt;/strong&gt;&lt;/a&gt;
&lt;/p&gt; 
				</description>
				
				<category>CFCPhotoBlog</category>				
				
				<category>ColdFusion</category>				
				
				<category>Photography</category>				
				
				<pubDate>Mon, 19 Jan 2009 21:49:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2009/1/19/cfcphotoblog1.1</guid>
				
			</item>
			
			<item>
				<title>ColdBox Presentation at Sacramento ColdFusion User Group</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2009/1/9/ColdBox-Presentation-at-Sacramento-ColdFusion-User-Group</link>
				<description>
				
				&lt;p&gt;
Join the Sacramento ColdFusion User Group on January 13th 2009, &lt;a href=&quot;http://www.think-lab.net/blog/&quot;&gt;Matt Graf&lt;/a&gt; will be talking about the &lt;a href=&quot;http://coldboxframework.com/&quot;&gt;ColdBox&lt;/a&gt; ColdFusion framework.
&lt;/p&gt;

&lt;p&gt;
For more details and directions visit &lt;a href=&quot;http://www.saccfug.com/&quot;&gt;&lt;strong&gt;www.saccfug.com&lt;/strong&gt;&lt;/a&gt;
&lt;/p&gt; 
				</description>
				
				<category>ColdFusion</category>				
				
				<category>SacCFUG</category>				
				
				<pubDate>Fri, 09 Jan 2009 21:01:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2009/1/9/ColdBox-Presentation-at-Sacramento-ColdFusion-User-Group</guid>
				
			</item>
			
			<item>
				<title>Using Gumbo and itemRendererFunction to create multiple ItemRenderers</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2008/12/3/itemRendererFunction</link>
				<description>
				
				&lt;p&gt;
	&lt;a href=&quot;http://labs.adobe.com/technologies/gumbo/&quot; target=&quot;_blank&quot;&gt;Gumbo&lt;/a&gt; has added an &amp;quot;itemRendererFunction&amp;quot; function that allows certain data containers to specify an itemRenderer based on the data item. In this example an FxDataContainer&apos;s dataProvider is set to an ArrayCollection that contains 2 different types of Value Objects. Depending on the type of Value Object the 
itemRendererFunction returns a different itemRenderer.&lt;/p&gt;

&lt;p style=&quot;margin-left:20px;&quot;&gt;
	
    &lt;a href=&quot;http://www2.themorphicgroup.net/projects/examples/itemrendererfunction&quot;&gt;&lt;img src=&quot;http://www2.themorphicgroup.net/projects/examples/img/itemRendererFunction.png&quot; width=&quot;200&quot; height=&quot;149&quot; alt=&quot;&quot; style=&quot;border:none;&quot; /&gt;&lt;/a&gt;
&lt;br /&gt;
    &lt;a href=&quot;http://www2.themorphicgroup.net/projects/examples/itemrendererfunction&quot;&gt;&lt;strong&gt;View Example&lt;/strong&gt; (right click for source)&lt;/a&gt; 
&lt;/p&gt;
&lt;p&gt;In this example there are two different Value Objects: PhotoVO and QuoteVO. An FxDataContainer&apos;s dataProvider is set to an ArrayCollection:&lt;/p&gt;
&lt;pre&gt;
[Bindable]private var VODataProvider:ArrayCollection;

&amp;lt;FxDataContainer dataProvider=&quot;{VODataProvider}&quot;...
&lt;/pre&gt;

&lt;p&gt;
	The ArrayCollection is populated with 5 Value Objects, 2 PhotoVO and 3 QuoteVO.
&lt;/p&gt;
&lt;p&gt;In the FxDataContainer the itemRendererFunction is set to a function:&lt;/p&gt;
&lt;pre&gt;&amp;lt;FxDataContainer dataProvider=&quot;{VODataProvider}&quot; 

	itemRendererFunction=&quot;itemRendererFunction_handler&quot;
&lt;/pre&gt;
&lt;p&gt;In the itemRendererFunction a ClassFactory is passed back based on the type of data item in the itemRenderer. In this example there is a different itemRenderer for the PhotoVO and QuoteVO. We will also pass in a function to the itemRenderer to handle clicks:&lt;/p&gt;
&lt;pre&gt;
private function itemRendererFunction_handler(item:Object):ClassFactory {

	var classFactory:ClassFactory;

	if (item is PhotoVO) {

		//item is PhotoVO so use Photo ItemRenderer

		classFactory = new ClassFactory(PhotoItemRenderer);

	} else if (item is QuoteVO) {

		//item is QuoteVO so use Quote ItemRenderer

		classFactory = new ClassFactory(QuoteItemRenderer);

	}

	//pass callback click function

	classFactory.properties = {clickFunction:itemRenderClick_handler};

	return classFactory;

}
&lt;/pre&gt;

&lt;p&gt;
&lt;a href=&quot;http://www2.themorphicgroup.net/projects/examples/itemrendererfunction&quot;&gt;View Example&lt;/a&gt; with source enabled (flash 10 required)
&lt;/p&gt; 
				</description>
				
				<category>Flex</category>				
				
				<category>Gumbo</category>				
				
				<pubDate>Wed, 03 Dec 2008 10:16:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2008/12/3/itemRendererFunction</guid>
				
			</item>
			
			<item>
				<title>Gumbo and Catalyst Photo Viewer Application</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2008/12/3/GumboCatalystPhotoViewerApplication</link>
				<description>
				
				&lt;p&gt;I&apos;ve posted an example of a Flex application created with the MAX preview versions of Flash Catalyst and Gumbo. This small demo application was created to test out some of the new features in both Catalyst and Gumbo. It is not a perfect project, but a starting point for further projects.&lt;/p&gt;

&lt;p style=&quot;20px;&quot;&gt;
	&lt;a href=&quot;http://www2.themorphicgroup.com/projects/catalystgumbophoto/&quot; target=&quot;_blank&quot;&gt;&lt;img src=&quot;http://www2.themorphicgroup.com/projects/examples/img/gumbo_app.png&quot; width=&quot;215&quot; height=&quot;157&quot; alt=&quot;Gumbo Catalyst Photo Application&quot; border=&quot;none&quot; /&gt;&lt;/a&gt;
    &lt;br /&gt;
    &lt;a href=&quot;http://www2.themorphicgroup.com/projects/catalystgumbophoto/&quot; target=&quot;_blank&quot;&gt;&lt;strong&gt;View Example&lt;/strong&gt; (right click for source)&lt;/a&gt;
&lt;/p&gt;


&lt;p&gt;The main goal of this project was to play with the new features in Catalyst and Gumbo using a close to real world example application, here is what was done:&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;Start with a photoshop layout (PhotoShop file located in PSD directory)&lt;/li&gt;
  &lt;li&gt;Use Catalyst to layout/components/skins and export FXG project&lt;/li&gt;
  &lt;li&gt;Import FXG to Gumbo project&lt;/li&gt;
  &lt;li&gt;In Gumbo add data/photo/etc functionality to the project&lt;/li&gt;
  &lt;li&gt;Take project back to Catalyst for small visual edits, then back to Gumbo&lt;/li&gt;
  &lt;li&gt;Use new Gumbo MXML tags/components&lt;/li&gt;
  &lt;li&gt;Play with new __AS3__.vec.Vector (using the new BitmapData.histogram)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;
	Instead of detailing every step of the process there is great &lt;a href=&quot;http://opensource.adobe.com/wiki/display/flexsdk/Gumbo#Gumbo-DocumentsandSpecifications&quot; target=&quot;_blank&quot;&gt;Gumbo Documentation&lt;/a&gt; and &lt;a href=&quot;http://thermoteamblog.com/category/started/&quot; target=&quot;_blank&quot;&gt;Catalyst Examples&lt;/a&gt;.
&lt;/p&gt;

&lt;p&gt;
	&lt;a href=&quot;http://www2.themorphicgroup.com/projects/catalystgumbophoto/&quot; target=&quot;_blank&quot;&gt;&lt;strong&gt;View Catalyst and Gumbo Photo Application&lt;/strong&gt;&lt;/a&gt; (requires Flash 10 player)
&lt;/p&gt; 
				</description>
				
				<category>Flex</category>				
				
				<category>Photography</category>				
				
				<category>Gumbo</category>				
				
				<pubDate>Wed, 03 Dec 2008 10:15:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2008/12/3/GumboCatalystPhotoViewerApplication</guid>
				
			</item>
			
			<item>
				<title>Introduction to MVC at November Sacramento ColdFusion User Group</title>
				<link>http://www.leavethatthingalone.com/blog/index.cfm/2008/11/8/saccfugNovember2008Meeting</link>
				<description>
				
				&lt;p&gt;
Sacramento ColdFusion User Group meets November 11th, this month &lt;a href=&quot;http://www.southofshasta.com/blog/index.cfm&quot;&gt;Nolan Erck&lt;/a&gt; will be giving a presentation on &quot;Introduction to Model View Controllers in ColdFusion&quot;.  He will go over the basics of what MVC does, pros and cons, and give an introductory look at some code that uses this pattern.

&lt;/p&gt;
&lt;p&gt;
This will be a non-framework-specific talk.  No prior knowledge of Model-Glue, Mach-ii, etc required; none of the code samples will use a framework.  However, some basic knowledge of CFCs will probably help tremendously
&lt;/p&gt; 


&lt;p&gt;
For more information and directions visit &lt;a href=&quot;http://www.saccfug.com&quot;&gt;&lt;strong&gt;www.saccfug.com&lt;/strong&gt;&lt;/a&gt;
&lt;/p&gt; 
				</description>
				
				<category>ColdFusion</category>				
				
				<category>SacCFUG</category>				
				
				<pubDate>Sat, 08 Nov 2008 09:03:00 -0400</pubDate>
				<guid>http://www.leavethatthingalone.com/blog/index.cfm/2008/11/8/saccfugNovember2008Meeting</guid>
				
			</item>
			</channel></rss>
