<?xml version="1.0" encoding="utf-8"?>
<s:View xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark" title="Sample ToggleSwitch" xmlns:components="components.*">
<fx:Script>
<![CDATA[
import views.SnippetView;
]]>
</fx:Script>
<s:navigationContent>
<s:Button label="Snippet" click="navigator.pushView(views.SnippetView,data)"/>
<s:Button label="Tutorial" click="navigateToURL(new URLRequest(data.tutorial))"/>
</s:navigationContent>
<s:layout>
<s:VerticalLayout paddingTop="100" paddingBottom="5" paddingLeft="5" paddingRight="5" gap="30"
horizontalAlign="center"/>
</s:layout>
<s:Label text="Toggle Settings"/>
<s:HGroup verticalAlign="middle">
<s:Label text="Wifi"/>
<s:ToggleSwitch id="switch1" selected="true" slideDuration="100"/>
<s:Label text="{switch1.selected}"/>
</s:HGroup>
<s:HGroup verticalAlign="middle">
<s:Label text="Port 80"/>
<s:ToggleSwitch id="switch2"/>
<s:Label text="{switch2.selected}"/>
</s:HGroup>
<components:QuestionBlock bottom="40" horizontalCenter="0" questionData="{data}"/>
</s:View>