Fix SplashScreen loading

This commit is contained in:
PAL\cbo
2023-02-07 15:06:43 +01:00
parent b2220452b2
commit 98c3aeb9ea
5 changed files with 38 additions and 17 deletions
+3
View File
@@ -6,6 +6,7 @@ using Serilog;
using Serilog.Sinks.Graylog;
using DevExpress.Mvvm;
using DevExpress.Xpf.Core;
using System.Threading;
namespace wpf_ax_utility
{
@@ -70,6 +71,8 @@ namespace wpf_ax_utility
uriString = "/wpf_ax_utility;component/AppMainWindow.xaml";
}
Thread.Sleep(2000);
this.StartupUri = new Uri(uriString, UriKind.Relative);
}
}
+20 -6
View File
@@ -6,21 +6,34 @@
xmlns:dx="http://schemas.devexpress.com/winfx/2008/xaml/core"
xmlns:dxt="http://schemas.devexpress.com/winfx/2008/xaml/core/themekeys"
xmlns:dxmvvm="http://schemas.devexpress.com/winfx/2008/xaml/mvvm"
MinWidth="600"
MinHeight="400"
AllowAcrylic="True"
dx:DXDesignTimeHelper.Background="#02188f"
MinWidth="550"
MinHeight="300"
ResizeMode="NoResize"
WindowStyle="None"
WindowStartupLocation="CenterScreen"
AllowsTransparency="True"
Background="Transparent"
Title="PAL Ax Utility"
mc:Ignorable="d"
d:DataContext="{x:Static dxmvvm:DXSplashScreenViewModel.DesignTimeData}">
<Grid>
<Border Background="#02188f" CornerRadius="15" Opacity="0.95"/>
<Grid>
<Grid.RowDefinitions>
<RowDefinition/>
<RowDefinition/>
<RowDefinition Height="2*"/>
<RowDefinition/>
</Grid.RowDefinitions>
<dx:DXImage x:Name="PART_Logo" Height="35" Width="82" Source="res/pallogo.png" Style="{DynamicResource ResourceKey={dxt:FluentSplashScreenThemeKey ResourceKey=LogoImageStyle}}" Stretch="Fill"/>
<dx:DXImage x:Name="PART_Logo" Height="45" Width="105" Source="res/pallogo.png" Style="{DynamicResource ResourceKey={dxt:FluentSplashScreenThemeKey ResourceKey=LogoImageStyle}}" Stretch="Fill"/>
<Border Grid.Row="1" Height="100" Width="100" CornerRadius="15">
<Border.Background>
<ImageBrush Stretch="Fill" ImageSource="res/axlogo.png"/>
</Border.Background>
</Border>
<TextBlock x:Name="PART_Title" Grid.Row="1" Text="PAL Ax Utility" Style="{DynamicResource ResourceKey={dxt:FluentSplashScreenThemeKey ResourceKey=TitleTextBoxStyle}}"/>
<StackPanel Orientation="Vertical" Grid.Row="2" VerticalAlignment="Top">
<!--<TextBlock x:Name="PART_SubTitle" Text="{Binding Subtitle}" Style="{DynamicResource ResourceKey={dxt:FluentSplashScreenThemeKey ResourceKey=SubTitleTextBoxStyle}}"/>-->
@@ -30,4 +43,5 @@
<TextBlock x:Name="PART_Copyright" Text='Copyright © 2023 PAL s.r.l. All rights reserved.' Grid.Row="2" Style="{DynamicResource ResourceKey={dxt:FluentSplashScreenThemeKey ResourceKey=CopyrightTextBoxStyle}}"/>
<TextBlock x:Name="PART_Status" Text="{Binding Status}" Grid.Row="2" Style="{DynamicResource ResourceKey={dxt:FluentSplashScreenThemeKey ResourceKey=StatusTextBoxStyle}}"/>
</Grid>
</Grid>
</dx:SplashScreenWindow>
Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 174 KiB

After

Width:  |  Height:  |  Size: 139 KiB

+4
View File
@@ -12,6 +12,7 @@
<None Remove="axlogo.ico" />
<None Remove="axlogo.png" />
<None Remove="rdrect1197.png" />
<None Remove="res\axlogo.png" />
<None Remove="res\pallogo.png" />
</ItemGroup>
@@ -19,6 +20,9 @@
<Content Include="res\axlogo.ico">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
<Content Include="res\axlogo.png">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
<Content Include="res\pallogo.png">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>