nitai/projects
rblxtool / src / ui / RblxTool / Views / SweepPage.xaml
127 lines · 6.6 KB Raw
1<Page
2 x:Class="RblxTool.Views.SweepPage"
3 xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
4 xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
5 xmlns:models="using:RblxTool.Models">
6
7 <Grid Padding="{StaticResource PagePadding}" RowSpacing="16">
8 <Grid.RowDefinitions>
9 <RowDefinition Height="Auto" />
10 <RowDefinition Height="Auto" />
11 <RowDefinition Height="Auto" />
12 <RowDefinition Height="*" />
13 </Grid.RowDefinitions>
14
15 <TextBlock Style="{StaticResource SectionTitle}" Text="Free Sweep" />
16
17 <Border Grid.Row="1" Style="{StaticResource CardBorder}">
18 <Grid ColumnSpacing="20" RowSpacing="12">
19 <Grid.ColumnDefinitions>
20 <ColumnDefinition Width="*" />
21 <ColumnDefinition Width="*" />
22 <ColumnDefinition Width="*" />
23 <ColumnDefinition Width="Auto" />
24 </Grid.ColumnDefinitions>
25 <Grid.RowDefinitions>
26 <RowDefinition Height="Auto" />
27 <RowDefinition Height="Auto" />
28 </Grid.RowDefinitions>
29
30 <StackPanel>
31 <TextBlock Style="{StaticResource FieldLabel}" Text="Max price (Robux)" />
32 <NumberBox x:Name="MaxPriceBox" Minimum="0" Value="0" SpinButtonPlacementMode="Compact" />
33 </StackPanel>
34 <StackPanel Grid.Column="1">
35 <TextBlock Style="{StaticResource FieldLabel}" Text="Pages per catalog stream" />
36 <NumberBox x:Name="PagesBox" Minimum="1" Maximum="500" Value="64" SpinButtonPlacementMode="Compact" />
37 </StackPanel>
38 <StackPanel Grid.Column="2">
39 <TextBlock Style="{StaticResource FieldLabel}" Text="Stop after N finds (0 = no limit)" />
40 <NumberBox x:Name="LimitBox" Minimum="0" Value="0" SpinButtonPlacementMode="Compact" />
41 </StackPanel>
42
43 <StackPanel Grid.Row="1" Orientation="Horizontal" Spacing="8">
44 <StackPanel>
45 <TextBlock Style="{StaticResource FieldLabel}" Text="Scan" />
46 <NumberBox x:Name="ScanThreadsBox" Width="80" Minimum="1" Maximum="64" Value="8" />
47 </StackPanel>
48 <StackPanel>
49 <TextBlock Style="{StaticResource FieldLabel}" Text="Detail" />
50 <NumberBox x:Name="DetailThreadsBox" Width="80" Minimum="1" Maximum="32" Value="6" />
51 </StackPanel>
52 <StackPanel>
53 <TextBlock Style="{StaticResource FieldLabel}" Text="Buy" />
54 <NumberBox x:Name="BuyThreadsBox" Width="80" Minimum="1" Maximum="16" Value="3" />
55 </StackPanel>
56 </StackPanel>
57
58 <StackPanel Grid.Row="1" Grid.Column="1" Grid.ColumnSpan="2" Orientation="Horizontal" Spacing="16" VerticalAlignment="Bottom">
59 <ToggleSwitch x:Name="BuyToggle" Header="Purchase" IsOn="True" />
60 <ToggleSwitch x:Name="DryRunToggle" Header="Dry run" />
61 <ToggleSwitch x:Name="SkipOwnedToggle" Header="Skip owned" IsOn="True" />
62 <ToggleSwitch x:Name="CollectiblesToggle" Header="Collectibles" IsOn="True" />
63 </StackPanel>
64
65 <StackPanel Grid.Row="1" Grid.Column="3" Orientation="Horizontal" Spacing="8" VerticalAlignment="Bottom">
66 <Button x:Name="StartButton" Click="OnStart" Content="Start sweep" Style="{StaticResource AccentButtonStyle}" />
67 <Button x:Name="StopButton" Click="OnStop" Content="Stop" IsEnabled="False" />
68 </StackPanel>
69 </Grid>
70 </Border>
71
72 <Border Grid.Row="2" Style="{StaticResource CardBorder}">
73 <Grid ColumnSpacing="24">
74 <Grid.ColumnDefinitions>
75 <ColumnDefinition Width="*" />
76 <ColumnDefinition Width="*" />
77 <ColumnDefinition Width="*" />
78 <ColumnDefinition Width="*" />
79 <ColumnDefinition Width="*" />
80 </Grid.ColumnDefinitions>
81 <StackPanel>
82 <TextBlock Style="{StaticResource FieldLabel}" Text="Scanned" />
83 <TextBlock x:Name="ScannedText" Style="{StaticResource MetricValue}" Text="0" />
84 </StackPanel>
85 <StackPanel Grid.Column="1">
86 <TextBlock Style="{StaticResource FieldLabel}" Text="Free found" />
87 <TextBlock x:Name="MatchedText" Style="{StaticResource MetricValue}" Text="0" />
88 </StackPanel>
89 <StackPanel Grid.Column="2">
90 <TextBlock Style="{StaticResource FieldLabel}" Text="Purchased" />
91 <TextBlock x:Name="PurchasedText" Style="{StaticResource MetricValue}" Text="0" />
92 </StackPanel>
93 <StackPanel Grid.Column="3">
94 <TextBlock Style="{StaticResource FieldLabel}" Text="Requests" />
95 <TextBlock x:Name="RequestsText" Style="{StaticResource MetricValue}" Text="0" />
96 </StackPanel>
97 <StackPanel Grid.Column="4">
98 <TextBlock Style="{StaticResource FieldLabel}" Text="Avg latency" />
99 <TextBlock x:Name="LatencyText" Style="{StaticResource MetricValue}" Text="0 ms" />
100 </StackPanel>
101 </Grid>
102 </Border>
103
104 <Border Grid.Row="3" Style="{StaticResource CardBorder}">
105 <ListView
106 x:Name="FeedList"
107 IncrementalLoadingTrigger="Edge"
108 ScrollViewer.IsVerticalScrollChainingEnabled="False"
109 SelectionMode="None">
110 <ListView.ItemContainerStyle>
111 <Style TargetType="ListViewItem">
112 <Setter Property="MinHeight" Value="0" />
113 <Setter Property="Padding" Value="8,2,8,2" />
114 </Style>
115 </ListView.ItemContainerStyle>
116 <ListView.ItemTemplate>
117 <DataTemplate x:DataType="models:FeedLine">
118 <TextBlock
119 Style="{StaticResource LogText}"
120 Foreground="{x:Bind Brush}"
121 Text="{x:Bind Text}" />
122 </DataTemplate>
123 </ListView.ItemTemplate>
124 </ListView>
125 </Border>
126 </Grid>
127</Page>