wabbajack/Wabbajack.App.Wpf/Views/MainWindow.xaml
Luca a87f8dac7f
New Features from External Contributors [Merged to Internal Test Branch so Tests can run!] (#2325)
* added enderalse GOGID

* Fix readme opening twice when loading last modlist

* Edit Wabbajack CLI button text

* Cancel running downloads when shutting down application

* Add resume support for IHttpDownloader

* Add resume support for manual downloads

* Update CHANGELOG.md

* Improve game selection to only show games with results combined with the amount of lists

* Undo accidental removal of loading settings

* Add more tooltips and improve existing ones

* Update CHANGELOG.md

* Main test external pull readme fix (#2335)

* Fix SelectedGameType crashing Wabbajack when no settings are present yet, fix readme being clickable when not specified resulting in crash

* Add readme fix to CHANGELOG, fix typo

* Add readme button fix to changelog

---------

Co-authored-by: UrbanCMC <UrbanCMC@web.de>
Co-authored-by: Angad <angadmisra28@gmail.com>
Co-authored-by: trawzified <55751269+tr4wzified@users.noreply.github.com>
Co-authored-by: Timothy Baldridge <tbaldridge@gmail.com>
2023-05-07 14:32:18 -06:00

102 lines
5.0 KiB
XML

<mahapps:MetroWindow
x:Class="Wabbajack.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:icon="http://metro.mahapps.com/winfx/xaml/iconpacks"
xmlns:local="clr-namespace:Wabbajack"
xmlns:mahapps="clr-namespace:MahApps.Metro.Controls;assembly=MahApps.Metro"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:viewModels="clr-namespace:Wabbajack.View_Models"
xmlns:views="clr-namespace:Wabbajack.Views"
ShowTitleBar="False"
Title="WABBAJACK"
Width="1280"
Height="960"
MinWidth="850"
MinHeight="650"
Closing="Window_Closing"
RenderOptions.BitmapScalingMode="HighQuality"
ResizeMode="CanResize"
Style="{StaticResource {x:Type Window}}"
TitleBarHeight="25"
UseLayoutRounding="True"
WindowTitleBrush="{StaticResource MahApps.Brushes.Accent}"
mc:Ignorable="d">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"></RowDefinition>
<RowDefinition Height="*"></RowDefinition>
<RowDefinition Height="Auto"></RowDefinition>
</Grid.RowDefinitions>
<Grid Grid.Row="0" Margin="5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"></ColumnDefinition>
<ColumnDefinition Width="*"></ColumnDefinition>
<ColumnDefinition Width="Auto"></ColumnDefinition>
<ColumnDefinition Width="140"></ColumnDefinition>
</Grid.ColumnDefinitions>
<TextBlock Grid.Column="0" FontSize="16" Margin="0, 0, 8, 0" Name="AppName"></TextBlock>
<TextBlock Grid.Column="1" FontSize="16" Margin="5, 0" Name="ResourceUsage" HorizontalAlignment="Right" VerticalAlignment="Center"></TextBlock>
<Button Grid.Column="2" Name="SettingsButton" ToolTip="Open Wabbajack settings">
<icon:Material Kind="Cog"></icon:Material>
</Button>
</Grid>
<ContentPresenter Grid.Row="1" Content="{Binding ActivePane}">
<ContentPresenter.Resources>
<DataTemplate DataType="{x:Type local:CompilerVM}">
<local:CompilerView ViewModel="{Binding}" />
</DataTemplate>
<DataTemplate DataType="{x:Type local:InstallerVM}">
<local:InstallationView ViewModel="{Binding}" />
</DataTemplate>
<DataTemplate DataType="{x:Type local:ModeSelectionVM}">
<local:ModeSelectionView ViewModel="{Binding}" />
</DataTemplate>
<DataTemplate DataType="{x:Type local:ModListGalleryVM}">
<local:ModListGalleryView ViewModel="{Binding}" />
</DataTemplate>
<DataTemplate DataType="{x:Type local:WebBrowserVM}">
<local:WebBrowserView />
</DataTemplate>
<DataTemplate DataType="{x:Type local:SettingsVM}">
<local:SettingsView ViewModel="{Binding}" />
</DataTemplate>
<DataTemplate DataType="{x:Type viewModels:ModListContentsVM}">
<local:ModListContentsView ViewModel="{Binding}" />
</DataTemplate>
</ContentPresenter.Resources>
</ContentPresenter>
</Grid>
<mahapps:MetroWindow.RightWindowCommands>
<mahapps:WindowCommands>
<mahapps:WindowCommands.Resources>
<Style BasedOn="{StaticResource IconBareButtonStyle}" TargetType="Button" />
</mahapps:WindowCommands.Resources>
<Button
Margin="5,0"
Command="{Binding CopyVersionCommand}"
Content="{Binding VersionDisplay}">
<Button.ToolTip>
<ToolTip Content="Wabbajack Version&#x0a;Click to copy to clipboard" />
</Button.ToolTip>
</Button>
<Button Grid.Column="1"
Margin="5,0"
Command="{Binding OpenSettingsCommand}">
<icon:PackIconMaterial
Width="17"
Height="17"
Kind="Cog" />
</Button>
</mahapps:WindowCommands>
</mahapps:MetroWindow.RightWindowCommands>
<Window.TaskbarItemInfo>
<TaskbarItemInfo x:Name="TaskbarItemInfoControl"></TaskbarItemInfo>
</Window.TaskbarItemInfo>
</mahapps:MetroWindow>