Skip to content

Commit

Permalink
Fixed wallpaper import progress infobar transparency
Browse files Browse the repository at this point in the history
  • Loading branch information
rocksdanister committed Apr 30, 2024
1 parent 3354edd commit 3aac3f3
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
4 changes: 3 additions & 1 deletion src/Lively/Lively.UI.WinUI/Views/MainWindow.xaml
Expand Up @@ -320,10 +320,12 @@
<Frame x:Name="contentFrame" />
</NavigationView>

<InfoBar Name="infoBar" Grid.Row="1" />
<InfoBar Name="errorBar" Grid.Row="1" />
<!-- Setting background because default Information infobar style color is transparent now. -->
<InfoBar
Name="importBar"
Grid.Row="1"
Background="{ThemeResource SystemAccentColorDark1}"
IsClosable="False">
<ProgressBar Name="importBarProgress" Margin="-50,0,0,0" />
</InfoBar>
Expand Down
10 changes: 5 additions & 5 deletions src/Lively/Lively.UI.WinUI/Views/MainWindow.xaml.cs
Expand Up @@ -180,15 +180,15 @@ private void DesktopCore_WallpaperError(object sender, Exception e)

private void ShowError(Exception e)
{
infoBar.IsOpen = true;
infoBar.ActionButton = new HyperlinkButton
errorBar.IsOpen = true;
errorBar.ActionButton = new HyperlinkButton
{
Content = i18n.GetString("Help/Label"),
NavigateUri = new Uri("https://github.com/rocksdanister/lively/wiki/Common-Problems"),
};
infoBar.Title = i18n.GetString("TextError");
infoBar.Message = $"{e.Message}\n\nException:\n{e.GetType().Name}";
infoBar.Severity = InfoBarSeverity.Error;
errorBar.Title = i18n.GetString("TextError");
errorBar.Message = $"{e.Message}\n\nException:\n{e.GetType().Name}";
errorBar.Severity = InfoBarSeverity.Error;
}

private void AppUpdater_UpdateChecked(object sender, AppUpdaterEventArgs e)
Expand Down

0 comments on commit 3aac3f3

Please sign in to comment.