<?xml version="1.0" encoding="UTF-8"?>
<window>
	<defaultcontrol always="true">9000</defaultcontrol>
	<menucontrol>9051</menucontrol>
	<onload>SetProperty(Window.HasSettings,True,home)</onload>
	<onload>ClearProperty(MediaMenu,Home)</onload>
	<onunload>ClearProperty(MediaMenu,Home)</onunload>
	<onunload>ClearProperty(Window.HasSettings,Home)</onunload>
	<onunload>Skin.Reset(Weather.Zoom.Detailed)</onunload>
	<onunload>Skin.Reset(Weather.Zoom.Alert)</onunload>
	
	<allowoverlay>no</allowoverlay>

	<include file="MyWeather-includes-data.xml" />

	<controls>
		<include>CommonBackground</include>
		<control type="group">
			<visible>!Skin.HasSetting(Enable.BasicWeatherView)</visible>
			<!-- <include>Animation.Common</include> -->
			<top>175</top>
			<!-- <control type="group"> -->
			<!-- <visible>Integer.IsGreater(Container(9000).NumItems,0)</visible> -->
			<!-- <control type="image"> -->
			<!-- <left>60</left> -->
			<!-- <top>10</top> -->
			<!-- <width>356</width> -->
			<!-- <height>95</height> -->
			<!-- <visible>Control.HasFocus(9000)</visible> -->
			<!-- <animation effect="fade" time="320" delay="200">Visible</animation> -->
			<!-- <animation effect="fade" time="50">Hidden</animation> -->
			<!-- <texture colordiffuse="FocusColor" border="5">listselect_fo.png</texture> -->
			<!-- <animation effect="slide" end="0,95" time="300" tween="cubic" easing="inout" condition="Integer.IsGreater(Container(9000).Row,6)">Conditional</animation> -->
			<!-- <animation effect="slide" end="0,95" time="300" tween="cubic" easing="inout" condition="Integer.IsGreater(Container(9000).Row,5)">Conditional</animation> -->
			<!-- <animation effect="slide" end="0,95" time="300" tween="cubic" easing="inout" condition="Integer.IsGreater(Container(9000).Row,4)">Conditional</animation> -->
			<!-- <animation effect="slide" end="0,95" time="300" tween="cubic" easing="inout" condition="Integer.IsGreater(Container(9000).Row,3)">Conditional</animation> -->
			<!-- <animation effect="slide" end="0,95" time="300" tween="cubic" easing="inout" condition="Integer.IsGreater(Container(9000).Row,2)">Conditional</animation> -->
			<!-- <animation effect="slide" end="0,95" time="300" tween="cubic" easing="inout" condition="Integer.IsGreater(Container(9000).Row,1)">Conditional</animation> -->
			<!-- <animation effect="slide" end="0,95" time="300" tween="cubic" easing="inout" condition="Integer.IsGreater(Container(9000).Row,0)">Conditional</animation> -->
			<!-- </control> -->
			<!-- </control> -->
			<control type="panel" id="9000">
				<left>60</left>
				<top>10</top>
				<width>356</width>
				<height>800</height>
				<onleft>60</onleft>
				<onright condition="Container(9000).HasFocus(1)">300</onright>
				<onright condition="Container(9000).HasFocus(2)">301</onright>
				<onright condition="Container(9000).HasFocus(5)">304</onright>
				<onright condition="Container(9000).HasFocus(6)">310</onright>
				<onright condition="Container(9000).HasFocus(11)">307</onright>
				<onright condition="Container(9000).HasFocus(12)">308</onright>
				<onup>9000</onup>
				<ondown>9000</ondown>
				<pagecontrol>60</pagecontrol>
				<!-- <scrolltime tween="quadratic">300</scrolltime> -->
				<itemlayout height="95" width="356">
					<control type="label">
						<width>356</width>
						<height>95</height>
						<font>font15</font>
						<textoffsetx>20</textoffsetx>
						<selectedcolor>SelectedColor</selectedcolor>
						<align>right</align>
						<label>$INFO[ListItem.Label]</label>
					</control>
				</itemlayout>
				<focusedlayout height="95" width="356">
					<control type="image">
						<texture colordiffuse="FocusColor" border="5">listselect_fo.png</texture>
					</control>
					<control type="label">
						<width>356</width>
						<height>95</height>
						<font>font15</font>
						<textoffsetx>20</textoffsetx>
						<selectedcolor>SelectedColor</selectedcolor>
						<align>right</align>
						<label>$INFO[ListItem.Label]</label>
					</control>
				</focusedlayout>
				<content>
					<item id="1">
						<label>31300</label>
						<icon />
					</item>
					<item id="12">
						<label>90910</label>
						<icon />
						<visible>!String.IsEmpty(Window.Property(Alerts.IsFetched))</visible>
					</item>
					<item id="2">
						<label>31904</label>
						<icon />
						<visible>!String.IsEmpty(Window.Property(Daily.IsFetched))</visible>
					</item>
					<item id="11">
						<label>90911</label>
						<icon />
						<visible>!String.IsEmpty(Window.Property(Detailed.IsFetched))</visible>
					</item>
					<item id="3">
						<label>31901</label>
						<icon />
						<visible>!String.IsEmpty(Window.Property(36Hour.IsFetched))</visible>
					</item>
					<item id="4">
						<label>31903</label>
						<icon />
						<visible>!String.IsEmpty(Window.Property(Weekend.IsFetched))</visible>
					</item>
					<item id="5">
						<label>31902</label>
						<icon />
						<visible>!String.IsEmpty(Window.Property(Hourly.IsFetched))</visible>
					</item>
					<item id="6">
						<label>33035</label>
						<icon />
						<visible>!String.IsEmpty(Window.Property(Map.IsFetched))</visible>
					</item>
				</content>
			</control>
			<control type="group" id="9001">

				<include file="MyWeather-includes-CurrentForecast.xml" condition="!String.IsEmpty(Window.Property(Current.IsFetched))">CurrentForecast</include>

				<include file="MyWeather-includes-Alerts.xml" condition="!String.IsEmpty(Window.Property(Alerts.IsFetched))">Alerts</include>

				<include file="MyWeather-includes-DailyForecast.xml" condition="!String.IsEmpty(Window.Property(Daily.IsFetched))">DailyForecast</include>

				<include file="MyWeather-includes-DetailedForecast.xml" condition="!String.IsEmpty(Window.Property(Detailed.IsFetched))">DetailedForecast</include>

				<include file="MyWeather-includes-36HourForecast.xml" condition="!String.IsEmpty(Window.Property(36Hour.IsFetched))">36HourForecast</include>

				<include file="MyWeather-includes-WeekendForecast.xml" condition="!String.IsEmpty(Window.Property(Weekend.IsFetched))">WeekendForecast</include>

				<include file="MyWeather-includes-HourlyForecast.xml" condition="!String.IsEmpty(Window.Property(Hourly.IsFetched))">HourlyForecast</include>

				<include file="MyWeather-includes-Maps.xml" condition="!String.IsEmpty(Window.Property(Map.IsFetched))">WeatherMaps</include>

			</control>

			<control type="image">
				<left>1350</left>
				<top>850</top>
				<width>500</width>
				<height>50</height>
				<aspectratio align="right" aligny="center">keep</aspectratio>
				<texture>$INFO[Window.Property(WeatherProviderLogo)]</texture>
			</control>
			<control type="group">
				<include>VisibleFadeEffect</include>
				<visible>Control.HasFocus(301) | Control.HasFocus(304)</visible>
				<height>890</height>
				<top>-55</top>
				<left>1155</left>
				<control type="label">
					<visible>[Control.HasFocus(301) + Container(301).HasPrevious] | [Control.HasFocus(304) + Container(304).HasPrevious]</visible>
					<width>30</width>
					<height>30</height>
					<align>center</align>
					<label>$VAR[Icon-ScrollUp]</label>
					<font>IconSmall</font>
					<textcolor>DisabledColor</textcolor>
				</control>
				<control type="label">
					<visible>[Control.HasFocus(301) + Container(301).HasNext] | [Control.HasFocus(304) + Container(304).HasNext]</visible>
					<top>860</top>
					<width>30</width>
					<height>30</height>
					<align>center</align>
					<label>$VAR[Icon-ScrollDown]</label>
					<font>IconSmall</font>
					<textcolor>DisabledColor</textcolor>
				</control>
			</control>
		</control>
		<control type="scrollbar" id="60">
			<visible>!Skin.HasSetting(Enable.BasicWeatherView)</visible>
			<left>0</left>
			<top>120</top>
			<width>10</width>
			<height>960</height>
			<onleft condition="!Skin.HasSetting(KioskMode.Enabled)">SetProperty(MediaMenu,True,home)</onleft>
			<onleft condition="!Skin.HasSetting(KioskMode.Enabled)">SetFocus(9050)</onleft>
			<onright>9000</onright>
		</control>

		<include file="MyWeather-includes-Basic.xml">BasicForecast</include>

		<include>Topbar</include>
		<control type="label">
			<left>100</left>
			<top>60</top>
			<width>900</width>
			<height>45</height>
			<font>font14</font>
			<textoffsetx>15</textoffsetx>
			<textcolor>NormalTextColor</textcolor>
			<label>$INFO[Window.Property(Location)] ($INFO[Window.Property(WeatherProvider)])</label>
		</control>
		<control type="group">
			<left>-440</left>
			<include>SideBladeLeft</include>
			<control type="grouplist" id="9050">
				<visible allowhiddenfocus="true">!Window.IsVisible(1134) + !Control.HasFocus(9013) + !Control.HasFocus(9014)</visible>
				<animation effect="slide" start="-440,0" end="0,0" time="400" tween="quadratic" easing="out">Visible</animation>
				<left>15</left>
				<top>0</top>
				<width>400</width>
				<height>1080</height>
				<onleft>9050</onleft>
				<onright>ClearProperty(MediaMenu,Home)</onright>
				<onright>9000</onright>
				<onup>9050</onup>
				<ondown>9050</ondown>
				<onback>ClearProperty(MediaMenu,Home)</onback>
				<onback>9000</onback>
				<itemgap>0</itemgap>
				<control type="label" id="200">
					<width>400</width>
					<height>60</height>
					<textoffsetx>15</textoffsetx>
					<font>font13_title</font>
					<label>31006</label>
					<textcolor>NormalTextColor</textcolor>
				</control>
				<control type="button" id="201">
					<description>Change weather location</description>
					<width>400</width>
					<font>font13</font>
					<label>--$INFO[Window.Property(Location)]--</label>
					<!-- <label>$INFO[Weather.Location]</label> -->
					<onclick>Weather.LocationNext</onclick>
				</control>
				<control type="button" id="202">
					<description>Select weather icons</description>
					<include>ButtonCommonValues</include>
					<label>31158</label>
					<onclick condition="System.HasAddon(script.image.resource.select)">RunScript(script.image.resource.select,property=weathericons&amp;type=resource.images.weathericons)</onclick>
					<onclick condition="!System.HasAddon(script.image.resource.select)">InstallAddon(script.image.resource.select)</onclick>
				</control>
				<control type="radiobutton" id="203">
					<description>Use Icons from Weather Provider</description>
					<include>ButtonCommonValues</include>
					<label>90912</label>
					<onclick>Skin.ToggleSetting(Enable.RemoteWeatherIcons)</onclick>
					<selected>Skin.HasSetting(Enable.RemoteWeatherIcons)</selected>
				</control>
				<control type="radiobutton" id="204">
					<description>Zoom Radar Images</description>
					<include>ButtonCommonValues</include>
					<label>90913</label>
					<onclick>Skin.ToggleSetting(Enable.ZoomRadar)</onclick>
					<selected>Skin.HasSetting(Enable.ZoomRadar)</selected>
				</control>
				<control type="button" id="205">
					<description>Select weather fanart</description>
					<include>ButtonCommonValues</include>
					<label>31171</label>
					<onclick condition="System.HasAddon(script.image.resource.select)">RunScript(script.image.resource.select,property=weatherfanart&amp;type=resource.images.weatherfanart)</onclick>
					<onclick condition="!System.HasAddon(script.image.resource.select)">InstallAddon(script.image.resource.select)</onclick>
				</control>
				<control type="radiobutton" id="206">
					<description>View Toggle</description>
					<include>ButtonCommonValues</include>
					<label>31507</label>
					<onclick>Skin.ToggleSetting(Enable.BasicWeatherView)</onclick>
					<selected>Skin.HasSetting(Enable.BasicWeatherView)</selected>
				</control>
				<control type="button" id="207">
					<description>Actions label</description>
					<include>ButtonCommonValues</include>
					<textwidth>352</textwidth>
					<font>font13_title</font>
					<label>31039</label>
					<enable>no</enable>
					<disabledcolor>DisabledColor</disabledcolor>
					<visible>!Skin.HasSetting(Disable.Quicknav) | Player.HasMedia | !String.IsEqual(Playlist.Length(music),0) | !String.IsEqual(Playlist.Length(video),0)</visible>
				</control>
				<control type="button" id="208">
					<description>Refresh button</description>
					<include>ButtonCommonValues</include>
					<textwidth>352</textwidth>
					<label>184</label>
					<onclick>Weather.Refresh</onclick>
				</control>
				<control type="button" id="209">
					<description>Last Updated Time</description>
					<include>ButtonCommonValues</include>
					<label>[LOWERCASE]$INFO[Window.Property(Updated)][/LOWERCASE]</label>
					<visible>!String.IsEmpty(Window.Property(Updated))</visible>
					<enable>False</enable>
				</control>
				<control type="button" id="210">
					<description>Settings button</description>
					<include>ButtonCommonValues</include>
					<textwidth>352</textwidth>
					<label>1390</label>
					<onclick>ActivateWindow(servicesettings,weather)</onclick>
				</control>
				<include>QuicknavButton</include>
				<include>PlaylistButtons</include>
				<include content="MenuPlayerControls">
					<param name="PlayerControlsOnDown" value="213" />
				</include>
			</control>
			<include condition="!Skin.HasSetting(Disable.Quicknav)">QuicknavMenu</include>
		</control>

		<include>weather-details-zoom</include>
		<include>weather-alert-zoom</include>
	</controls>

</window>