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
<UserControl x:Class="AdamsToolkit.Views.TimerResolutionView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition/>
</Grid.RowDefinitions>
<!-- cabeçalho -->
<StackPanel Grid.Row="0" Margin="0,0,0,14">
<TextBlock Text="Timer Resolution" Style="{StaticResource H1}"/>
<TextBlock Style="{StaticResource Muted}" Margin="0,4,0,0"
Text="Sobe a precisão do relógio interno do Windows de ~15.6 ms para 0.5 ms — menos latência e frametimes mais estáveis em jogo. Sem admin, sem reboot."/>
</StackPanel>
<!-- leituras -->
<UniformGrid Grid.Row="1" Columns="3" Margin="0,0,0,14">
<Border Style="{StaticResource Card}" Margin="0,0,12,0">
<StackPanel>
<TextBlock Text="Resolução atual" Style="{StaticResource Muted}"/>
<TextBlock x:Name="CurrentText" Style="{StaticResource H2}" Text="—" Margin="0,6,0,0"/>
</StackPanel>
</Border>
<Border Style="{StaticResource Card}" Margin="0,0,12,0">
<StackPanel>
<TextBlock Text="Mínima (padrão Windows)" Style="{StaticResource Muted}"/>
<TextBlock x:Name="MinText" Style="{StaticResource H2}" Text="—" Margin="0,6,0,0"/>
</StackPanel>
</Border>
<Border Style="{StaticResource Card}">
<StackPanel>
<TextBlock Text="Máxima (hardware)" Style="{StaticResource Muted}"/>
<TextBlock x:Name="MaxText" Style="{StaticResource H2}" Text="—" Margin="0,6,0,0"/>
</StackPanel>
</Border>
</UniformGrid>
<!-- ações -->
<Border Grid.Row="2" Style="{StaticResource Card}" Padding="18,16">
<StackPanel>
<StackPanel Orientation="Horizontal">
<Button x:Name="MaxBtn" Style="{StaticResource PrimaryButton}"
Content="⚡ Máxima (0.5 ms)" Click="Max_Click" Margin="0,0,10,0"/>
<Button x:Name="DefaultBtn" Style="{StaticResource GhostButton}"
Content="Padrão" Click="Default_Click"/>
</StackPanel>
<TextBlock x:Name="StateText" Style="{StaticResource Muted}" Margin="0,10,0,0"
Text="A precisão máxima fica ativa enquanto o Adams Toolkit estiver aberto (podes minimizar para a bandeja). Fechar a app repõe o padrão do Windows instantaneamente."/>
</StackPanel>
</Border>
</Grid>
</UserControl>