<?xml version="1.0" encoding="utf-8"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" xmlns="*" creationComplete="iFrame.visible=true; iFrame.source='http://www.adobeindia.com'" viewSourceURL="srcview/index.html" pageTitle="Flex-i-Frame"> <mx:Style source="app.css"/> <mx:XMLList id="treeData"> <node label="ADO Contest Resources"> <node label="ADO Home" path="http://adobeindia.com/ado/index.html" /> <node label="ADO FLEX Resources" path="http://www.adobeindia.com/ado/flex.html" /> <node label="ADO CF Resources" path="http://www.adobeindia.com/ado/coldfusion.html" /> <node label="Flex Samples" path="http://www.adobe.com/devnet/flex/?tab:samples=1" /> <node label="Adobe India Students Group" path="http://groups-beta.google.com/group/adobe-india-students" /> </node> <node label="Flex Blogs"> <node label="Ely Greenfield" path="http://quietlyscheming.com/blog" /> <node label="Manish Jethani" path="http://mannu.livejournal.com" /> <node label="Peter Ent" path="http://weblogs.macromedia.com/pent" /> <node label="Anjali Bharadwaj" path="http://flexarena.blogspot.com" /> <node label="Anant P N" path="http://www.ananth.info" /> </node> <node label="Getting Started PDFs"> <node label="Getting Started with Flex 2" path="http://www.adobe.com/go/flex2_gettingstarted_pdf" /> <node label="Flex 2 Developer's Guide" path="http://www.adobe.com/go/flex2_devapps_pdf" /> <node label="Building Flex 2 Applications" path="http://www.adobe.com/go/flex2_building_pdf" /> <node label="Extending Flex 2 Components" path="http://www.adobe.com/go/flex2_components_pdf" /> <node label="Programming ActionScript 3.0" path="http://www.adobe.com/go/programmingAS3_pdf" /> <node label="Using Flex Builder 2" path="http://www.adobe.com/go/flexbuilder2_using_pdf" /> </node> <node label="Search"> <node label="Google" path="http://www.google.com" /> <node label="Yahoo" path="http://www.yahoo.com" /> </node> </mx:XMLList> <mx:HBox width="100%" height="100%"> <mx:Panel title="Resource Tree" width="250" height="100%" roundedBottomCorners="true"> <mx:Tree id="tree" width="100%" height="100%" dataProvider="{treeData}" labelField="@label" showRoot="false" change="swfl.load(); ti.text = iFrame.source = (Tree(event.target).selectedItem.attribute('path').toString());" /> </mx:Panel> <mx:Panel width="100%" height="100%" title="Content Pane" paddingTop="1" paddingBottom="1" paddingLeft="1" paddingRight="1" > <mx:Canvas width="100%" height="100%"> <mx:SWFLoader x="0" y="0" id="swfl" verticalCenter="0" horizontalCenter="0" width="100%" height="100%" source="preloader.swf" autoLoad="true" scaleContent="true"/> <IFrame id="iFrame" x="0" y="0" width="100%" height="100%" > </IFrame> </mx:Canvas> <mx:ControlBar> <mx:HBox width="100%" height="100%"> <mx:TextInput id="ti" width="75%" text="http://www.adobeindia.com" enter="iFrame.source = ti.text"/> <mx:Button label="Load Page" click="iFrame.source = ti.text"/> </mx:HBox> </mx:ControlBar> </mx:Panel> </mx:HBox> </mx:Application>