Files
OpenBullet/OpenBullet/Pages/Main/RunnerManager.xaml
T

141 lines
8.9 KiB
XML

<Page x:Class="OpenBullet.RunnerManager"
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:OpenBullet"
mc:Ignorable="d"
d:DesignHeight="550" d:DesignWidth="780"
Title="RunnerManager">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="40" />
<RowDefinition Height="*" />
</Grid.RowDefinitions>
<TextBlock x:Name="helpMessageLabel" Grid.Row="0" Grid.RowSpan="2" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="25" FontWeight="Bold" Foreground="{DynamicResource ForegroundMain}" TextAlignment="Center" >
Welcome to Open Bullet!<LineBreak/>
Create a Runner to get started.
</TextBlock>
<StackPanel Grid.Row="0" Orientation="Horizontal">
<Button x:Name="addRunnerButton" Click="addRunnerButton_Click">
<StackPanel Orientation="Horizontal">
<Image Source="/Images/Icons/plus.png" Width="20" />
<TextBlock VerticalAlignment="Center" Margin="5 0">New</TextBlock>
</StackPanel>
</Button>
<Button x:Name="startAllRunnersButton" Click="startAllRunnersButton_Click">
<StackPanel Orientation="Horizontal">
<Image Source="/Images/Icons/play.png" Width="20" />
<TextBlock VerticalAlignment="Center" Margin="5 0">Start All</TextBlock>
</StackPanel>
</Button>
<Button x:Name="stopAllRunnersButton" Click="stopAllRunnersButton_Click">
<StackPanel Orientation="Horizontal">
<Image Source="/Images/Icons/stop.png" Width="20" />
<TextBlock VerticalAlignment="Center" Margin="5 0">Stop All</TextBlock>
</StackPanel>
</Button>
<Button x:Name="removeAllRunnersButton" Click="removeAllRunnersButton_Click">
<StackPanel Orientation="Horizontal">
<Image Source="/Images/Icons/delete.png" Width="20" />
<TextBlock VerticalAlignment="Center" Margin="5 0">Remove All</TextBlock>
</StackPanel>
</Button>
<Label Content="TIP: Click on a Runner to switch to the detailed view"/>
</StackPanel>
<ScrollViewer Grid.Row="1" VerticalScrollBarVisibility="Auto">
<ItemsControl x:Name="runnersControl" ItemsSource="{Binding Runners}">
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<StackPanel Orientation="Vertical" Margin="0 10"/>
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
<ItemsControl.ItemTemplate>
<DataTemplate>
<Border BorderBrush="{DynamicResource ForegroundMain}" BorderThickness="1">
<Grid x:Name="runnerInstanceGrid" Tag="{Binding Id}" MouseDown="runnerInstanceGrid_MouseDown" >
<Grid.Style>
<Style TargetType="{x:Type Grid}">
<Setter Property="Background" Value="Transparent"/>
<Style.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter Property="Background" Value="{DynamicResource BackgroundSecondary}"/>
</Trigger>
</Style.Triggers>
</Style>
</Grid.Style>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="auto"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<!--FIRST ROW-->
<StackPanel Orientation="Horizontal" Grid.Row="0" Grid.Column="0" Grid.ColumnSpan="2">
<Label Content="Config: " FontWeight="Bold" MouseDown="selectConfig_MouseDown"/>
<Label Content="{Binding Runner.ConfigName}" MouseDown="selectConfig_MouseDown"/>
<Label Content="Wordlist: " FontWeight="Bold" MouseDown="selectWordlist_MouseDown"/>
<Label Content="{Binding Runner.WordlistName}" MouseDown="selectWordlist_MouseDown"/>
<Label Content="Bots: " FontWeight="Bold" MouseDown="selectBots_MouseDown"/>
<Label Content="{Binding Runner.BotsNumber}" MouseDown="selectBots_MouseDown"/>
<Label Content="Proxies: " FontWeight="Bold" MouseDown="selectProxies_MouseDown"/>
<Label Content="{Binding Runner.ProxyMode}" MouseDown="selectProxies_MouseDown"/>
<Label Content="STATUS: " FontWeight="Bold" Foreground="{DynamicResource ForegroundRetry}"/>
<Label Content="{Binding Runner.WorkerStatus}" Foreground="{DynamicResource ForegroundRetry}"/>
</StackPanel>
<!--SECOND ROW-->
<StackPanel Orientation="Horizontal" Grid.Row="1" Grid.Column="0" >
<Label Content="Hits: " FontWeight="Bold" Foreground="{DynamicResource ForegroundGood}"/>
<Label Content="{Binding Runner.HitCount}" Foreground="{DynamicResource ForegroundGood}"/>
<Label Content="Custom: " FontWeight="Bold" Foreground="{DynamicResource ForegroundCustom}"/>
<Label Content="{Binding Runner.CustomCount}" Foreground="{DynamicResource ForegroundCustom}"/>
<Label Content="ToCheck: " FontWeight="Bold" Foreground="{DynamicResource ForegroundToCheck}"/>
<Label Content="{Binding Runner.ToCheckCount}" Foreground="{DynamicResource ForegroundToCheck}"/>
<Label Content="Progress: " FontWeight="Bold"/>
<Label Content="{Binding Runner.ProgressCount}" />
<Label Content="/" />
<Label Content="{Binding Runner.WordlistSize}"/>
<Label Content="("/>
<Label Content="{Binding Runner.Progress}"/>
<Label Content="%)"/>
<Label Content="CPM" FontWeight="Bold"/>
<Label Content="{Binding Runner.CPM}" />
</StackPanel>
<StackPanel Grid.Row="1" Grid.Column="1" Orientation="Horizontal" HorizontalAlignment="Right">
<Button Tag="{Binding Id}" x:Name="startRunnerButton" Click="startRunnerButton_Click">
<StackPanel Orientation="Horizontal">
<Image Source="/Images/Icons/play.png" Width="20" />
<TextBlock VerticalAlignment="Center" Margin="5 0">Start /</TextBlock>
<Image Source="/Images/Icons/stop.png" Width="20" />
<TextBlock VerticalAlignment="Center" Margin="5 0">Stop</TextBlock>
</StackPanel>
</Button>
<Button Tag="{Binding Id}" x:Name="removeRunnerButton" Click="removeRunnerButton_Click">
<StackPanel Orientation="Horizontal">
<Image Source="/Images/Icons/minus.png" Width="20" />
<TextBlock VerticalAlignment="Center" Margin="5 0">Remove</TextBlock>
</StackPanel>
</Button>
</StackPanel>
</Grid>
</Border>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
</ScrollViewer>
</Grid>
</Page>