-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMainWindow.xaml
More file actions
547 lines (517 loc) · 37.2 KB
/
Copy pathMainWindow.xaml
File metadata and controls
547 lines (517 loc) · 37.2 KB
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
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
<Window x:Class="SoundManager.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="SoundManager" Height="600" Width="820" MinHeight="460" MinWidth="680"
Background="{DynamicResource Bg}" FontFamily="Segoe UI" UseLayoutRounding="True">
<Window.Resources>
<Style x:Key="ScrollThumbStyle" TargetType="Thumb">
<Setter Property="OverridesDefaultStyle" Value="True"/>
<Setter Property="IsTabStop" Value="False"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Thumb">
<Border x:Name="t" CornerRadius="5" Margin="3,2" Background="{DynamicResource ScrollThumb}"/>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="t" Property="Background" Value="{DynamicResource ScrollThumbHover}"/>
</Trigger>
<Trigger Property="IsDragging" Value="True">
<Setter TargetName="t" Property="Background" Value="{DynamicResource ScrollThumbHover}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="ScrollNoButton" TargetType="RepeatButton">
<Setter Property="OverridesDefaultStyle" Value="True"/>
<Setter Property="Focusable" Value="False"/>
<Setter Property="IsTabStop" Value="False"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="RepeatButton"><Border Background="Transparent"/></ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="ScrollBar">
<Setter Property="OverridesDefaultStyle" Value="True"/>
<Setter Property="Width" Value="12"/>
<Setter Property="Background" Value="Transparent"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="ScrollBar">
<Grid Background="Transparent">
<Track x:Name="PART_Track" IsDirectionReversed="True">
<Track.DecreaseRepeatButton>
<RepeatButton Style="{StaticResource ScrollNoButton}" Command="ScrollBar.PageUpCommand"/>
</Track.DecreaseRepeatButton>
<Track.Thumb><Thumb Style="{StaticResource ScrollThumbStyle}" MinHeight="28"/></Track.Thumb>
<Track.IncreaseRepeatButton>
<RepeatButton Style="{StaticResource ScrollNoButton}" Command="ScrollBar.PageDownCommand"/>
</Track.IncreaseRepeatButton>
</Track>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="Orientation" Value="Horizontal">
<Setter Property="Width" Value="Auto"/>
<Setter Property="Height" Value="12"/>
<Setter TargetName="PART_Track" Property="MinHeight" Value="0"/>
<Setter TargetName="PART_Track" Property="IsDirectionReversed" Value="False"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="ContextMenu">
<Setter Property="OverridesDefaultStyle" Value="True"/>
<Setter Property="HasDropShadow" Value="True"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="ContextMenu">
<Border Background="{DynamicResource Surface}" BorderBrush="{DynamicResource Border}"
BorderThickness="1" CornerRadius="10" Padding="5">
<StackPanel IsItemsHost="True" KeyboardNavigation.DirectionalNavigation="Cycle"/>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="MenuItem">
<Setter Property="Foreground" Value="{DynamicResource Text}"/>
<Setter Property="Padding" Value="11,8"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="MenuItem">
<Border x:Name="b" Background="Transparent" CornerRadius="7" Padding="{TemplateBinding Padding}">
<ContentPresenter ContentSource="Header" VerticalAlignment="Center" RecognizesAccessKey="True"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsHighlighted" Value="True">
<Setter TargetName="b" Property="Background" Value="{DynamicResource SurfaceHover}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="Separator">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Separator">
<Border Height="1" Background="{DynamicResource Border}" Margin="6,5"/>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="DeviceCard" TargetType="Button">
<Setter Property="Background" Value="{DynamicResource Surface}"/>
<Setter Property="BorderBrush" Value="{DynamicResource Border}"/>
<Setter Property="BorderThickness" Value="1"/>
<Setter Property="Margin" Value="0,0,0,8"/>
<Setter Property="Padding" Value="14,12"/>
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border x:Name="b" CornerRadius="10" Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}"
Padding="{TemplateBinding Padding}">
<ContentPresenter/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="b" Property="Background" Value="{DynamicResource SurfaceHover}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
<Style.Triggers>
<DataTrigger Binding="{Binding IsActive}" Value="True">
<Setter Property="Background" Value="{DynamicResource ActiveBg}"/>
<Setter Property="BorderBrush" Value="{DynamicResource Accent}"/>
</DataTrigger>
</Style.Triggers>
</Style>
<Style x:Key="IconButton" TargetType="Button">
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Width" Value="40"/>
<Setter Property="Height" Value="40"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border x:Name="b" CornerRadius="10" Background="{DynamicResource Surface}"
BorderBrush="{DynamicResource Border}" BorderThickness="1">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="b" Property="Background" Value="{DynamicResource SurfaceHover}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!-- ===== header pill button (icon + label) ===== -->
<Style x:Key="HeaderButton" TargetType="Button">
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Height" Value="40"/>
<Setter Property="MinWidth" Value="120"/>
<Setter Property="Margin" Value="5,0"/>
<Setter Property="Foreground" Value="{DynamicResource Text}"/>
<Setter Property="HorizontalContentAlignment" Value="Center"/>
<Setter Property="VerticalContentAlignment" Value="Center"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border x:Name="b" CornerRadius="10" Background="{DynamicResource Surface}"
BorderBrush="{DynamicResource Border}" BorderThickness="1" Padding="14,0">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="b" Property="Background" Value="{DynamicResource SurfaceHover}"/>
<Setter TargetName="b" Property="BorderBrush" Value="{DynamicResource Accent}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="SocialButton" TargetType="Button">
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Width" Value="50"/>
<Setter Property="Height" Value="50"/>
<Setter Property="Margin" Value="7,0"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border x:Name="b" CornerRadius="13" Background="{DynamicResource Bg}"
BorderBrush="{DynamicResource Border}" BorderThickness="1">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="b" Property="Background" Value="{DynamicResource SurfaceHover}"/>
<Setter TargetName="b" Property="BorderBrush" Value="{DynamicResource Accent}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="DialogButton" TargetType="Button">
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Foreground" Value="{DynamicResource Text}"/>
<Setter Property="FontWeight" Value="SemiBold"/>
<Setter Property="Padding" Value="0,11"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border x:Name="b" CornerRadius="10" Background="{DynamicResource Bg}"
BorderBrush="{DynamicResource Border}" BorderThickness="1" Padding="{TemplateBinding Padding}">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="b" Property="Background" Value="{DynamicResource SurfaceHover}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="ToggleSwitch" TargetType="CheckBox">
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="VerticalAlignment" Value="Center"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="CheckBox">
<Border x:Name="track" Width="46" Height="26" CornerRadius="13" Background="{DynamicResource Border}">
<Border x:Name="knob" Width="20" Height="20" CornerRadius="10"
Background="White" HorizontalAlignment="Left" Margin="3,0,0,0"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsChecked" Value="True">
<Setter TargetName="track" Property="Background" Value="{DynamicResource Accent}"/>
<Setter TargetName="knob" Property="HorizontalAlignment" Value="Right"/>
<Setter TargetName="knob" Property="Margin" Value="0,0,3,0"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="StatusCard" TargetType="Border">
<Setter Property="Background" Value="{DynamicResource Surface}"/>
<Setter Property="BorderBrush" Value="{DynamicResource Border}"/>
<Setter Property="BorderThickness" Value="1"/>
<Setter Property="CornerRadius" Value="12"/>
<Setter Property="Padding" Value="14,13"/>
<Setter Property="Margin" Value="0,0,0,12"/>
</Style>
<DataTemplate x:Key="DeviceTemplate">
<Button Style="{StaticResource DeviceCard}" Click="Device_Click"
ToolTip="Left-click: set Default • Right-click: more options">
<Button.ContextMenu>
<ContextMenu>
<MenuItem Header="Set as Default" Click="MenuDefault_Click"/>
<MenuItem Header="Set as Default Communication" Click="MenuComms_Click"/>
<Separator/>
<MenuItem Header="Set as Both" Click="MenuBoth_Click"/>
</ContextMenu>
</Button.ContextMenu>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<TextBlock Grid.Column="0" Text="{Binding Name}" TextTrimming="CharacterEllipsis"
Foreground="{DynamicResource Text}" VerticalAlignment="Center" FontSize="14" Margin="0,0,8,0"/>
<StackPanel Grid.Column="1" Orientation="Horizontal" VerticalAlignment="Center">
<Border Visibility="{Binding DefaultVis}" Background="{DynamicResource Accent}"
CornerRadius="6" Padding="8,3" Margin="0,0,6,0">
<TextBlock Text="Default" Foreground="White" FontSize="11" FontWeight="SemiBold"/>
</Border>
<Border Visibility="{Binding CommsVis}" Background="{DynamicResource AccentComms}"
CornerRadius="6" Padding="8,3">
<TextBlock Text="Comms" Foreground="White" FontSize="11" FontWeight="SemiBold"/>
</Border>
</StackPanel>
</Grid>
</Button>
</DataTemplate>
</Window.Resources>
<Grid>
<Grid Margin="20">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<!-- header -->
<Grid Grid.Row="0" Margin="0,0,0,18">
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center" VerticalAlignment="Center">
<Button Style="{StaticResource HeaderButton}" Click="OpenSoundPanel_Click"
ToolTip="Open Windows Sound settings">
<StackPanel Orientation="Horizontal" VerticalAlignment="Center">
<Viewbox Width="17" Height="17" Margin="0,0,9,0">
<Canvas Width="24" Height="24">
<Path Fill="{DynamicResource Text}" Data="M3 9v6h4l5 5V4L7 9H3zm13.5 3c0-1.77-1.02-3.29-2.5-4.03v8.05c1.48-.73 2.5-2.25 2.5-4.02zM14 3.23v2.06c2.89.86 5 3.54 5 6.71s-2.11 5.85-5 6.71v2.06c4.01-.91 7-4.49 7-8.77s-2.99-7.86-7-8.77z"/>
</Canvas>
</Viewbox>
<TextBlock Text="Sound settings" FontSize="13" FontWeight="SemiBold"
Foreground="{DynamicResource Text}" VerticalAlignment="Center"/>
</StackPanel>
</Button>
<Button Style="{StaticResource HeaderButton}" Click="OpenVolumeMixer_Click"
ToolTip="Open Windows Volume Mixer">
<StackPanel Orientation="Horizontal" VerticalAlignment="Center">
<Viewbox Width="17" Height="17" Margin="0,0,9,0">
<Canvas Width="24" Height="24">
<Path Fill="{DynamicResource Text}" Data="M7 3h2v18H7V3zm-4 6h2v12H3V9zm8-4h2v22h-2V5zm4 8h2v14h-2V13zm4-4h2v18h-2V9z"/>
</Canvas>
</Viewbox>
<TextBlock Text="Volume mixer" FontSize="13" FontWeight="SemiBold"
Foreground="{DynamicResource Text}" VerticalAlignment="Center"/>
</StackPanel>
</Button>
</StackPanel>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right">
<Button Style="{StaticResource IconButton}" Margin="0,0,8,0" Click="OpenSettings_Click" ToolTip="Settings">
<Viewbox Width="20" Height="20">
<Canvas Width="24" Height="24">
<Path Fill="{DynamicResource Text}" Data="M19.14,12.94c0.04-0.3,0.06-0.61,0.06-0.94c0-0.32-0.02-0.64-0.07-0.94l2.03-1.58c0.18-0.14,0.23-0.41,0.12-0.61 l-1.92-3.32c-0.12-0.22-0.37-0.29-0.59-0.22l-2.39,0.96c-0.5-0.38-1.03-0.7-1.62-0.94L14.4,2.81c-0.04-0.24-0.24-0.41-0.48-0.41 h-3.84c-0.24,0-0.43,0.17-0.47,0.41L9.25,5.35C8.66,5.59,8.12,5.92,7.63,6.29L5.24,5.33c-0.22-0.08-0.47,0-0.59,0.22L2.74,8.87 C2.62,9.08,2.66,9.34,2.86,9.48l2.03,1.58C4.84,11.36,4.8,11.69,4.8,12s0.02,0.64,0.07,0.94l-2.03,1.58 c-0.18,0.14-0.23,0.41-0.12,0.61l1.92,3.32c0.12,0.22,0.37,0.29,0.59,0.22l2.39-0.96c0.5,0.38,1.03,0.7,1.62,0.94l0.36,2.54 c0.05,0.24,0.24,0.41,0.48,0.41h3.84c0.24,0,0.44-0.17,0.47-0.41l0.36-2.54c0.59-0.24,1.13-0.56,1.62-0.94l2.39,0.96 c0.22,0.08,0.47,0,0.59-0.22l1.92-3.32c0.12-0.22,0.07-0.47-0.12-0.61L19.14,12.94z M12,15.6c-1.98,0-3.6-1.62-3.6-3.6 s1.62-3.6,3.6-3.6s3.6,1.62,3.6,3.6S13.98,15.6,12,15.6z"/>
</Canvas>
</Viewbox>
</Button>
<Button Style="{StaticResource IconButton}" Click="OpenAbout_Click" ToolTip="About">
<Viewbox Width="20" Height="20">
<Canvas Width="24" Height="24">
<Path Fill="{DynamicResource Text}" Data="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"/>
</Canvas>
</Viewbox>
</Button>
</StackPanel>
</Grid>
<Grid Grid.Row="1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="16"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<DockPanel Grid.Column="0">
<TextBlock DockPanel.Dock="Top" Text="🔊 Playback" FontSize="15" FontWeight="SemiBold"
Foreground="{DynamicResource TextDim}" Margin="2,0,0,10"/>
<Border DockPanel.Dock="Top" Style="{StaticResource StatusCard}">
<StackPanel>
<Grid>
<Grid.ColumnDefinitions><ColumnDefinition Width="Auto"/><ColumnDefinition Width="*"/></Grid.ColumnDefinitions>
<Border Grid.Column="0" Background="{DynamicResource Accent}" CornerRadius="6" Padding="8,3" Margin="0,0,10,0" VerticalAlignment="Center">
<TextBlock Text="Default" Foreground="White" FontSize="11" FontWeight="SemiBold"/>
</Border>
<TextBlock Grid.Column="1" x:Name="PlaybackDefaultName" Text="—" Foreground="{DynamicResource Text}"
FontSize="13" FontWeight="SemiBold" VerticalAlignment="Center" TextTrimming="CharacterEllipsis"/>
</Grid>
<Border Height="1" Background="{DynamicResource Border}" Margin="0,11"/>
<Grid>
<Grid.ColumnDefinitions><ColumnDefinition Width="Auto"/><ColumnDefinition Width="*"/></Grid.ColumnDefinitions>
<Border Grid.Column="0" Background="{DynamicResource AccentComms}" CornerRadius="6" Padding="8,3" Margin="0,0,10,0" VerticalAlignment="Center">
<TextBlock Text="Comms" Foreground="White" FontSize="11" FontWeight="SemiBold"/>
</Border>
<TextBlock Grid.Column="1" x:Name="PlaybackCommsName" Text="—" Foreground="{DynamicResource Text}"
FontSize="13" FontWeight="SemiBold" VerticalAlignment="Center" TextTrimming="CharacterEllipsis"/>
</Grid>
</StackPanel>
</Border>
<ScrollViewer VerticalScrollBarVisibility="Auto">
<ItemsControl x:Name="PlaybackList" ItemTemplate="{StaticResource DeviceTemplate}"/>
</ScrollViewer>
</DockPanel>
<DockPanel Grid.Column="2">
<TextBlock DockPanel.Dock="Top" Text="🎙 Recording" FontSize="15" FontWeight="SemiBold"
Foreground="{DynamicResource TextDim}" Margin="2,0,0,10"/>
<Border DockPanel.Dock="Top" Style="{StaticResource StatusCard}">
<StackPanel>
<Grid>
<Grid.ColumnDefinitions><ColumnDefinition Width="Auto"/><ColumnDefinition Width="*"/></Grid.ColumnDefinitions>
<Border Grid.Column="0" Background="{DynamicResource Accent}" CornerRadius="6" Padding="8,3" Margin="0,0,10,0" VerticalAlignment="Center">
<TextBlock Text="Default" Foreground="White" FontSize="11" FontWeight="SemiBold"/>
</Border>
<TextBlock Grid.Column="1" x:Name="RecordingDefaultName" Text="—" Foreground="{DynamicResource Text}"
FontSize="13" FontWeight="SemiBold" VerticalAlignment="Center" TextTrimming="CharacterEllipsis"/>
</Grid>
<Border Height="1" Background="{DynamicResource Border}" Margin="0,11"/>
<Grid>
<Grid.ColumnDefinitions><ColumnDefinition Width="Auto"/><ColumnDefinition Width="*"/></Grid.ColumnDefinitions>
<Border Grid.Column="0" Background="{DynamicResource AccentComms}" CornerRadius="6" Padding="8,3" Margin="0,0,10,0" VerticalAlignment="Center">
<TextBlock Text="Comms" Foreground="White" FontSize="11" FontWeight="SemiBold"/>
</Border>
<TextBlock Grid.Column="1" x:Name="RecordingCommsName" Text="—" Foreground="{DynamicResource Text}"
FontSize="13" FontWeight="SemiBold" VerticalAlignment="Center" TextTrimming="CharacterEllipsis"/>
</Grid>
</StackPanel>
</Border>
<ScrollViewer VerticalScrollBarVisibility="Auto">
<ItemsControl x:Name="RecordingList" ItemTemplate="{StaticResource DeviceTemplate}"/>
</ScrollViewer>
</DockPanel>
</Grid>
</Grid>
<Grid x:Name="SettingsOverlay" Visibility="Collapsed" Background="#99000000" MouseLeftButtonDown="Overlay_Click">
<Border Width="420" VerticalAlignment="Center" HorizontalAlignment="Center"
Background="{DynamicResource Surface}" CornerRadius="16"
BorderBrush="{DynamicResource Border}" BorderThickness="1" Padding="24" MouseLeftButtonDown="Card_Click">
<StackPanel>
<Grid Margin="0,0,0,18">
<TextBlock Text="Settings" FontSize="18" FontWeight="Bold" Foreground="{DynamicResource Text}" VerticalAlignment="Center"/>
<Button Style="{StaticResource IconButton}" Width="30" Height="30" HorizontalAlignment="Right" Click="CloseSettings_Click" ToolTip="Close">
<TextBlock Text="✕" FontSize="13" Foreground="{DynamicResource TextDim}"/>
</Button>
</Grid>
<Grid Margin="0,6,0,14">
<StackPanel VerticalAlignment="Center">
<TextBlock Text="Dark mode" FontSize="14" FontWeight="SemiBold" Foreground="{DynamicResource Text}"/>
<TextBlock Text="Switch between light and dark theme" FontSize="12" Foreground="{DynamicResource TextDim}" Margin="0,2,0,0"/>
</StackPanel>
<CheckBox x:Name="DarkToggle" Style="{StaticResource ToggleSwitch}" HorizontalAlignment="Right" Click="DarkToggle_Click"/>
</Grid>
<Border Height="1" Background="{DynamicResource Border}" Margin="0,0,0,14"/>
<Grid Margin="0,0,0,14">
<StackPanel VerticalAlignment="Center">
<TextBlock Text="Minimize to tray on close" FontSize="14" FontWeight="SemiBold" Foreground="{DynamicResource Text}"/>
<TextBlock Text="Closing (✕) hides to tray instead of quitting" FontSize="12" Foreground="{DynamicResource TextDim}" Margin="0,2,0,0"/>
</StackPanel>
<CheckBox x:Name="TrayToggle" Style="{StaticResource ToggleSwitch}" HorizontalAlignment="Right" Click="TrayToggle_Click"/>
</Grid>
<Border Height="1" Background="{DynamicResource Border}" Margin="0,0,0,14"/>
<Grid Margin="0,0,0,14">
<StackPanel VerticalAlignment="Center">
<TextBlock Text="Run at startup" FontSize="14" FontWeight="SemiBold" Foreground="{DynamicResource Text}"/>
<TextBlock Text="Launch SoundManager when Windows starts" FontSize="12" Foreground="{DynamicResource TextDim}" Margin="0,2,0,0"/>
</StackPanel>
<CheckBox x:Name="StartupToggle" Style="{StaticResource ToggleSwitch}" HorizontalAlignment="Right" Click="StartupToggle_Click"/>
</Grid>
<Border Height="1" Background="{DynamicResource Border}" Margin="0,0,0,14"/>
<Grid x:Name="AutoHideRow">
<StackPanel VerticalAlignment="Center">
<TextBlock Text="Auto hide to tray on startup" FontSize="14" FontWeight="SemiBold" Foreground="{DynamicResource Text}"/>
<TextBlock Text="Start hidden in the tray (needs Run at startup)" FontSize="12" Foreground="{DynamicResource TextDim}" Margin="0,2,0,0"/>
</StackPanel>
<CheckBox x:Name="HideStartupToggle" Style="{StaticResource ToggleSwitch}" HorizontalAlignment="Right" Click="HideStartupToggle_Click"/>
</Grid>
</StackPanel>
</Border>
</Grid>
<Grid x:Name="AboutOverlay" Visibility="Collapsed" Background="#99000000" MouseLeftButtonDown="AboutOverlay_Click">
<Border Width="400" VerticalAlignment="Center" HorizontalAlignment="Center"
Background="{DynamicResource Surface}" CornerRadius="16"
BorderBrush="{DynamicResource Border}" BorderThickness="1" MouseLeftButtonDown="Card_Click">
<Border.Clip><RectangleGeometry Rect="0,0,400,520" RadiusX="16" RadiusY="16"/></Border.Clip>
<StackPanel>
<Grid Height="130">
<Border>
<Border.Background>
<LinearGradientBrush StartPoint="0,0" EndPoint="1,1">
<GradientStop Color="#4C8BF5" Offset="0"/>
<GradientStop Color="#9D7BF0" Offset="1"/>
</LinearGradientBrush>
</Border.Background>
<StackPanel VerticalAlignment="Center" HorizontalAlignment="Center">
<TextBlock HorizontalAlignment="Center" FontSize="28">
<Run Text="Sound" FontWeight="Light" Foreground="White"/><Run Text="Manager" FontWeight="SemiBold" Foreground="White"/>
</TextBlock>
<TextBlock Text="Version 1.0.0" HorizontalAlignment="Center" FontSize="12" Foreground="#EAEFFF" Margin="0,4,0,0"/>
</StackPanel>
</Border>
<Button Width="30" Height="30" HorizontalAlignment="Right" VerticalAlignment="Top" Margin="0,12,12,0" Cursor="Hand" Click="CloseAbout_Click" ToolTip="Close">
<Button.Template>
<ControlTemplate TargetType="Button">
<Border x:Name="b" CornerRadius="8" Background="#26FFFFFF">
<TextBlock Text="✕" FontSize="12" Foreground="White" HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="b" Property="Background" Value="#44FFFFFF"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Button.Template>
</Button>
</Grid>
<StackPanel Margin="0,24,0,0">
<TextBlock Text="Created by" TextAlignment="Center" FontSize="13" Foreground="{DynamicResource TextDim}"/>
<TextBlock Text="GoldKingZ" TextAlignment="Center" FontSize="18" FontWeight="Bold" Foreground="{DynamicResource Accent}" Margin="0,2,0,0"/>
</StackPanel>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center" Margin="0,20,0,22">
<Button Style="{StaticResource SocialButton}" Click="Discord_Click" ToolTip="Discord">
<Viewbox Width="26" Height="26">
<Canvas Width="24" Height="24">
<Path Fill="#5865F2" Data="M20.317 4.369a19.791 19.791 0 0 0-4.885-1.515 0.074 0.074 0 0 0-0.079 0.037c-0.211 0.375-0.444 0.864-0.608 1.249-1.844-0.276-3.68-0.276-5.486 0-0.164-0.393-0.405-0.874-0.617-1.249a0.077 0.077 0 0 0-0.079-0.037 19.736 19.736 0 0 0-4.885 1.515 0.07 0.07 0 0 0-0.032 0.027C0.533 9.046-0.32 13.58 0.099 18.057a0.082 0.082 0 0 0 0.031 0.057 19.9 19.9 0 0 0 5.993 3.03 0.078 0.078 0 0 0 0.084-0.028c0.462-0.63 0.874-1.295 1.226-1.994a0.076 0.076 0 0 0-0.041-0.106 13.107 13.107 0 0 1-1.872-0.892 0.077 0.077 0 0 1-0.008-0.128 10.2 10.2 0 0 0 0.372-0.292 0.074 0.074 0 0 1 0.077-0.01c3.928 1.793 8.18 1.793 12.062 0a0.074 0.074 0 0 1 0.078 0.009c0.12 0.099 0.245 0.198 0.372 0.293a0.077 0.077 0 0 1-0.006 0.127 12.299 12.299 0 0 1-1.873 0.891 0.077 0.077 0 0 0-0.041 0.107c0.36 0.698 0.772 1.362 1.225 1.993a0.076 0.076 0 0 0 0.084 0.028 19.839 19.839 0 0 0 6.002-3.03 0.077 0.077 0 0 0 0.032-0.054c0.5-5.177-0.838-9.674-3.549-13.66a0.061 0.061 0 0 0-0.031-0.03zM8.02 15.33c-1.183 0-2.157-1.085-2.157-2.419 0-1.333 0.956-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-0.956 2.418-2.157 2.418zm7.975 0c-1.183 0-2.157-1.085-2.157-2.419 0-1.333 0.955-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-0.946 2.418-2.157 2.418z"/>
</Canvas>
</Viewbox>
</Button>
<Button Style="{StaticResource SocialButton}" Click="Github_Click" ToolTip="GitHub">
<Viewbox Width="25" Height="25">
<Canvas Width="24" Height="24">
<Path Fill="{DynamicResource Text}" Data="M12 0.297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385 0.6 0.113 0.82-0.258 0.82-0.577 0-0.285-0.01-1.04-0.015-2.04-3.338 0.724-4.042-1.61-4.042-1.61-0.546-1.387-1.333-1.756-1.333-1.756-1.089-0.745 0.083-0.729 0.083-0.729 1.205 0.084 1.839 1.237 1.839 1.237 1.07 1.834 2.807 1.304 3.492 0.997 0.107-0.775 0.418-1.305 0.762-1.604-2.665-0.305-5.467-1.334-5.467-5.931 0-1.311 0.469-2.381 1.236-3.221-0.124-0.303-0.535-1.524 0.117-3.176 0 0 1.008-0.322 3.301 1.23 0.957-0.266 1.983-0.399 3.003-0.404 1.02 0.005 2.047 0.138 3.006 0.404 2.291-1.552 3.297-1.23 3.297-1.23 0.653 1.653 0.242 2.874 0.118 3.176 0.77 0.84 1.235 1.911 1.235 3.221 0 4.609-2.807 5.624-5.479 5.921 0.43 0.372 0.823 1.102 0.823 2.222 0 1.606-0.014 2.898-0.014 3.293 0 0.319 0.216 0.694 0.825 0.576 4.765-1.589 8.199-6.086 8.199-11.386 0-6.627-5.373-12-12-12z"/>
</Canvas>
</Viewbox>
</Button>
<Button Style="{StaticResource SocialButton}" Click="Kofi_Click" ToolTip="Ko-fi">
<Viewbox Width="27" Height="27">
<Canvas Width="24" Height="24">
<Path Fill="#FF5E5B" Data="M23.881 8.948c-.773-4.085-4.859-4.593-4.859-4.593H.723c-.604 0-.679.798-.679.798s-.082 7.324-.022 11.822c.164 2.424 2.586 2.672 2.586 2.672s8.267-.023 11.966-.049c2.438-.426 2.683-2.566 2.658-3.734 4.352.24 7.422-2.831 6.649-6.916zm-11.062 3.511c-1.246 1.453-4.011 3.976-4.011 3.976s-.121.119-.31.023c-.076-.057-.108-.09-.108-.09-.443-.441-3.368-3.049-4.034-3.954-.709-.965-1.041-2.7-.091-3.71.951-1.01 3.005-1.086 4.363.407 0 0 1.565-1.782 3.468-.963 1.904.82 1.832 3.011.723 4.311zm6.173.478c-.928.116-1.682.028-1.682.028V7.284h1.77s1.971.551 1.971 2.638c0 1.913-.985 2.667-2.059 3.015z"/>
</Canvas>
</Viewbox>
</Button>
</StackPanel>
<Border Height="1" Background="{DynamicResource Border}"/>
<Button Style="{StaticResource DialogButton}" Content="Close" Margin="26,16,26,22" Click="CloseAbout_Click"/>
</StackPanel>
</Border>
</Grid>
</Grid>
</Window>