Skip to content

Commit

Permalink
Updated Advocate
Browse files Browse the repository at this point in the history
Updated MDL Shit
Updated Thunderstore UI
Added and finalized smart log flagger
  • Loading branch information
BigSpice committed Nov 13, 2022
1 parent 8d226de commit 897a999
Show file tree
Hide file tree
Showing 10 changed files with 59 additions and 62 deletions.
38 changes: 6 additions & 32 deletions VTOL_2.0.0/MainWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -202,8 +202,8 @@

<StackPanel Orientation="Horizontal"
HorizontalAlignment="Center"
VerticalAlignment="Top" Height="30" Width="104" Margin="0,-2,0,0">
<ui:Button x:Name="Log_Folder_warning" Template="{DynamicResource ButtonControlTemplate1}" Background="#99464646" Padding="0,0,0,0" KeyboardNavigation.IsTabStop="False" Height="35" Width="35" BorderThickness="0,0,0,0" ClickMode="Press" ToolTip="A New Log Has been Detected! , Please Click me to open Your Logs Folder!" Visibility="Visible" Click="Log_Folder_warning_Click"
VerticalAlignment="Top" Height="30" Width="110" Margin="0,-2,0,0">
<ui:Button x:Name="Log_Folder_warning" Template="{DynamicResource ButtonControlTemplate1}" Background="#99464646" Padding="0,0,0,0" KeyboardNavigation.IsTabStop="False" Height="35" Width="35" BorderThickness="0,0,0,0" ClickMode="Press" ToolTip="{x:Static properties:Language.MainWindow_NewLogChangesHaveBeenDetectedPleaseClickMeToOpenYourLogsFolder}" Visibility="Hidden" Click="Log_Folder_warning_Click"
>
<Button.LayoutTransform>
<TransformGroup>
Expand Down Expand Up @@ -233,7 +233,7 @@
</ui:SymbolIcon>
</ui:Button>
<Button x:Name="MaximizeButton" Template="{DynamicResource ButtonControlTemplate1}"
KeyboardNavigation.IsTabStop="False" Height="34" Width="34" BorderThickness="0,0,0,0" Click="MaximizeButton_Click" Background="#99464646" Padding="0,0,0,0" Margin="10,0,1,0" ClickMode="Press"
KeyboardNavigation.IsTabStop="False" Height="34" Width="34" BorderThickness="0,0,0,0" Click="MaximizeButton_Click" Background="#99464646" Padding="0,0,0,0" Margin="14,0,1,0" ClickMode="Press"

>
<Button.LayoutTransform>
Expand Down Expand Up @@ -275,39 +275,13 @@
</Button>
</StackPanel>
</Grid>
<Border PreviewMouseLeftButtonDown="Grid_PreviewMouseLeftButtonDown" Margin="0,-7,109,0" Background="#00000000" />
<!--<Grid
x:Name="RootWelcomeGrid"
Grid.Row="1"
Visibility="Hidden">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid Grid.Column="0">
<Image
MaxWidth="180"
RenderOptions.BitmapScalingMode="HighQuality"
Source="/Resources/Icons/Main_UI/Northstar-512.ico" />
</Grid>
<StackPanel Grid.Column="1" VerticalAlignment="Center">
<ui:ProgressRing IsIndeterminate="True" />
<TextBlock
Margin="0,12,0,0"
FontSize="16"
FontWeight="Medium"
Text="Preparing app for you."
TextAlignment="Center"
TextWrapping="Wrap" />
</StackPanel>
</Grid>-->
<Border PreviewMouseLeftButtonDown="Grid_PreviewMouseLeftButtonDown" Margin="0,-7,115,0" Background="#00000000" />

</Grid>


<ui:Snackbar x:Name="Snackbar" Grid.Column="1" Margin="197,608,197,0" VerticalAlignment="Top" MessageForeground="White" IconForeground="White" Timeout="5000" Height="60" Content="" Icon="Info24" FontSize="14" AllowDrop="False" />
<!--<hc:Badge Content="" HorizontalAlignment="Left" Margin="37,114,0,0" VerticalAlignment="Top" BadgeMargin="0,0,0,0" Status="Processing" Height="10" Foreground="{x:Null}" Background="{Binding Source={x:Static SystemParameters.WindowGlassBrush}}" BorderBrush="{x:Null}"/>
<hc:Badge Content="" HorizontalAlignment="Left" Margin="37,175,0,0" VerticalAlignment="Top" BadgeMargin="0,0,0,0" Status="Processing" Height="10" Foreground="{x:Null}" Background="{Binding Source={x:Static SystemParameters.WindowGlassBrush}}" BorderBrush="{x:Null}"/>-->


</Grid>


Expand Down
2 changes: 2 additions & 0 deletions VTOL_2.0.0/MainWindow.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -521,6 +521,8 @@ private void Log_Folder_warning_Click(object sender, RoutedEventArgs e)
info.Arguments = args;
Process.Start(info);
Properties.Settings.Default.LOG_Folder_Counter = Directory.GetFiles(User_Settings_Vars.NorthstarInstallLocation + @"R2Northstar\logs\").Length;
Properties.Settings.Default.Save();

Log_Folder_warning.Visibility = Visibility.Hidden;
}

Expand Down
4 changes: 2 additions & 2 deletions VTOL_2.0.0/Pages/Page_Home.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,9 @@
</ControlTemplate>
</Page.Resources>

<ScrollViewer x:Name="Scroller" ScrollChanged="Scroller_ScrollChanged" VerticalScrollBarVisibility="Hidden">
<ScrollViewer x:Name="Scroller" ScrollChanged="Scroller_ScrollChanged" VerticalScrollBarVisibility="Hidden" UseLayoutRounding="True">

<Grid Background="{ui:ThemeResource}" Height="660">
<Grid Background="{ui:ThemeResource}" Height="660" UseLayoutRounding="True">

<Image x:Name="Image" Source="/Resources/Backgrounds/62f29dba743d3.jpg" Stretch="UniformToFill" MouseEnter="Image_MouseEnter" Visibility="Visible"

Expand Down
3 changes: 2 additions & 1 deletion VTOL_2.0.0/Pages/Page_Home.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -312,9 +312,10 @@ public Page_Home()
if (Directory.Exists(User_Settings_Vars.NorthstarInstallLocation + @"R2Northstar\logs\") && Properties.Settings.Default.LOG_Folder_Counter < 1)
{
Properties.Settings.Default.LOG_Folder_Counter = Directory.GetFiles(User_Settings_Vars.NorthstarInstallLocation + @"R2Northstar\logs\").Length;

Properties.Settings.Default.Save();

}
Check_Log_Folder();

}
public bool TryUnzipFile(
Expand Down
33 changes: 19 additions & 14 deletions VTOL_2.0.0/Pages/Page_Thunderstore.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
xmlns:cntrls="clr-namespace:VTOL"

d:DesignHeight="670" d:DesignWidth="1148"
Title="Page_Thunderstore">
Title="Page_Thunderstore" UseLayoutRounding="True">
<Page.Resources>
<local:NegatingConverter x:Key="NegatingConverter" />
<Storyboard x:Key="slide">
Expand All @@ -22,7 +22,7 @@
RepeatBehavior="Forever"/>
</Storyboard>
</Page.Resources>
<Grid Focusable="True" OverridesDefaultStyle="True" ClipToBounds="True" Unloaded="Grid_Unloaded" GotFocus="Grid_GotFocus">
<Grid Focusable="True" OverridesDefaultStyle="True" ClipToBounds="True" Unloaded="Grid_Unloaded" GotFocus="Grid_GotFocus" UseLayoutRounding="True">
<ui:TextBox x:Name="Search_Bar_Suggest_Mods" TextWrapping="NoWrap" Height="36" Text="~Search" BorderThickness="0,0,0,0" Icon="Search48" GotFocus="Search_Bar_Suggest_Mods_GotFocus" LostFocus="Search_Bar_Suggest_Mods_LostFocus" Background="{x:Null}" TextChanged="Search_Bar_Suggest_Mods_TextChanged" Padding="0,8,0,7" Margin="48,135,547,0" VerticalAlignment="Top" KeyUp="Search_Bar_Suggest_Mods_KeyUp" Foreground="#34FFFFFF" IconForeground="#34FFFFFF" />
<ComboBox x:Name="Sort" Margin="0,136,320,0" Background="{x:Null}" BorderThickness="0,0,0,1" Height="36" VerticalAlignment="Top" BorderBrush="#82FFFFFF" SelectedIndex="-1" SelectionChanged="Sort_SelectionChanged" Padding="10,9,10,4.3" VerticalContentAlignment="Bottom" MinHeight="0" ScrollViewer.VerticalScrollBarVisibility="Auto" IsTextSearchEnabled="False" LostFocus="Sort_LostFocus" Width="224" UseLayoutRounding="True" Grid.IsSharedSizeScope="True" HorizontalAlignment="Right" MinWidth="225">
<ComboBoxItem Name="Name">Name</ComboBoxItem>
Expand All @@ -48,8 +48,7 @@

</Image>

<ui:VirtualizingItemsControl x:Name="Thunderstore_List" VirtualizingPanel.IsVirtualizing="True" VirtualizingPanel.VirtualizationMode="Recycling" VirtualizingPanel.ScrollUnit="Pixel" ItemsSource="{Binding itemsList}" Margin="35,174,35,54" Background="#994E4E4E" ScrollViewer.CanContentScroll="True" Foreground="White" Width="1078" Height="445" CacheLengthUnit="Pixel" Padding="0,0,0,5">

<ui:VirtualizingItemsControl x:Name="Thunderstore_List" VirtualizingPanel.IsVirtualizing="True" VirtualizingPanel.VirtualizationMode="Recycling" VirtualizingPanel.ScrollUnit="Pixel" ItemsSource="{Binding itemsList}" Margin="35,174,35,0" ScrollViewer.CanContentScroll="True" Foreground="White" Width="1078" Height="445" CacheLengthUnit="Pixel" UseLayoutRounding="True" ScrollViewer.VerticalScrollBarVisibility="Visible" VerticalContentAlignment="Stretch" HorizontalContentAlignment="Stretch" VerticalAlignment="Top" Background="#E85A5A5A">
<!--<ui:CardExpander
HorizontalContentAlignment="Center"
Expand Down Expand Up @@ -94,33 +93,38 @@
</ui:CardExpander>-->
<ui:VirtualizingItemsControl.ItemTemplate>
<DataTemplate>

<Grid Margin="3,3,3,8" Width="255" Height="286" HorizontalAlignment="Center" MouseMove="StackPanel_GotFocus" MouseEnter="Grid_MouseEnter" MouseLeave="Grid_MouseLeave">
<Grid Margin="3,3,3,8" Width="255" Height="286" HorizontalAlignment="Center" MouseMove="StackPanel_GotFocus" MouseEnter="Grid_MouseEnter" MouseLeave="Grid_MouseLeave" UseLayoutRounding="True">



<Border CornerRadius="5,5,5,5" >
<Border.Background>
<ImageBrush ImageSource="{Binding Icon}" Stretch="UniformToFill" />

<Image x:Name="Ts_Image" Source="{Binding Icon}" Stretch="UniformToFill" Height="Auto" GotFocus="Ts_Image_GotFocus" LostFocus="Ts_Image_LostFocus" MouseEnter="Ts_Image_MouseEnter" Width="Auto" HorizontalAlignment="Center" SnapsToDevicePixels="True"/>
</Border.Background>
</Border>
<!--<Image x:Name="Ts_Image" Source="{Binding Icon}" Stretch="UniformToFill" Height="Auto" GotFocus="Ts_Image_GotFocus" LostFocus="Ts_Image_LostFocus" MouseEnter="Ts_Image_MouseEnter" Width="Auto" HorizontalAlignment="Center" RenderOptions.BitmapScalingMode="NearestNeighbor" UseLayoutRounding="True"/>-->



<Border Width="255" Margin="0,205,0,0" HorizontalAlignment="Center" Background="#BF000000" CornerRadius="5,5,0,0" ></Border>
<Border Width="255" Margin="0,205,0,0" HorizontalAlignment="Center" Background="#BF000000" CornerRadius="9,9,4,4" ></Border>
<StackPanel Margin="0,205,0,0" >




<TextBlock TextWrapping="WrapWithOverflow" TextTrimming="CharacterEllipsis"
<TextBlock TextWrapping="Wrap" TextTrimming="CharacterEllipsis"
Text="{Binding Name}"
HorizontalAlignment="Left" FontSize="16" Width="252" TextAlignment="Left" FontStretch="Normal" FontWeight="Bold" Height="33" Margin="5,0,0,0" Background="{x:Null}" />
HorizontalAlignment="Left" FontSize="16" Width="245" TextAlignment="Left" FontStretch="Normal" FontWeight="Bold" Height="48" Margin="5,1,0,0" Background="{x:Null}" />

<!--<hc:RunningBlock Content="{Binding Name}" FontSize="20" Runaway="True" IsRunning="False" AutoRun="True" IsEnabled="False" IsHitTestVisible="False" IsTabStop="False" Focusable="False" Foreground="White" OverridesDefaultStyle="True" ScrollViewer.VerticalScrollBarVisibility="Disabled"/>-->



<TextBlock TextAlignment="Left" Text="{Binding Tag}" Margin="5,6,5,6" FontSize="12" Background="{x:Null}" Foreground="#FFFFF1E6" Width="250" HorizontalAlignment="Left" FontStyle="Italic" TextWrapping="Wrap" Height="19"/>
<TextBlock TextAlignment="Left" Text="{Binding Tag}" Margin="5,-4,5,6" FontSize="12" Background="{x:Null}" Foreground="#FFFFF1E6" Width="245" HorizontalAlignment="Left" FontStyle="Italic" TextWrapping="Wrap" Height="32"/>

</StackPanel>

<hc:SimplePanel Background="Black" Opacity="0">
<Border Background="#991B1B1B">
<ProgressBar Value="0" SmallChange="0.1" Foreground="#6600714F" Height="286" Background="{x:Null}" IsHitTestVisible="False" IsTabStop="False"/>
Expand All @@ -132,15 +136,15 @@
</Rectangle>-->
<TextBlock TextAlignment="Left" Text="{Binding owner, StringFormat={}{0:From :}}" Margin="10,3,10,0" FontSize="14" Background="{x:Null}" Foreground="#FFABABAB" VerticalAlignment="Top" Height="19"/>
<TextBlock TextAlignment="Left" Text="{Binding owner, StringFormat={}{0:From :}}" Margin="10,8,10,0" FontSize="14" Background="{x:Null}" Foreground="#FFABABAB" VerticalAlignment="Top" Height="19"/>



<Canvas ClipToBounds="True" Name="canMain" Margin="10,31,10,161" Background="#FF131313" Loaded="canMain_IsVisibleChanged" >
<TextBlock Name="tbmarquee" Foreground="White" Text="{Binding description}" TextWrapping="Wrap" FontSize="14" Width="235" Height="94" Padding="5,5,5,5" ScrollViewer.CanContentScroll="True" ></TextBlock>
</Canvas>

<ui:Button x:Name="Install_Bttn_Thunderstore" Margin="130,250,10,0" Background="#FF005D42" HorizontalAlignment="Stretch" Height="29" Content="Install" FontSize="14" Icon="ArrowDownload16" BorderBrush="{x:Null}" VerticalAlignment="Top" Padding="0,0,0,0" Tag="{Binding download_url}" Click="Install_Bttn_Thunderstore_Click" ToolTip ="{Binding Tag}"/>
<ui:Button x:Name="Install_Bttn_Thunderstore" Margin="130,250,10,0" Background="#FF005D42" HorizontalAlignment="Stretch" Height="29" Content="Install" FontSize="14" Icon="ArrowDownload16" BorderBrush="{x:Null}" VerticalAlignment="Top" Padding="0,0,0,0" Tag="{Binding download_url}" Click="Install_Bttn_Thunderstore_Click" ToolTip ="{Binding Tag}" ToolTipService.IsEnabled="False"/>
<TextBlock TextAlignment="Left" Text="{Binding date_created}" Margin="10,161,10,107" Background="{x:Null}" Foreground="#FFC7C7C7" FontSize="11" RenderTransformOrigin="0.5,0.5">
<TextBlock.RenderTransform>
<TransformGroup>
Expand Down Expand Up @@ -190,9 +194,10 @@

</Grid>


</DataTemplate>
</ui:VirtualizingItemsControl.ItemTemplate>


<!--<ListBox.ItemContainerStyle>
<Style TargetType="ListBoxItem">
Expand Down
Loading

0 comments on commit 897a999

Please sign in to comment.