-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMainWindow.xaml
More file actions
638 lines (601 loc) · 37.8 KB
/
Copy pathMainWindow.xaml
File metadata and controls
638 lines (601 loc) · 37.8 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
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
<Window x:Class="Net_Toolkit.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d"
Title="Net Toolkit"
Width="480"
Height="475"
SizeToContent="Height"
WindowStartupLocation="CenterScreen"
WindowStyle="None"
AllowsTransparency="True"
Background="Transparent"
ResizeMode="NoResize"
FontFamily="Segoe UI"
PreviewKeyDown="Window_PreviewKeyDown">
<Window.Resources>
<SolidColorBrush x:Key="AppBgBrush" Color="#F0F2F5"/>
<SolidColorBrush x:Key="CardBgBrush" Color="#FFFFFF"/>
<SolidColorBrush x:Key="TextPrimaryBrush" Color="#212529"/>
<SolidColorBrush x:Key="TextSecondaryBrush" Color="#495057"/>
<SolidColorBrush x:Key="BorderDefaultBrush" Color="#DEE2E6"/>
<SolidColorBrush x:Key="ControlBgBrush" Color="#E9ECEF"/>
<SolidColorBrush x:Key="AccentBrush" Color="#0D6EFD"/>
<Style x:Key="GlyphIconStyle" TargetType="TextBlock">
<Setter Property="FontFamily" Value="Segoe Fluent Icons"/>
<Setter Property="FontSize" Value="14"/>
<Setter Property="Foreground" Value="{StaticResource TextSecondaryBrush}"/>
<Setter Property="VerticalAlignment" Value="Center"/>
<Setter Property="Margin" Value="0,0,6,0"/>
</Style>
<Style TargetType="Border" x:Key="CardContainer">
<Setter Property="Background" Value="{StaticResource CardBgBrush}"/>
<Setter Property="CornerRadius" Value="10"/>
<Setter Property="Padding" Value="16"/>
<Setter Property="Margin" Value="0,0,0,12"/>
<Setter Property="BorderBrush" Value="{StaticResource BorderDefaultBrush}"/>
<Setter Property="BorderThickness" Value="1"/>
</Style>
<Style TargetType="TextBlock" x:Key="SectionLabel">
<Setter Property="FontSize" Value="12"/>
<Setter Property="FontWeight" Value="SemiBold"/>
<Setter Property="Foreground" Value="{StaticResource TextSecondaryBrush}"/>
<Setter Property="Margin" Value="0,0,0,6"/>
</Style>
<Style x:Key="ModernTextBox" TargetType="TextBox">
<Setter Property="Background" Value="White"/>
<Setter Property="Foreground" Value="{StaticResource TextPrimaryBrush}"/>
<Setter Property="BorderBrush" Value="{StaticResource BorderDefaultBrush}"/>
<Setter Property="BorderThickness" Value="1.5"/>
<Setter Property="Padding" Value="4"/>
<Setter Property="VerticalContentAlignment" Value="Center"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="TextBox">
<Border x:Name="border"
Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}"
CornerRadius="8">
<ScrollViewer x:Name="PART_ContentHost" Margin="{TemplateBinding Padding}"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsFocused" Value="True">
<Setter TargetName="border" Property="BorderBrush" Value="{StaticResource AccentBrush}"/>
</Trigger>
<Trigger Property="IsEnabled" Value="False">
<Setter TargetName="border" Property="Background" Value="{StaticResource ControlBgBrush}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="IpFieldContainer" TargetType="Border">
<Setter Property="Background" Value="White"/>
<Setter Property="BorderBrush" Value="{StaticResource BorderDefaultBrush}"/>
<Setter Property="BorderThickness" Value="1.5"/>
<Setter Property="CornerRadius" Value="8"/>
<Setter Property="Padding" Value="6,5"/>
<Setter Property="HorizontalAlignment" Value="Stretch"/>
<Style.Triggers>
<Trigger Property="IsKeyboardFocusWithin" Value="True">
<Setter Property="BorderBrush" Value="{StaticResource AccentBrush}"/>
</Trigger>
</Style.Triggers>
</Style>
<Style x:Key="IpOctetBox" TargetType="TextBox">
<Setter Property="Background" Value="Transparent"/>
<Setter Property="Foreground" Value="{StaticResource TextPrimaryBrush}"/>
<Setter Property="BorderThickness" Value="0"/>
<Setter Property="Width" Value="30"/>
<Setter Property="FontFamily" Value="Consolas"/>
<Setter Property="FontSize" Value="14"/>
<Setter Property="FontWeight" Value="SemiBold"/>
<Setter Property="TextAlignment" Value="Center"/>
<Setter Property="VerticalContentAlignment" Value="Center"/>
<Setter Property="MaxLength" Value="3"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="TextBox">
<ScrollViewer x:Name="PART_ContentHost" Background="Transparent"/>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="IpDotStyle" TargetType="TextBlock">
<Setter Property="Text" Value="."/>
<Setter Property="FontSize" Value="16"/>
<Setter Property="FontWeight" Value="Bold"/>
<Setter Property="Foreground" Value="{StaticResource TextSecondaryBrush}"/>
<Setter Property="Margin" Value="3,0"/>
<Setter Property="VerticalAlignment" Value="Center"/>
</Style>
<Style TargetType="Button" x:Key="ModernButton">
<Setter Property="Foreground" Value="White"/>
<Setter Property="FontWeight" Value="SemiBold"/>
<Setter Property="FontSize" Value="12"/>
<Setter Property="BorderThickness" Value="0"/>
<Setter Property="Padding" Value="12,0"/>
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Height" Value="34"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Grid>
<Border x:Name="border" Background="{TemplateBinding Background}" CornerRadius="8"/>
<Border x:Name="hoverOverlay" Background="White" Opacity="0" CornerRadius="8" IsHitTestVisible="False"/>
<Border x:Name="pressedOverlay" Background="Black" Opacity="0" CornerRadius="8" IsHitTestVisible="False"/>
<ContentPresenter Focusable="False" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="{TemplateBinding Padding}"/>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="hoverOverlay" Property="Opacity" Value="0.15"/>
</Trigger>
<Trigger Property="IsPressed" Value="True">
<Setter TargetName="pressedOverlay" Property="Opacity" Value="0.15"/>
</Trigger>
<Trigger Property="IsEnabled" Value="False">
<Setter TargetName="border" Property="Background" Value="{StaticResource ControlBgBrush}"/>
<Setter Property="Foreground" Value="{StaticResource TextSecondaryBrush}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="Button" x:Key="IconButton">
<Setter Property="Background" Value="Transparent"/>
<Setter Property="BorderThickness" Value="0"/>
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Width" Value="30"/>
<Setter Property="Height" Value="30"/>
<Setter Property="Foreground" Value="{StaticResource TextPrimaryBrush}"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border x:Name="border" Background="{TemplateBinding Background}" CornerRadius="6">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="border" Property="Background" Value="#FBE9E9"/>
<Setter Property="Foreground" Value="#DC3545"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<ControlTemplate x:Key="ComboBoxToggleButton" TargetType="ToggleButton">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition/>
<ColumnDefinition Width="26"/>
</Grid.ColumnDefinitions>
<Border x:Name="Border" Grid.ColumnSpan="2" CornerRadius="8"
Background="{StaticResource ControlBgBrush}"
BorderBrush="{StaticResource BorderDefaultBrush}"
BorderThickness="1.5"/>
<Path x:Name="Arrow" Grid.Column="1" Fill="{StaticResource TextSecondaryBrush}"
HorizontalAlignment="Center" VerticalAlignment="Center"
Data="M0,0 L0,2 L4,6 L8,2 L8,0 L4,4 z"/>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource AccentBrush}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
<Style TargetType="ComboBox" x:Key="ModernComboBox">
<Setter Property="Foreground" Value="{StaticResource TextPrimaryBrush}"/>
<Setter Property="Background" Value="{StaticResource ControlBgBrush}"/>
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Height" Value="36"/>
<Setter Property="FontSize" Value="12"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="ComboBox">
<Grid>
<ToggleButton Name="ToggleButton" Template="{StaticResource ComboBoxToggleButton}" Focusable="False"
IsChecked="{Binding Path=IsDropDownOpen, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"
ClickMode="Press"/>
<ContentPresenter Name="ContentSite" IsHitTestVisible="False" Content="{TemplateBinding SelectionBoxItem}"
Margin="12,0,30,0" VerticalAlignment="Center" HorizontalAlignment="Left"/>
<Popup Name="Popup" Placement="Bottom" IsOpen="{TemplateBinding IsDropDownOpen}" AllowsTransparency="True" Focusable="False" PopupAnimation="Slide">
<Grid Name="DropDown" SnapsToDevicePixels="True" MinWidth="{TemplateBinding ActualWidth}" MaxHeight="220">
<Border x:Name="DropDownBorder" Background="{StaticResource CardBgBrush}" BorderThickness="1"
BorderBrush="{StaticResource BorderDefaultBrush}" CornerRadius="8" Margin="0,4,0,0">
<Border.Effect>
<DropShadowEffect ShadowDepth="2" BlurRadius="8" Opacity="0.15" Direction="270"/>
</Border.Effect>
<ScrollViewer Margin="0,4" SnapsToDevicePixels="True">
<StackPanel IsItemsHost="True" KeyboardNavigation.DirectionalNavigation="Contained"/>
</ScrollViewer>
</Border>
</Grid>
</Popup>
</Grid>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="ComboBoxItem" x:Key="ModernComboBoxItem">
<Setter Property="Foreground" Value="{StaticResource TextPrimaryBrush}"/>
<Setter Property="Background" Value="Transparent"/>
<Setter Property="Padding" Value="12,8"/>
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="ComboBoxItem">
<Border Name="Border" Padding="{TemplateBinding Padding}" Background="{TemplateBinding Background}">
<ContentPresenter/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="Border" Property="Background" Value="{StaticResource ControlBgBrush}"/>
</Trigger>
<Trigger Property="IsSelected" Value="True">
<Setter TargetName="Border" Property="Background" Value="{StaticResource AccentBrush}"/>
<Setter Property="Foreground" Value="White"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="ComboBox" BasedOn="{StaticResource ModernComboBox}"/>
<Style TargetType="ComboBoxItem" BasedOn="{StaticResource ModernComboBoxItem}"/>
<Style x:Key="ResolveBadge" TargetType="Border">
<Setter Property="Background" Value="{StaticResource ControlBgBrush}"/>
<Setter Property="CornerRadius" Value="6"/>
<Setter Property="Height" Value="22"/>
<Setter Property="Margin" Value="0,8,0,0"/>
</Style>
<Style x:Key="TabButtonBase" TargetType="Button">
<Setter Property="BorderThickness" Value="0"/>
<Setter Property="FontSize" Value="12"/>
<Setter Property="FontWeight" Value="SemiBold"/>
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Height" Value="30"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border Background="{TemplateBinding Background}" CornerRadius="8">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="TabButtonActive" TargetType="Button" BasedOn="{StaticResource TabButtonBase}">
<Setter Property="Background" Value="#E7F1FF"/>
<Setter Property="Foreground" Value="{StaticResource AccentBrush}"/>
</Style>
<Style x:Key="TabButtonInactive" TargetType="Button" BasedOn="{StaticResource TabButtonBase}">
<Setter Property="Background" Value="Transparent"/>
<Setter Property="Foreground" Value="{StaticResource TextSecondaryBrush}"/>
</Style>
<Style x:Key="ToolCategoryCard" TargetType="Border">
<Setter Property="Background" Value="{StaticResource CardBgBrush}"/>
<Setter Property="BorderBrush" Value="{StaticResource BorderDefaultBrush}"/>
<Setter Property="BorderThickness" Value="1"/>
<Setter Property="CornerRadius" Value="10"/>
<Setter Property="Padding" Value="12,10"/>
</Style>
<Style x:Key="ToolCheckBox" TargetType="CheckBox">
<Setter Property="FontSize" Value="12"/>
<Setter Property="Foreground" Value="{StaticResource TextPrimaryBrush}"/>
<Setter Property="Margin" Value="0,4"/>
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="CheckBox">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Border x:Name="box" Grid.Column="0" Width="16" Height="16" CornerRadius="4"
BorderBrush="{StaticResource BorderDefaultBrush}" BorderThickness="1.5"
Background="White" VerticalAlignment="Center">
<Path x:Name="check" Data="M3,8 L6,11 L13,3" Stroke="White" StrokeThickness="2"
StrokeStartLineCap="Round" StrokeEndLineCap="Round" StrokeLineJoin="Round"
Width="10" Height="8" Stretch="Uniform"
HorizontalAlignment="Center" VerticalAlignment="Center"
Visibility="Collapsed"/>
</Border>
<ContentPresenter Grid.Column="1" Margin="8,0,0,0" VerticalAlignment="Center"/>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsChecked" Value="True">
<Setter TargetName="box" Property="Background" Value="{StaticResource AccentBrush}"/>
<Setter TargetName="box" Property="BorderBrush" Value="{StaticResource AccentBrush}"/>
<Setter TargetName="check" Property="Visibility" Value="Visible"/>
</Trigger>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="box" Property="BorderBrush" Value="{StaticResource AccentBrush}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="NumberBadge" TargetType="Border">
<Setter Property="Width" Value="16"/>
<Setter Property="Height" Value="16"/>
<Setter Property="CornerRadius" Value="8"/>
<Setter Property="Background" Value="#E7F1FF"/>
<Setter Property="Margin" Value="0,0,6,0"/>
</Style>
<Style x:Key="LogEntryText" TargetType="TextBlock">
<Setter Property="FontFamily" Value="Consolas"/>
<Setter Property="FontSize" Value="11.5"/>
<Setter Property="Foreground" Value="{StaticResource TextPrimaryBrush}"/>
<Setter Property="Margin" Value="0,3"/>
<Setter Property="TextWrapping" Value="Wrap"/>
</Style>
</Window.Resources>
<Border Background="{StaticResource AppBgBrush}" CornerRadius="12" BorderBrush="{StaticResource BorderDefaultBrush}" BorderThickness="1">
<Border.Effect>
<DropShadowEffect ShadowDepth="0" BlurRadius="16" Opacity="0.25"/>
</Border.Effect>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="48"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="385"/>
</Grid.RowDefinitions>
<Grid Grid.Row="0" Background="Transparent" MouseLeftButtonDown="Window_MouseLeftButtonDown">
<StackPanel Orientation="Horizontal" VerticalAlignment="Center" Margin="20,0,0,0">
<Image Source="icon.ico" Width="30" Height="30" Margin="0,0,10,0"/>
<TextBlock Text="Net Toolkit" FontWeight="Bold" FontSize="16"
Foreground="{StaticResource AccentBrush}" VerticalAlignment="Center"/>
</StackPanel>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Center" Margin="0,0,15,0">
<Button x:Name="CloseButton" Style="{StaticResource IconButton}"
Content="✕" FontSize="14"
HorizontalAlignment="Right" VerticalAlignment="Center"
Margin="0,0,0,0"
Click="CloseButton_Click"
ToolTip="Close"/>
</StackPanel>
</Grid>
<Grid Grid.Row="1" Margin="16,0,16,8">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Button x:Name="DnsTabButton" Grid.Column="0" Content="DNS"
Style="{StaticResource TabButtonActive}" Margin="0,0,3,0"
Click="DnsTabButton_Click"/>
<Button x:Name="ToolsTabButton" Grid.Column="1" Content="Network tools"
Style="{StaticResource TabButtonInactive}" Margin="3,0,0,0"
Click="ToolsTabButton_Click"/>
</Grid>
<Grid Grid.Row="2" Margin="10,0,10,10">
<StackPanel x:Name="DnsTabPanel" Visibility="Visible" Margin="0,0,0,0">
<Border Style="{StaticResource CardContainer}">
<StackPanel>
<StackPanel Orientation="Horizontal" Margin="0,0,0,6">
<TextBlock Text="" Style="{StaticResource GlyphIconStyle}"/>
<TextBlock Text="Network Adapter" FontSize="12" FontWeight="SemiBold" Foreground="{StaticResource TextSecondaryBrush}"/>
</StackPanel>
<ComboBox x:Name="SelectNetworkAdapter"
SelectionChanged="AdapterComboBox_SelectionChanged"
DropDownOpened="SelectNetworkAdapter_DropDownOpened"/>
</StackPanel>
</Border>
<Border Style="{StaticResource CardContainer}">
<StackPanel>
<StackPanel Orientation="Horizontal" Margin="0,0,0,6">
<TextBlock Text="" Style="{StaticResource GlyphIconStyle}"/>
<TextBlock Text="DNS Provider" FontSize="12" FontWeight="SemiBold" Foreground="{StaticResource TextSecondaryBrush}"/>
</StackPanel>
<ComboBox x:Name="DnsServerComboBox"
SelectionChanged="DnsServerComboBox_SelectionChanged"/>
</StackPanel>
</Border>
<Border Style="{StaticResource CardContainer}">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="14"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<StackPanel Grid.Column="0">
<StackPanel Orientation="Horizontal" Margin="0,0,0,6">
<Border Style="{StaticResource NumberBadge}">
<TextBlock Text="1" FontSize="10" FontWeight="Bold" Foreground="{StaticResource AccentBrush}"
HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<TextBlock Text="Primary DNS" FontSize="12" FontWeight="SemiBold" Foreground="{StaticResource TextSecondaryBrush}"/>
</StackPanel>
<Border Style="{StaticResource IpFieldContainer}">
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
<TextBox x:Name="PrimaryOctet1" Style="{StaticResource IpOctetBox}"/>
<TextBlock Style="{StaticResource IpDotStyle}"/>
<TextBox x:Name="PrimaryOctet2" Style="{StaticResource IpOctetBox}"/>
<TextBlock Style="{StaticResource IpDotStyle}"/>
<TextBox x:Name="PrimaryOctet3" Style="{StaticResource IpOctetBox}"/>
<TextBlock Style="{StaticResource IpDotStyle}"/>
<TextBox x:Name="PrimaryOctet4" Style="{StaticResource IpOctetBox}"/>
</StackPanel>
</Border>
<Border Style="{StaticResource ResolveBadge}">
<TextBlock x:Name="PrimaryResolveLabel" Text="Resolve time: --"
FontSize="10.5" Foreground="{StaticResource TextSecondaryBrush}"
HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
</StackPanel>
<StackPanel Grid.Column="2">
<StackPanel Orientation="Horizontal" Margin="0,0,0,6">
<Border Style="{StaticResource NumberBadge}">
<TextBlock Text="2" FontSize="10" FontWeight="Bold" Foreground="{StaticResource AccentBrush}"
HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
<TextBlock Text="Secondary DNS" FontSize="12" FontWeight="SemiBold" Foreground="{StaticResource TextSecondaryBrush}"/>
</StackPanel>
<Border Style="{StaticResource IpFieldContainer}">
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
<TextBox x:Name="SecondaryOctet1" Style="{StaticResource IpOctetBox}"/>
<TextBlock Style="{StaticResource IpDotStyle}"/>
<TextBox x:Name="SecondaryOctet2" Style="{StaticResource IpOctetBox}"/>
<TextBlock Style="{StaticResource IpDotStyle}"/>
<TextBox x:Name="SecondaryOctet3" Style="{StaticResource IpOctetBox}"/>
<TextBlock Style="{StaticResource IpDotStyle}"/>
<TextBox x:Name="SecondaryOctet4" Style="{StaticResource IpOctetBox}"/>
</StackPanel>
</Border>
<Border Style="{StaticResource ResolveBadge}">
<TextBlock x:Name="SecondaryResolveLabel" Text="Resolve time: --"
FontSize="10.5" Foreground="{StaticResource TextSecondaryBrush}"
HorizontalAlignment="Center" VerticalAlignment="Center"/>
</Border>
</StackPanel>
</Grid>
</Border>
<Grid Margin="0,0,0,0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Button x:Name="FastestDnsButton" Grid.Column="0"
Content="Fastest DNS" Style="{StaticResource ModernButton}"
Background="#198754" Margin="0,0,4,0"
Click="FastestDnsButton_Click"
ToolTip="Auto-select fastest DNS"/>
<Button x:Name="FlushDnsButton" Grid.Column="1"
Content="Flush DNS" Style="{StaticResource ModernButton}"
Background="#FF9500" Margin="4,0,4,0"
Click="FlushDnsButton_Click"
ToolTip="Clear DNS cache"/>
<Button x:Name="CancelButton" Grid.Column="2"
Content="Cancel" Style="{StaticResource ModernButton}"
Background="#6C757D" Margin="4,0,4,0"
Click="CancelButton_Click"
IsEnabled="False"/>
<Button x:Name="ApplyButton" Grid.Column="3"
Content="Apply" Style="{StaticResource ModernButton}"
Background="{StaticResource AccentBrush}" Margin="4,0,0,0"
Click="ApplyButton_Click"/>
</Grid>
</StackPanel>
<Grid x:Name="ToolsTabPanel" Visibility="Collapsed">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid Grid.Row="0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="8"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Border Grid.Column="0" Style="{StaticResource ToolCategoryCard}">
<StackPanel>
<TextBlock Text="Connection repair" FontSize="11" FontWeight="SemiBold"
Foreground="{StaticResource TextSecondaryBrush}" Margin="0,0,0,6"/>
<CheckBox x:Name="ResetTcpIpCheck" Style="{StaticResource ToolCheckBox}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="" Style="{StaticResource GlyphIconStyle}"/>
<TextBlock Text="Reset TCP/IP"/>
</StackPanel>
</CheckBox>
<CheckBox x:Name="RepairWinsockCheck" Style="{StaticResource ToolCheckBox}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="" Style="{StaticResource GlyphIconStyle}"/>
<TextBlock Text="Repair Winsock"/>
</StackPanel>
</CheckBox>
<CheckBox x:Name="RenewIpCheck" Style="{StaticResource ToolCheckBox}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="" Style="{StaticResource GlyphIconStyle}"/>
<TextBlock Text="Renew IP"/>
</StackPanel>
</CheckBox>
<CheckBox x:Name="FlushArpCheck" Style="{StaticResource ToolCheckBox}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="" Style="{StaticResource GlyphIconStyle}"/>
<TextBlock Text="Flush ARP cache"/>
</StackPanel>
</CheckBox>
<CheckBox x:Name="RenewWinsCheck" Style="{StaticResource ToolCheckBox}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="" Style="{StaticResource GlyphIconStyle}"/>
<TextBlock Text="Renew WINS registration"/>
</StackPanel>
</CheckBox>
<Button x:Name="RunRepairButton" Content="Run selected"
Style="{StaticResource ModernButton}"
Background="{StaticResource AccentBrush}"
Margin="0,10,0,0" HorizontalAlignment="Stretch"
Click="RunRepairButton_Click"/>
</StackPanel>
</Border>
<Border Grid.Column="2" Style="{StaticResource ToolCategoryCard}">
<StackPanel>
<TextBlock Text="Advanced Option" FontSize="11" FontWeight="SemiBold"
Foreground="{StaticResource TextSecondaryBrush}" Margin="0,0,0,6"/>
<CheckBox x:Name="ResetFirewallCheck" Style="{StaticResource ToolCheckBox}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="" Style="{StaticResource GlyphIconStyle}"/>
<TextBlock Text="Reset firewall"/>
</StackPanel>
</CheckBox>
<CheckBox x:Name="ResetProxyCheck" Style="{StaticResource ToolCheckBox}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="" Style="{StaticResource GlyphIconStyle}"/>
<TextBlock Text="Reset proxy config"/>
</StackPanel>
</CheckBox>
<CheckBox x:Name="RepairSslCheck" Style="{StaticResource ToolCheckBox}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="" Style="{StaticResource GlyphIconStyle}"/>
<TextBlock Text="Repair SSL / crypto"/>
</StackPanel>
</CheckBox>
<CheckBox x:Name="RestoreHostsCheck" Style="{StaticResource ToolCheckBox}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="" Style="{StaticResource GlyphIconStyle}"/>
<TextBlock Text="Restore hosts file"/>
</StackPanel>
</CheckBox>
<CheckBox x:Name="NetworkVisibilityCheck" Style="{StaticResource ToolCheckBox}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="" Style="{StaticResource GlyphIconStyle}"/>
<TextBlock Text="Network visibility"/>
</StackPanel>
</CheckBox>
<Button x:Name="RunAdvancedButton" Content="Run selected"
Style="{StaticResource ModernButton}"
Background="{StaticResource AccentBrush}"
Margin="0,10,0,0" HorizontalAlignment="Stretch"
Click="RunAdvancedButton_Click"/>
</StackPanel>
</Border>
</Grid>
<Border Grid.Row="1" Style="{StaticResource ToolCategoryCard}" Margin="0,10,0,0">
<DockPanel LastChildFill="True">
<TextBlock DockPanel.Dock="Top" Text="Activity log" FontSize="11" FontWeight="SemiBold"
Foreground="{StaticResource TextSecondaryBrush}" Margin="0,0,0,6"/>
<ScrollViewer VerticalScrollBarVisibility="Auto">
<ItemsControl x:Name="ToolLogList">
<ItemsControl.ItemTemplate>
<DataTemplate>
<TextBlock Text="{Binding}" Style="{StaticResource LogEntryText}"/>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
</ScrollViewer>
</DockPanel>
</Border>
</Grid>
</Grid>
</Grid>
</Border>
</Window>