<?xml version="1.0" encoding="UTF-8"?>
<window type="dialog" id="1117">
    <defaultcontrol always="true">3110</defaultcontrol>
	<include>DialogOpenClose</include>
    <onload condition="String.IsEqual(Window(Home).Property(colorpick),HighlightColor)">SetProperty(colorstring,$VAR[HighlightColor])</onload>
	<onload condition="String.IsEqual(Window(Home).Property(colorpick),LabelTextColor)">SetProperty(colorstring,$VAR[LabelTextColor])</onload>
	<onload condition="String.IsEqual(Window(Home).Property(colorpick),FocusedTextColor)">SetProperty(colorstring,$VAR[FocusedTextColor])</onload>
	<onload condition="String.IsEqual(Window(Home).Property(colorpick),SelectedTextColor)">SetProperty(colorstring,$VAR[SelectedTextColor])</onload>
	<onload condition="String.IsEqual(Window(Home).Property(colorpick),GlowBarsColor)">SetProperty(colorstring,$VAR[GlowBarsColor])</onload>
	<onload condition="String.IsEqual(Window(Home).Property(colorpick),MenuBarColor)">SetProperty(colorstring,$VAR[MenuBarColor])</onload>
	<onload condition="String.IsEqual(Window(Home).Property(colorpick),VertMenuBladeColor)">SetProperty(colorstring,$VAR[VertMenuBladeColor])</onload>
	<onload condition="String.IsEqual(Window(Home).Property(colorpick),TopBarColor)">SetProperty(colorstring,$VAR[TopBarColor])</onload>
	<onload condition="String.IsEqual(Window(Home).Property(colorpick),DialogBGColor)">SetProperty(colorstring,$VAR[DialogBGColor])</onload>
	<onload condition="String.IsEqual(Window(Home).Property(colorpick),WidgetBGColor)">SetProperty(colorstring,$VAR[WidgetBGColor])</onload>
	<onload condition="String.IsEqual(Window(Home).Property(colorpick),ViewsBGColor)">SetProperty(colorstring,$VAR[ViewsBGColor])</onload>
	<onunload>ClearProperty(colorpick,Home)</onunload>
    <controls>

	    <control type="group">
            <width>980</width>
            <height>720</height>
			<centerleft>50%</centerleft>
            <centertop>595</centertop>

			<!-- background panel -->
		    <control type="image">
			    <texture border="40">dialogs/TinyDialog.png</texture>
			    <colordiffuse>$VAR[DialogBGColor]</colordiffuse>
		    </control>

			<!-- Header -->
            <control type="label">
                <left>30</left>
                <right>30</right>
                <top>0</top>
                <height>120</height>
                <align>center</align>
                <aligny>center</aligny>
				<label>$LOCALIZE[22080] $INFO[Skin.String(SelectColorLabel)]</label>
			    <textcolor>$VAR[LabelTextColor]</textcolor>
            </control>

			<control type="group">
                <left>60</left>
                <right>40</right>
                <bottom>40</bottom>
                <top>120</top>

                <!-- Swatches -->
                <control type="group">
                    <right>320</right>

			        <!-- Color picker panel -->
		            <control type="panel" id="3110">
				        <onup>3110</onup>
                        <ondown>3110</ondown>
                        <onback>3012</onback>
                        <onleft>noop</onleft>
                        <onright>9000</onright>
                        <scrolltime>200</scrolltime>
                        <orientation>vertical</orientation>
                        <preloaditems>2</preloaditems>
				        <onclick condition="String.IsEqual(Window(Home).Property(colorpick),HighlightColor)">Skin.SetString(HighlightColorStr,$INFO[ListItem.Label])</onclick>
				        <onclick condition="String.IsEqual(Window(Home).Property(colorpick),LabelTextColor)">Skin.SetString(LabelTextColorStr,$INFO[ListItem.Label])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),FocusedTextColor)">Skin.SetString(FocusedTextColorStr,$INFO[ListItem.Label])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),SelectedTextColor)">Skin.SetString(SelectedTextColorStr,$INFO[ListItem.Label])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),GlowBarsColor)">Skin.SetString(GlowBarsColorStr,$INFO[ListItem.Label])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),MenuBarColor)">Skin.SetString(MenuBarColorStr,$INFO[ListItem.Label])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),VertMenuBladeColor)">Skin.SetString(VertMenuBladeColorStr,$INFO[ListItem.Label])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),TopBarColor)">Skin.SetString(TopBarColorStr,$INFO[ListItem.Label])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),DialogBGColor)">Skin.SetString(DialogBGColorStr,$INFO[ListItem.Label])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),WidgetBGColor)">Skin.SetString(WidgetBGColorStr,$INFO[ListItem.Label])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),ViewsBGColor)">Skin.SetString(ViewsBGColorStr,$INFO[ListItem.Label])</onclick>
						<onclick>SetProperty(colorstring,$INFO[ListItem.Label])</onclick>
                        <onclick>SetFocus(3012)</onclick>
                        <itemlayout width="80" height="80">
                            <control type="image">
                                <right>1</right>
                                <bottom>1</bottom>
                                <texture background="true">$INFO[ListItem.Icon]</texture>
                            </control>
                        </itemlayout>
                        <focusedlayout width="80" height="80">
                            <control type="image">
                                <right>1</right>
                                <bottom>1</bottom>
                                <texture background="true">$INFO[ListItem.Icon]</texture>
                            </control>
                        </focusedlayout>
				        <include>Items_ColorPalette_Standard</include>
                        <include>Items_ColorPalette_Material</include>
                    </control>

					<!-- Selection Box -->
                    <control type="group">
                        <left>-40</left>
                        <top>-40</top>
                        <width>160</width>
                        <height>160</height>
                        <visible>Control.Hasfocus(3110)</visible>
                        <animation effect="slide" end="0,80" condition="Container(3110).Row(1)">Conditional</animation>
                        <animation effect="slide" end="0,160" condition="Container(3110).Row(2)">Conditional</animation>
                        <animation effect="slide" end="0,240" condition="Container(3110).Row(3)">Conditional</animation>
                        <animation effect="slide" end="0,320" condition="Container(3110).Row(4)">Conditional</animation>
                        <animation effect="slide" end="0,400" condition="Container(3110).Row(5)">Conditional</animation>
                        <animation effect="slide" end="0,480" condition="Container(3110).Row(6)">Conditional</animation>
                        <animation effect="slide" end="80" condition="Container(3110).Column(1)">Conditional</animation>
                        <animation effect="slide" end="160" condition="Container(3110).Column(2)">Conditional</animation>
                        <animation effect="slide" end="240" condition="Container(3110).Column(3)">Conditional</animation>
                        <animation effect="slide" end="320" condition="Container(3110).Column(4)">Conditional</animation>
                        <animation effect="slide" end="400" condition="Container(3110).Column(5)">Conditional</animation>
                        <animation effect="slide" end="480" condition="Container(3110).Column(6)">Conditional</animation>
                        <control type="image">
                            <bordersize>20</bordersize>
                            <texture colordiffuse="$INFO[Container(3110).ListItem.Label]" border="10">common/box.png</texture>
                        </control>
                        <control type="image">
                            <bordersize>20</bordersize>
                            <bordertexture border="32" colordiffuse="Shadow">common/shadow-20.png</bordertexture>
                            <texture border="20" colordiffuse="Selected">common/selectbox.png</texture>
                        </control>
                    </control>
                </control>

				<!-- Buttons -->
                <control type="grouplist" id="9000">
                    <right>-100</right>
                    <width>380</width>
                    <orientation>vertical</orientation>
                    <itemgap>20</itemgap>
                    <onleft>3110</onleft>
                    <onright>3110</onright>
					<onup>9000</onup>
					<ondown>9000</ondown>
                    <height>550</height>

			        <control type="group">
					    <height>160</height>
					    <control type="label">
					        <width>280</width>
						    <height>40</height>
						    <label>[B]$LOCALIZE[32338][/B]</label>
							<font>ListDetailsSmall</font>
					    </control>
					    <!-- color preview-->
			            <control type="image">
				            <top>40</top>
							<width>280</width>
				            <height>60</height>
				            <aspectratio>stretch</aspectratio>
				            <texture border="5">panel.png</texture>
				            <colordiffuse>$INFO[Window.Property(colorstring)]</colordiffuse>
			            </control>
					</control>
			        <!-- edit manual -->
			        <control type="button" id="3010">
				        <width>280</width>
				        <height>60</height>
				        <label>$LOCALIZE[32339]: $VAR[ColorValueLabelVar]</label>
                        <onclick condition="String.IsEqual(Window(Home).Property(colorpick),HighlightColor)">Skin.SetString(HighlightColorStr)</onclick>
				        <onclick condition="String.IsEqual(Window(Home).Property(colorpick),LabelTextColor)">Skin.SetString(LabelTextColorStr)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),FocusedTextColor)">Skin.SetString(FocusedTextColorStr)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),SelectedTextColor)">Skin.SetString(SelectedTextColorStr)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),GlowBarsColor)">Skin.SetString(GlowBarsColorStr)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),MenuBarColor)">Skin.SetString(MenuBarColorStr)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),VertMenuBladeColor)">Skin.SetString(VertMenuBladeColorStr)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),TopBarColor)">Skin.SetString(TopBarColorStr)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),DialogBGColor)">Skin.SetString(DialogBGColorStr)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),WidgetBGColor)">Skin.SetString(WidgetBGColorStr)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),ViewsBGColor)">Skin.SetString(ViewsBGColorStr)</onclick>
						<font>ListDetails</font>
			        </control>
			        <!-- Save button -->
			        <control type="button" id="3012">
				        <width>280</width>
				        <height>60</height>
				        <label>190</label>
				        <font>ListDetails</font>
					    <onclick>Action(Close)</onclick>
						<animation type="Focus" reversible="false">
			                <effect type="zoom" end="110" time="75" tween="sine" easing="out" center="auto" />
		                </animation>
			        </control>
			        <!-- None -->
			        <control type="button" id="3011">
				        <width>280</width>
				        <height>60</height>
				        <label>None</label>
				        <font>ListDetails</font>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),HighlightColor)">Skin.SetString(HighlightColorStr,None)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),HighlightColor)">SetProperty(colorstring,$VAR[HighlightColor])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),LabelTextColor)">Skin.SetString(LabelTextColorStr,None)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),LabelTextColor)">SetProperty(colorstring,$VAR[LabelTextColor])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),FocusedTextColor)">Skin.SetString(FocusedTextColorStr,None)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),FocusedTextColor)">SetProperty(colorstring,$VAR[FocusedTextColor])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),SelectedTextColor)">Skin.SetString(SelectedTextColorStr,None)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),SelectedTextColor)">SetProperty(colorstring,$VAR[SelectedTextColor])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),GlowBarsColor)">Skin.SetString(GlowBarsColorStr,None)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),GlowBarsColor)">SetProperty(colorstring,$VAR[GlowBarsColor])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),MenuBarColor)">Skin.SetString(MenuBarColorStr,None)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),MenuBarColor)">SetProperty(colorstring,$VAR[MenuBarColor])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),VertMenuBladeColor)">Skin.SetString(VertMenuBladeColorStr,None)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),VertMenuBladeColor)">SetProperty(colorstring,$VAR[VertMenuBladeColor])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),TopBarColor)">Skin.SetString(TopBarColorStr,None)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),TopBarColor)">SetProperty(colorstring,$VAR[TopBarColor])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),DialogBGColor)">Skin.SetString(DialogBGColorStr,None)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),DialogBGColor)">SetProperty(colorstring,$VAR[DialogBGColor])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),WidgetBGColor)">Skin.SetString(WidgetBGColorStr,None)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),WidgetBGColor)">SetProperty(colorstring,$VAR[WidgetBGColor])</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),ViewsBGColor)">Skin.SetString(ViewsBGColorStr,None)</onclick>
						<onclick condition="String.IsEqual(Window(Home).Property(colorpick),ViewsBGColor)">SetProperty(colorstring,$VAR[ViewsBGColor])</onclick>
			        </control>
					<!-- Use for all tints -->
				    <control type="button" id="3029">
				        <width>280</width>
				        <height>60</height>
				        <label>$LOCALIZE[32216]</label>
				        <font>ListDetails</font>
					    <onclick>Skin.SetString(GlowBarsColorStr,$INFO[Window.Property(colorstring)])</onclick>
					    <onclick>Skin.SetString(MenuBarColorStr,$INFO[Window.Property(colorstring)])</onclick>
					    <onclick>Skin.SetString(VertMenuBladeColorStr,$INFO[Window.Property(colorstring)])</onclick>
					    <onclick>Skin.SetString(TopBarColorStr,$INFO[Window.Property(colorstring)])</onclick>
					    <onclick>Skin.SetString(DialogBGColorStr,$INFO[Window.Property(colorstring)])</onclick>
					    <onclick>Skin.SetString(WidgetBGColorStr,$INFO[Window.Property(colorstring)])</onclick>
					    <onclick>Skin.SetString(ViewsBGColorStr,$INFO[Window.Property(colorstring)])</onclick>
					   <onclick>Action(Close)</onclick>
			        </control>
		        </control>
            </control>
        </control>

    </controls>
</window>
