[rnbrowse-commits] SF.net SVN: rnbrowse:[159] branches/RNBGUI/src/RNBGUI.mxml
Brought to you by:
cjsoftuk
|
From: <dav...@us...> - 2008-08-03 09:31:31
|
Revision: 159
http://rnbrowse.svn.sourceforge.net/rnbrowse/?rev=159&view=rev
Author: davidisofox
Date: 2008-08-03 09:31:28 +0000 (Sun, 03 Aug 2008)
Log Message:
-----------
Removed Paths:
-------------
branches/RNBGUI/src/RNBGUI.mxml
Deleted: branches/RNBGUI/src/RNBGUI.mxml
===================================================================
--- branches/RNBGUI/src/RNBGUI.mxml 2008-08-03 08:04:03 UTC (rev 158)
+++ branches/RNBGUI/src/RNBGUI.mxml 2008-08-03 09:31:28 UTC (rev 159)
@@ -1,409 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" verticalScrollPolicy="off" horizontalScrollPolicy="off" layout="absolute" creationComplete="rnb4_gui::initAll(); setHints(new TimerEvent(TimerEvent.TIMER_COMPLETE));" themeColor="#009dff" xmlns:controls="controls.*" viewSourceURL="srcview/index.html">
- <mx:states>
- <mx:State name="Slideshow">
- <mx:AddChild relativeTo="{vbox1}" position="firstChild">
- <mx:Canvas id="slideshowcanvas" bottom="196" top="0" left="0" right="0">
- <mx:Canvas width="100%" height="100%">
- <mx:Canvas backgroundAlpha="0.2" x="0" y="0" width="100%" height="100%" id="ssPicCont" showEffect="{fadeAndBlurIn}" hideEffect="{fadeAndBlurOut}" visible="false">
- <mx:Image x="0" y="0" width="100%" height="100%" id="ssPic" verticalAlign="center" horizontalAlign="middle" cacheAsBitmap="true" />
- </mx:Canvas>
- <mx:Canvas backgroundAlpha="0.2" x="0" y="0" width="100%" height="100%" id="ssPicCont2" showEffect="{fadeAndBlurIn}" hideEffect="{fadeAndBlurOut}" visible="false">
- <mx:Image x="0" y="0" width="100%" height="100%" id="ssPic2" verticalAlign="center" horizontalAlign="middle" cacheAsBitmap="true" />
- </mx:Canvas>
- </mx:Canvas>
- <mx:Canvas backgroundAlpha="0.2" width="100%" height="100%" id="preload" showEffect="{fadeAndBlurIn}" hideEffect="{fadeAndBlurOut}">
- <mx:Box width="100%" height="100%" verticalAlign="center">
- <mx:ProgressBar id="preloadBar" width="100%" complete="ssPreloadComplete()" labelPlacement="bottom" />
- </mx:Box>
- </mx:Canvas>
- </mx:Canvas>
- </mx:AddChild>
- <mx:RemoveChild target="{linkbar1}"/>
- <mx:SetEventHandler target="{linkbutton1}" name="click" handler="currentState=''"/>
- <mx:SetProperty target="{linkbutton1}" name="label" value="Browser"/>
- <mx:AddChild relativeTo="{hbox1}" position="lastChild">
- <mx:Button label="Start" click="ssStart()" icon="@Embed(source='../images/control_play_blue.png')" width="73" height="22"/>
- </mx:AddChild>
- <mx:AddChild relativeTo="{hbox1}" position="lastChild">
- <mx:Button label="Previous" click="ssPrev()" icon="@Embed(source='../images/control_start_blue.png')" width="94" height="22"/>
- </mx:AddChild>
- <mx:AddChild relativeTo="{hbox1}" position="lastChild">
- <mx:Button label="Next" click="ssNext()" icon="@Embed(source='../images/control_end_blue.png')" width="71" height="22"/>
- </mx:AddChild>
- <mx:AddChild relativeTo="{hbox1}" position="lastChild">
- <mx:Button label="Stop" click="ssStop()" id="button3" icon="@Embed(source='../images/control_stop_blue.png')" width="70" height="22"/>
- </mx:AddChild>
- <mx:AddChild relativeTo="{hbox1}" position="lastChild">
- <mx:Label text="[picname]" id="file" />
- </mx:AddChild>
- <mx:RemoveChild target="{pbStatus}"/>
- <mx:RemoveChild target="{btnUpload}"/>
- <mx:SetStyle target="{hbox2}" name="left" value="0"/>
- <mx:SetStyle target="{files}" name="top"/>
- <mx:SetProperty target="{files}" name="height" value="100"/>
- </mx:State>
- </mx:states>
- <mx:transitions>
- <mx:Transition fromState="*" toState="Slideshow">
- <mx:Parallel targets="{[files, linkbar1, slideshowcanvas, hbox2]}">
- <mx:Move target="{files}" duration="2000" />
- <mx:Resize target="{files}" duration="2000" />
- <mx:Move target="{hbox2}" duration="2000" />
- <mx:Resize target="{hbox2}" duration="2000" />
- <mx:Fade target="{linkbar1}" alphaFrom="1.0" alphaTo="0.0" duration="2000"/>
- <mx:Fade target="{slideshowcanvas}" alphaFrom="0.0" alphaTo="1.0" duration="2000"/>
- </mx:Parallel>
- </mx:Transition>
-
- <mx:Transition fromState="Slideshow" toState="*">
- <mx:Parallel targets="{[files, linkbar1, slideshowcanvas, hbox2]}">
- <mx:Move target="{files}" duration="2000" />
- <mx:Resize target="{files}" duration="2000" />
- <mx:Move target="{hbox2}" duration="2000" />
- <mx:Resize target="{hbox2}" duration="2000" />
- <mx:Fade target="{linkbar1}" alphaFrom="0.0" alphaTo="1.0" duration="2000"/>
- <mx:Fade target="{slideshowcanvas}" alphaFrom="1.0" alphaTo="0.0" duration="2000"/>
- </mx:Parallel>
- </mx:Transition>
- </mx:transitions>
- <mx:Style source="style.css" />
- <mx:Script>
- <![CDATA[
- import mx.controls.Alert;
- import mx.effects.IEffect;
- import mx.events.CloseEvent;
- [Embed(source="../images/folder.png")]
- [Bindable]
- public var FolderImage:Class;
-
-
- [Embed(source="../images/folder_open.png")]
- [Bindable]
- public var FolderOpenImage:Class;
-
-
- [Embed(source="../images/exclamation.png")]
- [Bindable]
- public var exclamation:Class;
-
-
- [Embed(source="../images/information.png")]
- [Bindable]
- public var information:Class;
-
-
- namespace rnb4_gui;
- //titlewindowshow
- import mx.managers.PopUpManager;
- import mx.containers.TitleWindow;
- rnb4_gui var contexts:ArrayCollection;
- rnb4_gui var loginwin:loginwindow;
- rnb4_gui var buildzipwin:buildzip;
- rnb4_gui var logInitWindow:evtVwrLoader;
- rnb4_gui var logsWindow:logViewer;
-
- // Open the TitleWindow container.
- // Cast the return value of the createPopUp() method
- // to loginwindow, the name of the
- // component containing the TitleWindow container.
-
- private function initLogViewer():void
- {
- rnb4_gui::logInitWindow = evtVwrLoader(PopUpManager.createPopUp( this, evtVwrLoader, true));
- PopUpManager.centerPopUp(rnb4_gui::logInitWindow);
- }
-
- private function showLogs():void {
- rnb4_gui::logsWindow=logViewer(PopUpManager.createPopUp( this, logViewer, true));
- rnb4_gui::logsWindow.instanceRef = rnb4_gui::logsWindow;
- rnb4_gui::logsWindow.updateLog(null);
- PopUpManager.centerPopUp(rnb4_gui::logsWindow);
- // Pass a reference to the TextInput control
- // to the TitleWindow container so that the
- // TitleWindow container can return data to the main application.
- }
-
- private function showZipWindow():void {
- rnb4_gui::buildzipwin=buildzip(PopUpManager.createPopUp( this, buildzip, true));
- PopUpManager.centerPopUp(rnb4_gui::buildzipwin);
- // Pass a reference to the TextInput control
- // to the TitleWindow container so that the
- // TitleWindow container can return data to the main application.
- }
-
- rnb4_gui function showWindow():void {
- rnb4_gui::loginwin=loginwindow(PopUpManager.createPopUp( this, loginwindow , true));
- PopUpManager.centerPopUp(rnb4_gui::loginwin);
- rnb4_gui::loginwin["buttonLogin"].addEventListener("click", doLogin);
- rnb4_gui::loginwin["textboxContext"].dataProvider=contexts;
- rnb4_api::getContexts();
- // Pass a reference to the TextInput control
- // to the TitleWindow container so that the
- // TitleWindow container can return data to the main application.
- }
-
- [Bindable]
- public var hints:ArrayCollection = new ArrayCollection(
- [ "Did you know: You can change the colour of RNBrowser under Settings -> Styler",
- "Did you know: You can click slideshow to view all photos in the selected folder as a slideshow",
- "Other (Item 3)",
- "Other (Item 4)",
- "Other (Item 5)",
- "Other (Item 6)",
- "Other (Item 7)",
- "Other (Item 8)",
- "Other (Item 9)",
- "Other (Item 10)",
- "Other (Item 11)",
- "Other (Item 12)",
- "Other (Item 13)",]);
-
- [Bindable]
- public var themes:ArrayCollection = new ArrayCollection(
- [ "bright",
- "simple",
- "dark",]);
-
- private var t:Timer = new Timer(120000, 1);
- private function setHints(evt:TimerEvent):void {
- t.stop();
- var a:int;
- a = Math.random() * 100;
- a = (a / 100) * (hints.length - 1);
- hintstext.text = hints.getItemAt(a).toString();
- if (t.hasEventListener(TimerEvent.TIMER_COMPLETE) == false)
- {
- t.addEventListener(TimerEvent.TIMER_COMPLETE, setHints);
- }
- t.start();
- }
-
- // Event handler for the OK button.
- private function doLogin(evt:Event):void {
- var loginName:String;
- var password:String;
- if (rnb4_gui::loginwin.textboxContext.text == "")
- {
- loginName = rnb4_gui::loginwin.textboxUsername.text
- }
- else
- {
- if (rnb4_gui::loginwin.textboxContext.text.charAt(0) == ".")
- {
- loginName = rnb4_gui::loginwin.textboxUsername.text + rnb4_gui::loginwin.textboxContext.text;
- }else{
- loginName = rnb4_gui::loginwin.textboxUsername.text + "." + rnb4_gui::loginwin.textboxContext.text;
- }
- }
- loginName = rnb4_gui::loginwin.textboxUsername.text + rnb4_gui::loginwin.textboxContext.text;
- password = rnb4_gui::loginwin.textboxPassword.text;
- login(loginName,password)
- PopUpManager.removePopUp(rnb4_gui::loginwin);
- }
-
- private function stylerApply():void {
- try {
- if (themecolorradio.selected==true){
- mx.styles.StyleManager.unloadStyleDeclarations("bright.swf");
- mx.styles.StyleManager.unloadStyleDeclarations("simple.swf");
- resetTheme();
- updateTheme();
- }else if(this.themeradio.selected==true){
- mx.styles.StyleManager.unloadStyleDeclarations("bright.swf");
- mx.styles.StyleManager.unloadStyleDeclarations("simple.swf");
- resetTheme();
- mx.styles.StyleManager.loadStyleDeclarations(themecombobox.text + ".swf");
- }else{
- mx.styles.StyleManager.unloadStyleDeclarations("bright.swf");
- mx.styles.StyleManager.unloadStyleDeclarations("simple.swf");
- resetTheme();
- }
- mx.controls.Alert.show('Save Succeeded', 'Saved', 4, this, null, this.information, 4);
- }
- catch (e:Error) {
- mx.controls.Alert.show("Save failed", "Error", 4, this, null, this.exclamation, 4);
- }
- }
- ]]>
- </mx:Script>
- <mx:Script source="rnbGui_codebehind.as" />
- <mx:Script source="upload.as" />
- <mx:Script source="rnbMain.as" />
-
- <mx:Script>
- <![CDATA[
- import mx.collections.ArrayCollection;
-
- [Bindable]
- public var filetypes:ArrayCollection = new ArrayCollection(
- [ {label:".zip", data:1},
- {label:".tgz", data:2} ]);
-
- [Bindable]
- public var speeds:ArrayCollection = new ArrayCollection(
- [ {label:"56Kbps", data:56},
- {label:"128Kbps", data:128},
- {label:"256Kbps", data:256},
- {label:"512Kbps", data:512},
- {label:"1Mbps", data:1024},
- {label:"2Mbps", data:2048},
- {label:"4Mbps", data:4096},
- {label:"8Mbps", data:8192},
- {label:"16Mbps", data:16384},
- {label:"24Mbps", data:24576},
- {label:"LAN", data:49152} ]);
-
- rnb4_gui function resetView():void
- {
- viewstack1.selectedIndex=0;
- logdata.dataProvider=null;
- files.dataProvider=null;
- dirs.dataProvider=null;
- txtAddrBar.text="";
- }
- ]]>
- </mx:Script>
- <mx:Sequence id="fadeAndBlurIn" startDelay="0" >
- <mx:Fade id="fadeIn" duration="1200" alphaFrom="0.0" alphaTo="1.0" />
- </mx:Sequence>
- <mx:Sequence id="fadeAndBlurOut" startDelay="0">
- <mx:Fade id="fadeOut" duration="300" alphaFrom="1.0" alphaTo="0" />
- </mx:Sequence>
- <mx:ApplicationControlBar x="197" y="58" dock="true" height="37" id="appcontrol">
- <mx:Canvas height="100%" width="100%">
- <mx:LinkBar dataProvider="{viewstack1}" id="linkbar1"/>
- <mx:LinkButton label="Slideshow" click="currentState='Slideshow'; viewstack1.selectedIndex = 0; files.maxRows = 1; inSSMode=!inSSMode;" id="linkbutton1" right="91" y="2" width="75"/>
- <mx:Button label="Logout" click="logout(); resetView();" y="2" right="0" icon="@Embed(source='../images/door.png')"/>
- <mx:HBox left="210" right="174" top="0" bottom="0" id="hbox2" backgroundColor="#F6FF91" cornerRadius="1" borderColor="#000000" borderStyle="solid" borderThickness="1" verticalAlign="middle" horizontalAlign="left">
- <mx:Spacer width="0" height="0"/>
- <mx:Image width="16" height="16" source="@Embed('../images/information.png')" />
- <mx:Label text="[Hints/Tips]" id="hintstext"/>
- </mx:HBox>
- </mx:Canvas>
- </mx:ApplicationControlBar>
- <mx:TextInput height="22" left="-1" top="0" right="-1" styleName="addressbar" id="txtAddrBar"/>
- <mx:Button id='btnGo' click="addrNav()" width="22" height="22" right="-1" top="0" styleName="addressbar" icon="@Embed(source='../images/arrow_right.png')"/>
- <mx:ViewStack id="viewstack1" right="10" left="10" top="32" bottom="10">
- <mx:HDividedBox label="File Browser" width="100%" height="100%">
- <mx:Tree id='dirs' folderClosedIcon="{FolderImage}" folderOpenIcon="{FolderImage}" defaultLeafIcon="{FolderImage}" top="0" bottom="0" left="0" width="206" showRoot="false" itemRenderer="RNBGUI.RNBRenderer" itemClick="itemClickEvt(event);" itemOpen="itemOpenEvt(event);" height="100%"></mx:Tree>
- <mx:Canvas width="100%" height="100%" id="vbox1">
- <mx:TileList doubleClickEnabled="true" top="0" bottom="88" right="0" itemRenderer="FileViewRender" id="files" allowMultipleSelection="true" left="0"/>
- <mx:VBox height="80" styleName="upload" id="vbox2" bottom="0" left="0" right="0">
- <mx:HBox id="hbox1" verticalAlign="middle" height="22">
- <mx:Button label="Upload" id="btnUpload" click="asUpload();" icon="@Embed(source='../images/arrow_up.png')" width="83" height="22"/>
- <mx:ProgressBar id='pbStatus' labelPlacement="center" height="22" width="131" label=" " mode="manual" indeterminate="false"/>
- </mx:HBox>
- <mx:HBox height="22">
- <mx:Button label="Download All Files" id="btnDLAll" icon="@Embed(source='../images/package.png')" click="asDLFolder();" width="147" height="22"/>
- <mx:Button label="Download Selected" icon="@Embed(source='../images/arrow_down.png')" id="btnDlSel" click="asDLSelFiles();" width="152" height="22"/>
- </mx:HBox>
- <mx:Button label="Delete Selected" id="button1" icon="@Embed(source='../images/cross.png')" height="22" width="134"/>
- </mx:VBox>
- </mx:Canvas>
- </mx:HDividedBox>
- <mx:Canvas label="Tools" width="100%" height="100%">
- <mx:ToggleButtonBar dataProvider="{viewstack2}" top="0" left="0"/>
- <mx:ViewStack id="viewstack2" left="10" right="10" bottom="10" top="30">
- <mx:Canvas label="Log viewer" width="100%" height="100%">
- <mx:Panel x="0" y="0" width="100%" height="100%" layout="absolute" title=" Log Viewer">
- <mx:AdvancedDataGrid id="logdata" designViewDataType="flat" left="10" top="10" bottom="50" right="10" editable="false" enabled="true">
- <mx:columns>
- <mx:AdvancedDataGridColumn width="180" headerText="Username" dataField="user"/>
- <mx:AdvancedDataGridColumn width="100" headerText="IP Address" dataField="ip"/>
- <mx:AdvancedDataGridColumn width="175" headerText="Time/Date" dataField="timestamp"/>
- <mx:AdvancedDataGridColumn width="120" headerText="Event type" dataField="type"/>
- <mx:AdvancedDataGridColumn headerText="Details" dataField="details"/>
- </mx:columns>
- </mx:AdvancedDataGrid>
- <mx:Button right="10" bottom="10" label="Reload" click="rnb4_api::getEventLog();"/>
- </mx:Panel>
- <mx:Image width="16" height="16" source="@Embed('../images/book.png')" x="10" y="7"/>
- </mx:Canvas>
- <mx:Canvas label="Styler" width="100%" height="100%">
- <mx:Panel layout="absolute" width="100%" height="100%" title=" Styler" creationComplete="themecolour.enabled = themecolorradio.selected; themecombobox.enabled = themeradio.selected; backcolour.enabled = themecolorradio.selected; csstext.enabled = cssradio.selected;">
- <mx:RadioButtonGroup id="radiogroup1" change="themecolour.enabled = themecolorradio.selected; themecombobox.enabled = themeradio.selected; backcolour.enabled = themecolorradio.selected; csstext.enabled = cssradio.selected;"/>
- <mx:VBox left="10" top="10" bottom="10" right="10">
- <mx:HBox width="100%">
- <mx:RadioButton label="Default" groupName="radiogroup1" width="110" selected="true"/>
- </mx:HBox>
- <mx:HBox width="100%" verticalAlign="middle">
- <mx:RadioButton label="Custom Color" id="themecolorradio" groupName="radiogroup1" width="110"/>
- <mx:Label text="Background Colour:"/>
- <mx:ColorPicker id="backcolour" color="#CCCCCC"/>
- <mx:Label text="Theme Colour:"/>
- <mx:ColorPicker id="themecolour" color="#CCCCCC"/>
- </mx:HBox>
- <mx:HBox width="100%">
- <mx:RadioButton label="Custom Theme" id="themeradio" groupName="radiogroup1" width="110" enabled="true"/>
- <mx:ComboBox id="themecombobox" editable="false" enabled="true" width="273" dataProvider="{themes}"/>
-
- </mx:HBox>
- <mx:HBox width="100%" height="100%">
- <mx:RadioButton label="Custom CSS" id="cssradio" groupName="radiogroup1" width="110" enabled="false"/>
- <mx:TextArea id="csstext" width="100%" height="100%"/>
- </mx:HBox>
- </mx:VBox>
- <mx:ControlBar horizontalAlign="right">
- <mx:Button label="Cancel" icon="@Embed(source='../images/cross.png')" labelPlacement="left"/>
- <mx:Button label="Save" labelPlacement="left" click="//stylerApply();" icon="@Embed(source='../images/disk.png')"/>
- </mx:ControlBar>
- </mx:Panel>
- <mx:Image width="16" height="16" source="@Embed('../images/color_swatch.png')" x="10" y="7"/>
- </mx:Canvas>
- <mx:Canvas label="Other" width="100%" height="100%">
- <mx:Panel layout="absolute" width="100%" height="100%" title=" Other" creationComplete="themecolour.enabled = themecolorradio.selected; backcolour.enabled = themecolorradio.selected; csstext.enabled = cssradio.selected;">
- <mx:VBox left="10" right="10" bottom="10" top="10">
- </mx:VBox>
-
- <mx:ControlBar horizontalAlign="right">
- <mx:Button label="Cancel" icon="@Embed(source='../images/cross.png')" labelPlacement="left"/>
- <mx:Button label="Save" labelPlacement="left" icon="@Embed(source='../images/disk.png')"/>
- </mx:ControlBar>
- </mx:Panel>
- <mx:Image width="16" height="16" source="@Embed('../images/color_swatch.png')" x="10" y="7"/>
- </mx:Canvas>
- </mx:ViewStack>
- </mx:Canvas>
- <mx:VBox label="About" width="100%" height="100%" verticalAlign="middle" horizontalAlign="center">
- <mx:Label fontSize="24" fontWeight="bold" text="Remote Network Browser 4"/>
- <mx:Label fontSize="10" fontWeight="bold" text="Version number 4.0.8"/>
- <mx:Spacer height="50" width="0"/>
- <mx:Grid width="415" horizontalCenter="0" verticalCenter="0">
- <mx:GridRow width="100%" height="100%">
- <mx:GridItem width="100%" height="100%" horizontalAlign="right" verticalAlign="middle">
- <mx:Label text="Flash UI and themes by"/>
- </mx:GridItem>
- <mx:GridItem width="100%" height="100%" verticalAlign="middle">
- <mx:LinkButton label="David Wood" width="100"/>
- </mx:GridItem>
- </mx:GridRow>
- <mx:GridRow width="100%" height="100%">
- <mx:GridItem width="100%" height="100%" horizontalAlign="right" verticalAlign="middle">
- <mx:Label text="ActionScript code-behind by"/>
- </mx:GridItem>
- <mx:GridItem width="100%" height="100%" verticalAlign="middle">
- <mx:LinkButton label="Chris Malton" width="100" click="navigateToURL(new URLRequest('http://www.cmalton.me.uk'), 'CJSoftUK');"/>
- </mx:GridItem>
- </mx:GridRow>
- <mx:GridRow width="100%" height="100%">
- <mx:GridItem width="100%" height="100%" horizontalAlign="right" verticalAlign="middle">
- <mx:Label text="PHP backend by"/>
- </mx:GridItem>
- <mx:GridItem width="100%" height="100%" verticalAlign="middle">
- <mx:LinkButton label="Chris Malton" width="100" click="navigateToURL(new URLRequest('http://www.cmalton.me.uk'), 'CJSoftUK');"/>
- </mx:GridItem>
- </mx:GridRow>
- <mx:GridRow width="100%" height="100%">
- <mx:GridItem width="100%" height="100%" horizontalAlign="right" verticalAlign="middle">
- <mx:Label text="Icons by"/>
- </mx:GridItem>
- <mx:GridItem width="100%" height="100%" verticalAlign="middle">
- <mx:LinkButton label="Mark James" width="100" click="navigateToURL(new URLRequest('http://www.famfamfam.com'), 'FAMFAMFAM');"/>
- </mx:GridItem>
- </mx:GridRow>
- </mx:Grid>
- <mx:Spacer height="115" width="0"/>
- </mx:VBox>
- </mx:ViewStack>
-</mx:Application>
\ No newline at end of file
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|