1 <?xml version="1.0" encoding="utf-8"?>
3 xmlns:fx="http://ns.adobe.com/mxml/2009"
4 xmlns:s="library://ns.adobe.com/flex/spark">
8 paddingLeft="5" paddingRight="5"
9 paddingTop="5" paddingBottom="5"/>
12 <s:List width="100%" height="100%" id="background"
14 change="FlexGlobals.topLevelApplication.bgButton.close(); application.theMap.tileset.setBackgroundFromImagery(background.selectedItem,true);"
15 dataProvider="{Imagery.instance().getAvailableImagery(application.theMap)}"
16 maxHeight="{this.screen.height-120}"
17 selectedItem="{application.theMap.tileset.selected}">
19 <s:VerticalLayout requestedRowCount="{Imagery.instance().getAvailableImagery(application.theMap).length}" gap="0" horizontalAlign="contentJustify"/>
23 <s:HGroup width="100%" horizontalAlign="center">
24 <s:CheckBox label="Dim" selected="{application.theMap.getDimming()}" id="dim"
25 change="setDimming(dim.selected)" />
26 <s:CheckBox label="Sharpen" selected="{application.theMap.getSharpen()}" id="sharpen"
27 change="setSharpen(sharpen.selected)" />
30 <s:HGroup width="100%" horizontalAlign="center">
31 <s:CheckBox label="Show floating window" id="showFloatingMap" selected="{application.floatingMap.visible}"
32 change="application.floatingMap.setFloatingMapVisible(showFloatingMap.selected);FlexGlobals.topLevelApplication.bgButton.close();" />
35 <s:HGroup horizontalAlign="center">
36 <s:Button id="editLabel" label="Edit..." click="FlexGlobals.topLevelApplication.bgButton.close(); new BackgroundDialog().init('Background imagery',background,Imagery.instance());" />
37 <s:Button label="Vector file..." click="FlexGlobals.topLevelApplication.bgButton.close(); new VectorSourceDialog().init();" />
42 import net.systemeD.halcyon.*;
43 import net.systemeD.halcyon.connection.*;
44 import net.systemeD.potlatch2.*;
45 import net.systemeD.potlatch2.dialogs.*;
46 import net.systemeD.potlatch2.collections.Imagery;
48 import mx.collections.ArrayCollection;
49 import mx.managers.PopUpManager;
51 [Bindable] private var application:Object = FlexGlobals.topLevelApplication;
53 public function setDimming(v:Boolean):void {
54 FlexGlobals.topLevelApplication.theMap.setDimming(dim.selected);
55 var obj:SharedObject=SharedObject.getLocal("user_state","/");
56 obj.setProperty('background_dim',v);
57 try { obj.flush(); } catch (e:Error) {}
59 public function setSharpen(v:Boolean):void {
60 FlexGlobals.topLevelApplication.theMap.setSharpen(sharpen.selected);
61 var obj:SharedObject=SharedObject.getLocal("user_state","/");
62 obj.setProperty('background_sharpen',v);
63 try { obj.flush(); } catch (e:Error) {}