|
|
@ -12,7 +12,8 @@ |
|
|
|
xmlns:system="clr-namespace:System;assembly=System.Runtime" |
|
|
|
xmlns:system="clr-namespace:System;assembly=System.Runtime" |
|
|
|
xmlns:converters="clr-namespace:StabilityMatrix.Avalonia.Converters" |
|
|
|
xmlns:converters="clr-namespace:StabilityMatrix.Avalonia.Converters" |
|
|
|
xmlns:avalonia="clr-namespace:SpacedGridControl.Avalonia;assembly=SpacedGridControl.Avalonia" |
|
|
|
xmlns:avalonia="clr-namespace:SpacedGridControl.Avalonia;assembly=SpacedGridControl.Avalonia" |
|
|
|
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450" |
|
|
|
xmlns:markupExtensions="clr-namespace:StabilityMatrix.Avalonia.MarkupExtensions" |
|
|
|
|
|
|
|
mc:Ignorable="d" d:DesignWidth="1000" d:DesignHeight="450" |
|
|
|
x:DataType="viewModels:PackageManagerViewModel" |
|
|
|
x:DataType="viewModels:PackageManagerViewModel" |
|
|
|
x:CompileBindings="True" |
|
|
|
x:CompileBindings="True" |
|
|
|
d:DataContext="{x:Static designData:DesignData.PackageManagerViewModel}" |
|
|
|
d:DataContext="{x:Static designData:DesignData.PackageManagerViewModel}" |
|
|
@ -32,216 +33,34 @@ |
|
|
|
<ItemsRepeater.ItemTemplate> |
|
|
|
<ItemsRepeater.ItemTemplate> |
|
|
|
<DataTemplate DataType="{x:Type packageManager:PackageCardViewModel}"> |
|
|
|
<DataTemplate DataType="{x:Type packageManager:PackageCardViewModel}"> |
|
|
|
<controls:Card Padding="8" |
|
|
|
<controls:Card Padding="8" |
|
|
|
|
|
|
|
MinWidth="400" |
|
|
|
CornerRadius="8"> |
|
|
|
CornerRadius="8"> |
|
|
|
<controls:Card.Background> |
|
|
|
<controls:Card.Background> |
|
|
|
<MultiBinding Converter="{StaticResource BoolChoiceMultiConverter}"> |
|
|
|
<MultiBinding Converter="{StaticResource BoolChoiceMultiConverter}"> |
|
|
|
<Binding Path="IsRunning" /> |
|
|
|
<Binding Path="IsRunning" /> |
|
|
|
<DynamicResource ResourceKey="ThemeDarkDarkGreenColorBrush"/> |
|
|
|
<DynamicResource ResourceKey="ThemeDarkDarkGreenColorBrush" /> |
|
|
|
<DynamicResource ResourceKey="ButtonBackground"/> |
|
|
|
<DynamicResource ResourceKey="ButtonBackground" /> |
|
|
|
</MultiBinding> |
|
|
|
</MultiBinding> |
|
|
|
</controls:Card.Background> |
|
|
|
</controls:Card.Background> |
|
|
|
<Grid RowDefinitions="Auto, Auto, Auto, Auto" |
|
|
|
<Grid ColumnDefinitions="Auto, *"> |
|
|
|
ColumnDefinitions="*,Auto"> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<TextBlock Grid.Row="0" |
|
|
|
|
|
|
|
Grid.Column="0" |
|
|
|
|
|
|
|
ToolTip.Tip="{Binding Package.DisplayName, FallbackValue=''}" |
|
|
|
|
|
|
|
Text="{Binding Package.DisplayName, FallbackValue=''}" |
|
|
|
|
|
|
|
TextTrimming="WordEllipsis" |
|
|
|
|
|
|
|
TextAlignment="Left" /> |
|
|
|
|
|
|
|
<Button |
|
|
|
|
|
|
|
Grid.Row="0" |
|
|
|
|
|
|
|
Grid.Column="1" |
|
|
|
|
|
|
|
HorizontalContentAlignment="Right" |
|
|
|
|
|
|
|
HorizontalAlignment="Right" |
|
|
|
|
|
|
|
VerticalContentAlignment="Top" |
|
|
|
|
|
|
|
VerticalAlignment="Top" |
|
|
|
|
|
|
|
Padding="4,1" |
|
|
|
|
|
|
|
Margin="4,0,0,0" |
|
|
|
|
|
|
|
Classes="transparent" |
|
|
|
|
|
|
|
Width="24" |
|
|
|
|
|
|
|
BorderThickness="0"> |
|
|
|
|
|
|
|
<ui:SymbolIcon FontSize="18" Symbol="MoreVertical" /> |
|
|
|
|
|
|
|
<Button.Flyout> |
|
|
|
|
|
|
|
<MenuFlyout Placement="BottomEdgeAlignedLeft"> |
|
|
|
|
|
|
|
<MenuItem Header="{x:Static lang:Resources.Action_CheckForUpdates}" |
|
|
|
|
|
|
|
IsVisible="{Binding !IsUnknownPackage}" |
|
|
|
|
|
|
|
Command="{Binding OnLoadedAsync}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<ui:SymbolIcon Symbol="Refresh" /> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
<MenuItem |
|
|
|
|
|
|
|
Header="{OnPlatform Default={x:Static lang:Resources.Action_OpenInExplorer}, macOS={x:Static lang:Resources.Action_OpenInFinder}}" |
|
|
|
|
|
|
|
Command="{Binding OpenFolder}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<ui:SymbolIcon Symbol="OpenFolder" /> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
<MenuItem |
|
|
|
|
|
|
|
Header="{x:Static lang:Resources.Action_OpenGithub}" |
|
|
|
|
|
|
|
IsVisible="{Binding !IsUnknownPackage}" |
|
|
|
|
|
|
|
Command="{Binding OpenOnGitHubCommand}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<icons:Icon |
|
|
|
|
|
|
|
Value="fa-brands fa-github" /> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<Separator/> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<MenuItem |
|
|
|
|
|
|
|
Header="{x:Static lang:Resources.Label_PythonPackages}" |
|
|
|
|
|
|
|
IsVisible="{Binding !IsUnknownPackage}" |
|
|
|
|
|
|
|
Command="{Binding OpenPythonPackagesDialogCommand}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<icons:Icon |
|
|
|
|
|
|
|
Value="fa-brands fa-python" /> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
<MenuItem |
|
|
|
|
|
|
|
Header="Extensions" |
|
|
|
|
|
|
|
IsVisible="{Binding CanUseExtensions}" |
|
|
|
|
|
|
|
Command="{Binding OpenExtensionsDialogCommand}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<icons:Icon |
|
|
|
|
|
|
|
Value="fa-solid fa-puzzle-piece" /> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<Separator IsVisible="{Binding CanUseSharedOutput}" /> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<MenuItem Header="{x:Static lang:Resources.Label_SharedModelStrategyShort}" |
|
|
|
|
|
|
|
IsVisible="{Binding !IsUnknownPackage}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<ui:SymbolIcon Symbol="FolderLink" /> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
<!-- ReSharper disable Xaml.RedundantResource --> |
|
|
|
|
|
|
|
<MenuItem Header="Symlink" |
|
|
|
|
|
|
|
Command="{Binding ToggleSharedModelSymlink}" |
|
|
|
|
|
|
|
IsVisible="{Binding CanUseSymlinkMethod}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<CheckBox IsChecked="{Binding IsSharedModelSymlink}" |
|
|
|
|
|
|
|
Margin="8,0,0,0" |
|
|
|
|
|
|
|
Padding="0" |
|
|
|
|
|
|
|
Width="28" Height="28"> |
|
|
|
|
|
|
|
<CheckBox.RenderTransform> |
|
|
|
|
|
|
|
<ScaleTransform ScaleX="1.5" ScaleY="1.5"/> |
|
|
|
|
|
|
|
</CheckBox.RenderTransform> |
|
|
|
|
|
|
|
</CheckBox> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
<MenuItem Header="Config" |
|
|
|
|
|
|
|
Command="{Binding ToggleSharedModelConfig}" |
|
|
|
|
|
|
|
IsVisible="{Binding CanUseConfigMethod}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<CheckBox Margin="8,0,0,0" |
|
|
|
|
|
|
|
Padding="0" |
|
|
|
|
|
|
|
Width="28" Height="28" |
|
|
|
|
|
|
|
IsChecked="{Binding IsSharedModelConfig}"> |
|
|
|
|
|
|
|
<CheckBox.RenderTransform> |
|
|
|
|
|
|
|
<ScaleTransform ScaleX="1.5" ScaleY="1.5"/> |
|
|
|
|
|
|
|
</CheckBox.RenderTransform> |
|
|
|
|
|
|
|
</CheckBox> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
<MenuItem Header="None" |
|
|
|
|
|
|
|
Command="{Binding ToggleSharedModelNone}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<CheckBox IsChecked="{Binding IsSharedModelDisabled}" |
|
|
|
|
|
|
|
Margin="8,0,0,0" |
|
|
|
|
|
|
|
Padding="0" |
|
|
|
|
|
|
|
Width="28" Height="28"> |
|
|
|
|
|
|
|
<CheckBox.RenderTransform> |
|
|
|
|
|
|
|
<ScaleTransform ScaleX="1.5" ScaleY="1.5"/> |
|
|
|
|
|
|
|
</CheckBox.RenderTransform> |
|
|
|
|
|
|
|
</CheckBox> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
<!-- ReSharper enable Xaml.RedundantResource --> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
<MenuItem |
|
|
|
|
|
|
|
Header="{x:Static lang:Resources.Label_UseSharedOutputFolder}" |
|
|
|
|
|
|
|
Command="{Binding ToggleSharedOutput}" |
|
|
|
|
|
|
|
IsVisible="{Binding CanUseSharedOutput}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<CheckBox Margin="8,0,0,0" |
|
|
|
|
|
|
|
Padding="0" |
|
|
|
|
|
|
|
Width="28" Height="28" |
|
|
|
|
|
|
|
IsChecked="{Binding UseSharedOutput}"> |
|
|
|
|
|
|
|
<CheckBox.RenderTransform> |
|
|
|
|
|
|
|
<ScaleTransform ScaleX="1.5" ScaleY="1.5"/> |
|
|
|
|
|
|
|
</CheckBox.RenderTransform> |
|
|
|
|
|
|
|
</CheckBox> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
<Separator /> |
|
|
|
|
|
|
|
<MenuItem Header="{x:Static lang:Resources.Action_Uninstall}" |
|
|
|
|
|
|
|
Command="{Binding Uninstall}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<ui:SymbolIcon Symbol="Delete" /> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
</MenuFlyout> |
|
|
|
|
|
|
|
</Button.Flyout> |
|
|
|
|
|
|
|
</Button> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<TextBlock Grid.Row="1" |
|
|
|
|
|
|
|
Grid.Column="0" |
|
|
|
|
|
|
|
Grid.ColumnSpan="2" |
|
|
|
|
|
|
|
Margin="2,0,0,0" |
|
|
|
|
|
|
|
VerticalAlignment="Center" |
|
|
|
|
|
|
|
Text="{Binding InstalledVersion}" /> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<Border Grid.Row="2" |
|
|
|
|
|
|
|
Grid.Column="0" |
|
|
|
|
|
|
|
Grid.ColumnSpan="2" |
|
|
|
|
|
|
|
Margin="0,8" |
|
|
|
|
|
|
|
Background="#AA000000" |
|
|
|
|
|
|
|
IsVisible="{Binding IsRunning}" |
|
|
|
|
|
|
|
CornerRadius="4" |
|
|
|
|
|
|
|
ZIndex="1"> |
|
|
|
|
|
|
|
<Button Classes="danger" |
|
|
|
|
|
|
|
FontSize="16" |
|
|
|
|
|
|
|
MinWidth="100" |
|
|
|
|
|
|
|
MinHeight="40" |
|
|
|
|
|
|
|
Command="{Binding StopCommand}" |
|
|
|
|
|
|
|
HorizontalAlignment="Center" |
|
|
|
|
|
|
|
HorizontalContentAlignment="Center"> |
|
|
|
|
|
|
|
<StackPanel Orientation="Horizontal"> |
|
|
|
|
|
|
|
<icons:Icon Value="fa-solid fa-stop" |
|
|
|
|
|
|
|
FontSize="20" |
|
|
|
|
|
|
|
Margin="0,0,8,0"/> |
|
|
|
|
|
|
|
<TextBlock Text="{x:Static lang:Resources.Action_Stop}"/> |
|
|
|
|
|
|
|
</StackPanel> |
|
|
|
|
|
|
|
</Button> |
|
|
|
|
|
|
|
</Border> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!-- Normal packages shows image --> |
|
|
|
|
|
|
|
<controls:BetterAdvancedImage |
|
|
|
<controls:BetterAdvancedImage |
|
|
|
Grid.Row="2" |
|
|
|
|
|
|
|
Grid.Column="0" |
|
|
|
Grid.Column="0" |
|
|
|
Grid.ColumnSpan="2" |
|
|
|
Height="150" |
|
|
|
Margin="0,8,0,8" |
|
|
|
Width="150" |
|
|
|
Height="180" |
|
|
|
Margin="4, 8" |
|
|
|
Width="225" |
|
|
|
CornerRadius="8" |
|
|
|
CornerRadius="4" |
|
|
|
|
|
|
|
HorizontalAlignment="Center" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
VerticalContentAlignment="Top" |
|
|
|
VerticalContentAlignment="Top" |
|
|
|
HorizontalContentAlignment="Center" |
|
|
|
HorizontalContentAlignment="Center" |
|
|
|
Source="{Binding CardImageSource}" |
|
|
|
Source="{Binding CardImageSource}" |
|
|
|
IsVisible="{Binding !IsUnknownPackage}" |
|
|
|
IsVisible="{Binding !IsUnknownPackage}" |
|
|
|
Stretch="UniformToFill" /> |
|
|
|
Stretch="UniformToFill" /> |
|
|
|
|
|
|
|
|
|
|
|
<!-- Unknown packages panel --> |
|
|
|
|
|
|
|
<Border |
|
|
|
<Border |
|
|
|
Grid.Row="2" |
|
|
|
|
|
|
|
Grid.Column="0" |
|
|
|
Grid.Column="0" |
|
|
|
Grid.ColumnSpan="2" |
|
|
|
Height="150" |
|
|
|
Margin="0,8,0,8" |
|
|
|
Width="150" |
|
|
|
Height="180" |
|
|
|
Margin="4, 8" |
|
|
|
Width="225" |
|
|
|
CornerRadius="8" |
|
|
|
CornerRadius="4" |
|
|
|
|
|
|
|
HorizontalAlignment="Center" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
IsVisible="{Binding IsUnknownPackage}" |
|
|
|
IsVisible="{Binding IsUnknownPackage}" |
|
|
|
Background="#202020"> |
|
|
|
Background="#202020"> |
|
|
@ -252,114 +71,328 @@ |
|
|
|
TextWrapping="Wrap" |
|
|
|
TextWrapping="Wrap" |
|
|
|
Text="{x:Static lang:Resources.Label_UnknownPackage}" /> |
|
|
|
Text="{x:Static lang:Resources.Label_UnknownPackage}" /> |
|
|
|
</Border> |
|
|
|
</Border> |
|
|
|
|
|
|
|
<Grid Grid.Column="1" RowDefinitions="Auto, Auto, Auto, *" |
|
|
|
|
|
|
|
ColumnDefinitions="Auto, *"> |
|
|
|
|
|
|
|
<TextBlock Grid.Column="0" |
|
|
|
|
|
|
|
Grid.Row="0" |
|
|
|
|
|
|
|
Text="{Binding Package.DisplayName}" |
|
|
|
|
|
|
|
Margin="8,0,8,0" |
|
|
|
|
|
|
|
FontWeight="SemiBold" |
|
|
|
|
|
|
|
MaxWidth="200" |
|
|
|
|
|
|
|
TextWrapping="NoWrap" |
|
|
|
|
|
|
|
TextTrimming="CharacterEllipsis" |
|
|
|
|
|
|
|
ToolTip.Tip="{Binding Package.DisplayName}" |
|
|
|
|
|
|
|
FontSize="16" /> |
|
|
|
|
|
|
|
<TextBlock Grid.Column="0" |
|
|
|
|
|
|
|
Grid.Row="1" |
|
|
|
|
|
|
|
FontSize="13" |
|
|
|
|
|
|
|
Foreground="{DynamicResource TextControlPlaceholderForeground}" |
|
|
|
|
|
|
|
Margin="8,0,8,0" |
|
|
|
|
|
|
|
VerticalAlignment="Center" |
|
|
|
|
|
|
|
Text="{Binding InstalledVersion}" /> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<Button |
|
|
|
|
|
|
|
Grid.Row="0" |
|
|
|
|
|
|
|
Grid.Column="1" |
|
|
|
|
|
|
|
HorizontalContentAlignment="Right" |
|
|
|
|
|
|
|
HorizontalAlignment="Right" |
|
|
|
|
|
|
|
VerticalContentAlignment="Top" |
|
|
|
|
|
|
|
VerticalAlignment="Top" |
|
|
|
|
|
|
|
Padding="4" |
|
|
|
|
|
|
|
Margin="4,0,0,0" |
|
|
|
|
|
|
|
Classes="transparent" |
|
|
|
|
|
|
|
Width="24" |
|
|
|
|
|
|
|
BorderThickness="0"> |
|
|
|
|
|
|
|
<ui:SymbolIcon FontSize="18" Symbol="MoreVertical" /> |
|
|
|
|
|
|
|
<Button.Flyout> |
|
|
|
|
|
|
|
<MenuFlyout Placement="BottomEdgeAlignedLeft"> |
|
|
|
|
|
|
|
<MenuItem Header="{x:Static lang:Resources.Action_CheckForUpdates}" |
|
|
|
|
|
|
|
IsVisible="{Binding !IsUnknownPackage}" |
|
|
|
|
|
|
|
Command="{Binding OnLoadedAsync}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<ui:SymbolIcon Symbol="Refresh" /> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
<MenuItem |
|
|
|
|
|
|
|
Header="{OnPlatform Default={x:Static lang:Resources.Action_OpenInExplorer}, macOS={x:Static lang:Resources.Action_OpenInFinder}}" |
|
|
|
|
|
|
|
Command="{Binding OpenFolder}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<ui:SymbolIcon Symbol="OpenFolder" /> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
<MenuItem |
|
|
|
|
|
|
|
Header="{x:Static lang:Resources.Action_OpenGithub}" |
|
|
|
|
|
|
|
IsVisible="{Binding !IsUnknownPackage}" |
|
|
|
|
|
|
|
Command="{Binding OpenOnGitHubCommand}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<icons:Icon |
|
|
|
|
|
|
|
Value="fa-brands fa-github" /> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<Separator /> |
|
|
|
|
|
|
|
|
|
|
|
<Grid |
|
|
|
<MenuItem |
|
|
|
Grid.Row="3" |
|
|
|
Header="{x:Static lang:Resources.Label_PythonPackages}" |
|
|
|
Grid.Column="0" |
|
|
|
IsVisible="{Binding !IsUnknownPackage}" |
|
|
|
Grid.ColumnSpan="2" |
|
|
|
Command="{Binding OpenPythonPackagesDialogCommand}"> |
|
|
|
IsVisible="{Binding !IsUnknownPackage}" |
|
|
|
<MenuItem.Icon> |
|
|
|
ColumnDefinitions="*,Auto"> |
|
|
|
<icons:Icon |
|
|
|
<!-- Launch and update buttons --> |
|
|
|
Value="fa-brands fa-python" /> |
|
|
|
<Button Grid.Column="0" Classes="accent" |
|
|
|
</MenuItem.Icon> |
|
|
|
VerticalAlignment="Bottom" |
|
|
|
</MenuItem> |
|
|
|
HorizontalAlignment="Stretch" |
|
|
|
<MenuItem |
|
|
|
Command="{Binding Launch}"> |
|
|
|
Header="Extensions" |
|
|
|
<Button.IsVisible> |
|
|
|
IsVisible="{Binding CanUseExtensions}" |
|
|
|
<MultiBinding Converter="{x:Static BoolConverters.And}"> |
|
|
|
Command="{Binding OpenExtensionsDialogCommand}"> |
|
|
|
<Binding Path="!IsRunning" /> |
|
|
|
<MenuItem.Icon> |
|
|
|
<Binding Path="!IsUnknownPackage" /> |
|
|
|
<icons:Icon |
|
|
|
</MultiBinding> |
|
|
|
Value="fa-solid fa-puzzle-piece" /> |
|
|
|
</Button.IsVisible> |
|
|
|
</MenuItem.Icon> |
|
|
|
<StackPanel Orientation="Horizontal" Margin="0,2,0,2"> |
|
|
|
</MenuItem> |
|
|
|
<icons:Icon Value="fa-solid fa-rocket" |
|
|
|
|
|
|
|
Margin="0,0,8,0" |
|
|
|
<Separator IsVisible="{Binding CanUseSharedOutput}" /> |
|
|
|
FontSize="14" /> |
|
|
|
|
|
|
|
<TextBlock Text="{x:Static lang:Resources.Action_Launch}" /> |
|
|
|
<MenuItem |
|
|
|
</StackPanel> |
|
|
|
Header="{x:Static lang:Resources.Label_SharedModelStrategyShort}" |
|
|
|
</Button> |
|
|
|
IsVisible="{Binding !IsUnknownPackage}"> |
|
|
|
<Button Grid.Column="1" Classes="accent" |
|
|
|
<MenuItem.Icon> |
|
|
|
VerticalAlignment="Bottom" |
|
|
|
<ui:SymbolIcon Symbol="FolderLink" /> |
|
|
|
HorizontalAlignment="Stretch" |
|
|
|
</MenuItem.Icon> |
|
|
|
Command="{Binding Update}"> |
|
|
|
<!-- ReSharper disable Xaml.RedundantResource --> |
|
|
|
<Button.IsVisible> |
|
|
|
<MenuItem Header="Symlink" |
|
|
|
<MultiBinding Converter="{x:Static BoolConverters.And}"> |
|
|
|
Command="{Binding ToggleSharedModelSymlink}" |
|
|
|
<Binding Path="IsUpdateAvailable" /> |
|
|
|
IsVisible="{Binding CanUseSymlinkMethod}"> |
|
|
|
<Binding Path="!IsRunning" /> |
|
|
|
<MenuItem.Icon> |
|
|
|
</MultiBinding> |
|
|
|
<CheckBox IsChecked="{Binding IsSharedModelSymlink}" |
|
|
|
</Button.IsVisible> |
|
|
|
Margin="8,0,0,0" |
|
|
|
<StackPanel Orientation="Horizontal" |
|
|
|
Padding="0" |
|
|
|
Margin="10,2"> |
|
|
|
Width="28" Height="28"> |
|
|
|
<icons:Icon Value="fa-solid fa-download" |
|
|
|
<CheckBox.RenderTransform> |
|
|
|
Margin="0,0,8,0" |
|
|
|
<ScaleTransform ScaleX="1.5" ScaleY="1.5" /> |
|
|
|
FontSize="14" /> |
|
|
|
</CheckBox.RenderTransform> |
|
|
|
<TextBlock Text="{x:Static lang:Resources.Action_Update}" /> |
|
|
|
</CheckBox> |
|
|
|
</StackPanel> |
|
|
|
</MenuItem.Icon> |
|
|
|
</Button> |
|
|
|
</MenuItem> |
|
|
|
<Button Grid.Column="0" Classes="accent" |
|
|
|
<MenuItem Header="Config" |
|
|
|
VerticalAlignment="Bottom" |
|
|
|
Command="{Binding ToggleSharedModelConfig}" |
|
|
|
HorizontalAlignment="Stretch" |
|
|
|
IsVisible="{Binding CanUseConfigMethod}"> |
|
|
|
IsVisible="{Binding IsRunning}" |
|
|
|
<MenuItem.Icon> |
|
|
|
Command="{Binding NavToConsole}"> |
|
|
|
<CheckBox Margin="8,0,0,0" |
|
|
|
<StackPanel Orientation="Horizontal" |
|
|
|
Padding="0" |
|
|
|
Margin="0,2,0,2"> |
|
|
|
Width="28" Height="28" |
|
|
|
<icons:Icon Value="fa-solid fa-terminal" |
|
|
|
IsChecked="{Binding IsSharedModelConfig}"> |
|
|
|
Margin="0,0,8,0" |
|
|
|
<CheckBox.RenderTransform> |
|
|
|
FontSize="14" /> |
|
|
|
<ScaleTransform ScaleX="1.5" ScaleY="1.5" /> |
|
|
|
<TextBlock Text="Console"/> |
|
|
|
</CheckBox.RenderTransform> |
|
|
|
</StackPanel> |
|
|
|
</CheckBox> |
|
|
|
</Button> |
|
|
|
</MenuItem.Icon> |
|
|
|
<Button Grid.Column="1" Classes="accent" |
|
|
|
</MenuItem> |
|
|
|
VerticalAlignment="Bottom" |
|
|
|
<MenuItem Header="None" |
|
|
|
HorizontalAlignment="Stretch" |
|
|
|
Command="{Binding ToggleSharedModelNone}"> |
|
|
|
IsVisible="{Binding ShowWebUiButton}" |
|
|
|
<MenuItem.Icon> |
|
|
|
Command="{Binding LaunchWebUi}"> |
|
|
|
<CheckBox IsChecked="{Binding IsSharedModelDisabled}" |
|
|
|
<StackPanel Orientation="Horizontal" Margin="8,2,8,2"> |
|
|
|
Margin="8,0,0,0" |
|
|
|
<icons:Icon Value="fa-solid fa-up-right-from-square" |
|
|
|
Padding="0" |
|
|
|
Margin="0,0,8,0" |
|
|
|
Width="28" Height="28"> |
|
|
|
FontSize="14" /> |
|
|
|
<CheckBox.RenderTransform> |
|
|
|
<TextBlock Text="Web UI" /> |
|
|
|
<ScaleTransform ScaleX="1.5" ScaleY="1.5" /> |
|
|
|
</StackPanel> |
|
|
|
</CheckBox.RenderTransform> |
|
|
|
|
|
|
|
</CheckBox> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
<!-- ReSharper enable Xaml.RedundantResource --> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
<MenuItem |
|
|
|
|
|
|
|
Header="{x:Static lang:Resources.Label_UseSharedOutputFolder}" |
|
|
|
|
|
|
|
Command="{Binding ToggleSharedOutput}" |
|
|
|
|
|
|
|
IsVisible="{Binding CanUseSharedOutput}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<CheckBox Margin="8,0,0,0" |
|
|
|
|
|
|
|
Padding="0" |
|
|
|
|
|
|
|
Width="28" Height="28" |
|
|
|
|
|
|
|
IsChecked="{Binding UseSharedOutput}"> |
|
|
|
|
|
|
|
<CheckBox.RenderTransform> |
|
|
|
|
|
|
|
<ScaleTransform ScaleX="1.5" ScaleY="1.5" /> |
|
|
|
|
|
|
|
</CheckBox.RenderTransform> |
|
|
|
|
|
|
|
</CheckBox> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
<Separator /> |
|
|
|
|
|
|
|
<MenuItem Header="{x:Static lang:Resources.Action_Uninstall}" |
|
|
|
|
|
|
|
Command="{Binding Uninstall}"> |
|
|
|
|
|
|
|
<MenuItem.Icon> |
|
|
|
|
|
|
|
<ui:SymbolIcon Symbol="Delete" /> |
|
|
|
|
|
|
|
</MenuItem.Icon> |
|
|
|
|
|
|
|
</MenuItem> |
|
|
|
|
|
|
|
</MenuFlyout> |
|
|
|
|
|
|
|
</Button.Flyout> |
|
|
|
</Button> |
|
|
|
</Button> |
|
|
|
</Grid> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!-- Import button (for unknown) --> |
|
|
|
<StackPanel Grid.Row="2" |
|
|
|
<Button Grid.Row="3" Grid.Column="0" Classes="transparent-info" |
|
|
|
Grid.Column="0" |
|
|
|
Grid.ColumnSpan="2" |
|
|
|
Margin="0,4,0,0" |
|
|
|
VerticalAlignment="Bottom" |
|
|
|
Orientation="Horizontal"> |
|
|
|
HorizontalAlignment="Stretch" |
|
|
|
<Button Classes="transparent-full" |
|
|
|
Command="{Binding Import}" |
|
|
|
Margin="4,4,0,0" |
|
|
|
IsVisible="{Binding IsUnknownPackage}"> |
|
|
|
Padding="4" |
|
|
|
<StackPanel Orientation="Horizontal" Margin="0,2,0,2"> |
|
|
|
ToolTip.Tip="{x:Static lang:Resources.Action_CheckForUpdates}" |
|
|
|
<icons:Icon Value="fa-solid fa-circle-question" |
|
|
|
Command="{Binding OnLoadedAsync}" |
|
|
|
Margin="0,0,8,0" |
|
|
|
> |
|
|
|
FontSize="14" /> |
|
|
|
<Button.IsVisible> |
|
|
|
<TextBlock Text="{x:Static lang:Resources.Action_Import}" /> |
|
|
|
<MultiBinding Converter="{x:Static BoolConverters.And}"> |
|
|
|
</StackPanel> |
|
|
|
<Binding Path="!IsUnknownPackage" /> |
|
|
|
</Button> |
|
|
|
<Binding Path="!IsUpdateAvailable" /> |
|
|
|
|
|
|
|
</MultiBinding> |
|
|
|
|
|
|
|
</Button.IsVisible> |
|
|
|
|
|
|
|
<ui:SymbolIcon Symbol="Refresh" |
|
|
|
|
|
|
|
FontSize="20"/> |
|
|
|
|
|
|
|
</Button> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<Button Classes="transparent-full" |
|
|
|
|
|
|
|
Margin="4,4,0,0" |
|
|
|
|
|
|
|
Padding="4" |
|
|
|
|
|
|
|
IsEnabled="{Binding !IsRunning}" |
|
|
|
|
|
|
|
ToolTip.Tip="{x:Static lang:Resources.Label_UpdateAvailable}" |
|
|
|
|
|
|
|
markupExtensions:ShowDisabledTooltipExtension.ShowOnDisabled="True" |
|
|
|
|
|
|
|
Command="{Binding Update}"> |
|
|
|
|
|
|
|
<Button.IsVisible> |
|
|
|
|
|
|
|
<MultiBinding Converter="{x:Static BoolConverters.And}"> |
|
|
|
|
|
|
|
<Binding Path="!IsUnknownPackage" /> |
|
|
|
|
|
|
|
<Binding Path="IsUpdateAvailable" /> |
|
|
|
|
|
|
|
</MultiBinding> |
|
|
|
|
|
|
|
</Button.IsVisible> |
|
|
|
|
|
|
|
<ui:SymbolIcon Symbol="CloudDownload" |
|
|
|
|
|
|
|
IsEnabled="{Binding !IsRunning}" |
|
|
|
|
|
|
|
FontSize="24"> |
|
|
|
|
|
|
|
<ui:SymbolIcon.Styles> |
|
|
|
|
|
|
|
<Style Selector="ui|SymbolIcon"> |
|
|
|
|
|
|
|
<Setter Property="Foreground" Value="Lime" /> |
|
|
|
|
|
|
|
</Style> |
|
|
|
|
|
|
|
<Style Selector="ui|SymbolIcon:disabled"> |
|
|
|
|
|
|
|
<Setter Property="Foreground" Value="Gray" /> |
|
|
|
|
|
|
|
</Style> |
|
|
|
|
|
|
|
</ui:SymbolIcon.Styles> |
|
|
|
|
|
|
|
</ui:SymbolIcon> |
|
|
|
|
|
|
|
</Button> |
|
|
|
|
|
|
|
<Button Classes="transparent-full" |
|
|
|
|
|
|
|
Margin="4,4,0,0" |
|
|
|
|
|
|
|
Padding="4" |
|
|
|
|
|
|
|
ToolTip.Tip="Launch Options" |
|
|
|
|
|
|
|
IsVisible="{Binding !IsUnknownPackage}" |
|
|
|
|
|
|
|
Command="{Binding ShowLaunchOptionsCommand}"> |
|
|
|
|
|
|
|
<ui:SymbolIcon Symbol="SettingsFilled" |
|
|
|
|
|
|
|
FontSize="20"/> |
|
|
|
|
|
|
|
</Button> |
|
|
|
|
|
|
|
</StackPanel> |
|
|
|
|
|
|
|
<UniformGrid Grid.Column="0" |
|
|
|
|
|
|
|
Grid.ColumnSpan="2" |
|
|
|
|
|
|
|
Grid.Row="3" |
|
|
|
|
|
|
|
VerticalAlignment="Bottom" |
|
|
|
|
|
|
|
Margin="8,8,8,0"> |
|
|
|
|
|
|
|
<Button Classes="accent" |
|
|
|
|
|
|
|
VerticalAlignment="Bottom" |
|
|
|
|
|
|
|
HorizontalAlignment="Stretch" |
|
|
|
|
|
|
|
Command="{Binding Launch}"> |
|
|
|
|
|
|
|
<Button.IsVisible> |
|
|
|
|
|
|
|
<MultiBinding Converter="{x:Static BoolConverters.And}"> |
|
|
|
|
|
|
|
<Binding Path="!IsRunning" /> |
|
|
|
|
|
|
|
<Binding Path="!IsUnknownPackage" /> |
|
|
|
|
|
|
|
</MultiBinding> |
|
|
|
|
|
|
|
</Button.IsVisible> |
|
|
|
|
|
|
|
<StackPanel Orientation="Horizontal" Margin="0,2,0,2"> |
|
|
|
|
|
|
|
<icons:Icon Value="fa-solid fa-rocket" |
|
|
|
|
|
|
|
Margin="0,0,8,0" |
|
|
|
|
|
|
|
FontSize="14" /> |
|
|
|
|
|
|
|
<TextBlock Text="{x:Static lang:Resources.Action_Launch}" /> |
|
|
|
|
|
|
|
</StackPanel> |
|
|
|
|
|
|
|
</Button> |
|
|
|
|
|
|
|
<Button Classes="borderless-danger" |
|
|
|
|
|
|
|
VerticalAlignment="Bottom" |
|
|
|
|
|
|
|
HorizontalAlignment="Stretch" |
|
|
|
|
|
|
|
IsVisible="{Binding IsRunning}" |
|
|
|
|
|
|
|
Command="{Binding StopCommand}"> |
|
|
|
|
|
|
|
<StackPanel Orientation="Horizontal" |
|
|
|
|
|
|
|
Margin="0,2"> |
|
|
|
|
|
|
|
<icons:Icon Value="fa-solid fa-stop" |
|
|
|
|
|
|
|
Margin="0,0,8,0" |
|
|
|
|
|
|
|
FontSize="14" /> |
|
|
|
|
|
|
|
<TextBlock Text="{x:Static lang:Resources.Action_Stop}" /> |
|
|
|
|
|
|
|
</StackPanel> |
|
|
|
|
|
|
|
</Button> |
|
|
|
|
|
|
|
<Button Classes="borderless-info" |
|
|
|
|
|
|
|
BorderBrush="Transparent" |
|
|
|
|
|
|
|
VerticalAlignment="Bottom" |
|
|
|
|
|
|
|
HorizontalAlignment="Stretch" |
|
|
|
|
|
|
|
IsVisible="{Binding IsRunning}" |
|
|
|
|
|
|
|
Command="{Binding RestartCommand}"> |
|
|
|
|
|
|
|
<StackPanel Orientation="Horizontal" |
|
|
|
|
|
|
|
Margin="0,2"> |
|
|
|
|
|
|
|
<icons:Icon Value="fa-solid fa-arrow-rotate-left" |
|
|
|
|
|
|
|
Margin="0,0,8,0" |
|
|
|
|
|
|
|
FontSize="14" /> |
|
|
|
|
|
|
|
<TextBlock Text="{x:Static lang:Resources.Action_Restart}" /> |
|
|
|
|
|
|
|
</StackPanel> |
|
|
|
|
|
|
|
</Button> |
|
|
|
|
|
|
|
<Button Classes="accent" |
|
|
|
|
|
|
|
VerticalAlignment="Bottom" |
|
|
|
|
|
|
|
HorizontalAlignment="Stretch" |
|
|
|
|
|
|
|
IsVisible="{Binding IsRunning}" |
|
|
|
|
|
|
|
Command="{Binding NavToConsole}"> |
|
|
|
|
|
|
|
<StackPanel Orientation="Horizontal" |
|
|
|
|
|
|
|
Margin="0,2,0,2"> |
|
|
|
|
|
|
|
<icons:Icon Value="fa-solid fa-terminal" |
|
|
|
|
|
|
|
Margin="0,0,8,0" |
|
|
|
|
|
|
|
FontSize="14" /> |
|
|
|
|
|
|
|
<TextBlock Text="Console" /> |
|
|
|
|
|
|
|
</StackPanel> |
|
|
|
|
|
|
|
</Button> |
|
|
|
|
|
|
|
<Button Classes="accent" |
|
|
|
|
|
|
|
VerticalAlignment="Bottom" |
|
|
|
|
|
|
|
HorizontalAlignment="Stretch" |
|
|
|
|
|
|
|
IsVisible="{Binding ShowWebUiButton}" |
|
|
|
|
|
|
|
Command="{Binding LaunchWebUi}"> |
|
|
|
|
|
|
|
<StackPanel Orientation="Horizontal" Margin="8,2,8,2"> |
|
|
|
|
|
|
|
<icons:Icon Value="fa-solid fa-up-right-from-square" |
|
|
|
|
|
|
|
Margin="0,0,8,0" |
|
|
|
|
|
|
|
FontSize="14" /> |
|
|
|
|
|
|
|
<TextBlock Text="Web UI" /> |
|
|
|
|
|
|
|
</StackPanel> |
|
|
|
|
|
|
|
</Button> |
|
|
|
|
|
|
|
<Button Classes="transparent-info" |
|
|
|
|
|
|
|
VerticalAlignment="Bottom" |
|
|
|
|
|
|
|
HorizontalAlignment="Stretch" |
|
|
|
|
|
|
|
Command="{Binding Import}" |
|
|
|
|
|
|
|
IsVisible="{Binding IsUnknownPackage}"> |
|
|
|
|
|
|
|
<StackPanel Orientation="Horizontal" Margin="0,2,0,2"> |
|
|
|
|
|
|
|
<icons:Icon Value="fa-solid fa-circle-question" |
|
|
|
|
|
|
|
Margin="0,0,8,0" |
|
|
|
|
|
|
|
FontSize="14" /> |
|
|
|
|
|
|
|
<TextBlock Text="{x:Static lang:Resources.Action_Import}" /> |
|
|
|
|
|
|
|
</StackPanel> |
|
|
|
|
|
|
|
</Button> |
|
|
|
|
|
|
|
</UniformGrid> |
|
|
|
|
|
|
|
</Grid> |
|
|
|
<!-- Update overlay --> |
|
|
|
<!-- Update overlay --> |
|
|
|
<Border |
|
|
|
<Border |
|
|
|
Grid.Row="0" Grid.RowSpan="4" |
|
|
|
|
|
|
|
Grid.Column="0" |
|
|
|
Grid.Column="0" |
|
|
|
Grid.ColumnSpan="2" |
|
|
|
Grid.ColumnSpan="2" |
|
|
|
Background="#DD000000" |
|
|
|
Background="#DD000000" |
|
|
|
CornerRadius="4" |
|
|
|
CornerRadius="8" |
|
|
|
HorizontalAlignment="Stretch" |
|
|
|
HorizontalAlignment="Stretch" |
|
|
|
VerticalAlignment="Stretch" |
|
|
|
VerticalAlignment="Stretch" |
|
|
|
IsVisible="{Binding IsProgressVisible}" /> |
|
|
|
IsVisible="{Binding IsProgressVisible}"/> |
|
|
|
<Grid Grid.Row="0" Grid.RowSpan="4" |
|
|
|
<Grid Grid.Column="0" |
|
|
|
Grid.Column="0" |
|
|
|
|
|
|
|
Grid.ColumnSpan="2" |
|
|
|
Grid.ColumnSpan="2" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
VerticalAlignment="Center" |
|
|
|
VerticalAlignment="Center" |
|
|
|
RowDefinitions="Auto, *" |
|
|
|
IsVisible="{Binding IsProgressVisible}" |
|
|
|
IsVisible="{Binding IsProgressVisible}"> |
|
|
|
RowDefinitions="Auto, *"> |
|
|
|
<controls:ProgressRing |
|
|
|
<controls:ProgressRing |
|
|
|
HorizontalAlignment="Center" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
IsIndeterminate="{Binding IsIndeterminate}" |
|
|
|
IsIndeterminate="{Binding IsIndeterminate}" |
|
|
|
Width="150" |
|
|
|
Width="120" |
|
|
|
Height="150" |
|
|
|
Height="120" |
|
|
|
StartAngle="90" |
|
|
|
StartAngle="90" |
|
|
|
EndAngle="450" |
|
|
|
EndAngle="450" |
|
|
|
Value="{Binding Value}" |
|
|
|
Value="{Binding Value}" |
|
|
|