-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathDial.xaml
131 lines (130 loc) · 5.33 KB
/
Dial.xaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
<UserControl x:Class="MusicPlayer.Dial"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:MusicPlayer"
mc:Ignorable="d"
x:Name="ADial"
Width="43"
Height="43"
d:DesignHeight="43"
d:DesignWidth="43">
<Grid
MouseMove="Grid_MouseMove"
MouseDown="Grid_MouseDown"
MouseUp="Grid_MouseUp">
<Label Foreground="{DynamicResource InterfaceGold}"
FontSize="5"
HorizontalContentAlignment="Center"
VerticalAlignment="Top"
HorizontalAlignment="Center"
Margin="-34,-5,0,0">-10</Label>
<Label Foreground="{DynamicResource InterfaceGold}"
FontSize="5"
HorizontalContentAlignment="Center"
VerticalAlignment="Top"
HorizontalAlignment="Center"
Margin="0,-5,-34,0">+10</Label>
<Label Foreground="{DynamicResource InterfaceGold}"
FontSize="5"
HorizontalContentAlignment="Center"
VerticalAlignment="Bottom"
HorizontalAlignment="Center"
Margin="-34,0,0,-4">-30</Label>
<Label Foreground="{DynamicResource InterfaceGold}"
FontSize="5"
HorizontalContentAlignment="Center"
VerticalAlignment="Bottom"
HorizontalAlignment="Center"
Margin="0,0,-34,-4">+30</Label>
<Grid Width="33" Height="33">
<Ellipse x:Name="pizza"
Width="33"
Height="33">
<Ellipse.Fill>
<LinearGradientBrush EndPoint="0.5,1"
StartPoint="0.5,0">
<GradientStop Color="#FFC09A67"
Offset="0" />
<GradientStop Color="#00C09A67"
Offset=".8" />
</LinearGradientBrush>
</Ellipse.Fill>
</Ellipse>
</Grid>
<Grid>
<Rectangle Width="1"
Height="16"
Fill="#FF323232"
Margin="0,-16,0,0"
HorizontalAlignment="Center"
VerticalAlignment="Center" />
<Rectangle Width="1"
Height="33"
Fill="#FF323232"
Margin="0,2,0,0"
HorizontalAlignment="Center"
VerticalAlignment="Center">
<Rectangle.RenderTransform>
<RotateTransform CenterX="0"
CenterY="16"
Angle="-90" />
</Rectangle.RenderTransform>
</Rectangle>
<Rectangle Width="1"
Height="32"
Fill="#FF323232"
Margin="0,0,1,0"
HorizontalAlignment="Center"
VerticalAlignment="Center">
<Rectangle.RenderTransform>
<RotateTransform CenterX="0"
CenterY="16"
Angle="-45" />
</Rectangle.RenderTransform>
</Rectangle>
<Rectangle Width="1"
Height="32"
Fill="#FF323232"
Margin="1,0,0,0"
HorizontalAlignment="Center"
VerticalAlignment="Center">
<Rectangle.RenderTransform>
<RotateTransform CenterX="0"
CenterY="16"
Angle="45" />
</Rectangle.RenderTransform>
</Rectangle>
</Grid>
<Ellipse Fill="{DynamicResource BlockFill}"
Stroke="{DynamicResource BorderBrush}"
StrokeThickness="3"
Width="28"
Height="28" />
<Grid x:Name="indicator"
HorizontalAlignment="Center"
VerticalAlignment="Center"
Width="33"
Height="33"
MinHeight="33"
MinWidth="33">
<Grid.RenderTransform>
<RotateTransform CenterX="16.5"
CenterY="16.5"
Angle="{Binding ElementName=ADial, Path=Angle}" />
</Grid.RenderTransform>
<Rectangle Width="1"
Height="4"
Fill="White"
HorizontalAlignment="Center"
VerticalAlignment="Top"
Margin="0,4,0,0" />
</Grid>
<Ellipse Fill="{DynamicResource BlockFill}"
Stroke="{DynamicResource BorderBrush}"
StrokeThickness="2"
Width="12"
Height="12" />
</Grid>
</UserControl>