diff --git a/Wino.Core.Domain/Interfaces/IThemeService.cs b/Wino.Core.Domain/Interfaces/IThemeService.cs index 86496fca..a452159d 100644 --- a/Wino.Core.Domain/Interfaces/IThemeService.cs +++ b/Wino.Core.Domain/Interfaces/IThemeService.cs @@ -22,5 +22,6 @@ namespace Wino.Core.Domain.Interfaces Guid CurrentApplicationThemeId { get; set; } string AccentColor { get; set; } string GetSystemAccentColorHex(); + bool IsCustomTheme { get; } } } diff --git a/Wino.Core.UWP/AppThemes/Clouds.xaml b/Wino.Core.UWP/AppThemes/Clouds.xaml index 6b443b7e..ae5554a7 100644 --- a/Wino.Core.UWP/AppThemes/Clouds.xaml +++ b/Wino.Core.UWP/AppThemes/Clouds.xaml @@ -4,7 +4,7 @@ xmlns:xaml="using:Windows.UI.Xaml"> Clouds - ms-appx:///BackgroundImages/Clouds.jpg + ms-appx:///Wino.Core.UWP/BackgroundImages/Clouds.jpg False diff --git a/Wino.Core.UWP/AppThemes/Forest.xaml b/Wino.Core.UWP/AppThemes/Forest.xaml index b2654834..63ab19a1 100644 --- a/Wino.Core.UWP/AppThemes/Forest.xaml +++ b/Wino.Core.UWP/AppThemes/Forest.xaml @@ -4,7 +4,7 @@ xmlns:xaml="using:Windows.UI.Xaml"> Forest - ms-appx:///BackgroundImages/Forest.jpg + ms-appx:///Wino.Core.UWP/BackgroundImages/Forest.jpg False diff --git a/Wino.Core.UWP/AppThemes/Garden.xaml b/Wino.Core.UWP/AppThemes/Garden.xaml index ad852e61..12227bfd 100644 --- a/Wino.Core.UWP/AppThemes/Garden.xaml +++ b/Wino.Core.UWP/AppThemes/Garden.xaml @@ -4,7 +4,7 @@ xmlns:xaml="using:Windows.UI.Xaml"> Garden - ms-appx:///BackgroundImages/Garden.jpg + ms-appx:///Wino.Core.UWP/BackgroundImages/Garden.jpg False diff --git a/Wino.Core.UWP/AppThemes/Nighty.xaml b/Wino.Core.UWP/AppThemes/Nighty.xaml index 721f7421..51de8e5f 100644 --- a/Wino.Core.UWP/AppThemes/Nighty.xaml +++ b/Wino.Core.UWP/AppThemes/Nighty.xaml @@ -4,7 +4,7 @@ xmlns:xaml="using:Windows.UI.Xaml"> Nighty - ms-appx:///BackgroundImages/Nighty.jpg + ms-appx:///Wino.Core.UWP/BackgroundImages/Nighty.jpg False diff --git a/Wino.Core.UWP/AppThemes/Snowflake.xaml b/Wino.Core.UWP/AppThemes/Snowflake.xaml index fd3ee92a..f2d8b893 100644 --- a/Wino.Core.UWP/AppThemes/Snowflake.xaml +++ b/Wino.Core.UWP/AppThemes/Snowflake.xaml @@ -4,7 +4,7 @@ xmlns:xaml="using:Windows.UI.Xaml"> Snowflake - ms-appx:///BackgroundImages/Snowflake.jpg + ms-appx:///Wino.Core.UWP/Snowflake.jpg False diff --git a/Wino.Core.UWP/CoreGeneric.xaml b/Wino.Core.UWP/CoreGeneric.xaml index 3387e142..30bb098e 100644 --- a/Wino.Core.UWP/CoreGeneric.xaml +++ b/Wino.Core.UWP/CoreGeneric.xaml @@ -94,9 +94,6 @@ - - - diff --git a/Wino.Core.UWP/Models/Personalization/CustomAppTheme.cs b/Wino.Core.UWP/Models/Personalization/CustomAppTheme.cs index 3f821e5a..0e02d319 100644 --- a/Wino.Core.UWP/Models/Personalization/CustomAppTheme.cs +++ b/Wino.Core.UWP/Models/Personalization/CustomAppTheme.cs @@ -24,7 +24,7 @@ namespace Wino.Core.UWP.Models.Personalization public override async Task GetThemeResourceDictionaryContentAsync() { - var customAppThemeFile = await StorageFile.GetFileFromApplicationUriAsync(new Uri("ms-appx:///AppThemes/Custom.xaml")); + var customAppThemeFile = await StorageFile.GetFileFromApplicationUriAsync(new Uri("ms-appx:///Wino.Core.UWP/AppThemes/Custom.xaml")); return await FileIO.ReadTextAsync(customAppThemeFile); } } diff --git a/Wino.Core.UWP/Models/Personalization/PreDefinedAppTheme.cs b/Wino.Core.UWP/Models/Personalization/PreDefinedAppTheme.cs index 107f4a1a..56a35975 100644 --- a/Wino.Core.UWP/Models/Personalization/PreDefinedAppTheme.cs +++ b/Wino.Core.UWP/Models/Personalization/PreDefinedAppTheme.cs @@ -23,11 +23,11 @@ namespace Wino.Core.UWP.Models.Personalization public override AppThemeType AppThemeType => AppThemeType.PreDefined; public override string GetBackgroundPreviewImagePath() - => $"ms-appx:///BackgroundImages/{ThemeName}.jpg"; + => $"ms-appx:///Wino.Core.UWP/BackgroundImages/{ThemeName}.jpg"; public override async Task GetThemeResourceDictionaryContentAsync() { - var xamlDictionaryFile = await StorageFile.GetFileFromApplicationUriAsync(new Uri($"ms-appx:///AppThemes/{ThemeName}.xaml")); + var xamlDictionaryFile = await StorageFile.GetFileFromApplicationUriAsync(new Uri($"ms-appx:///Wino.Core.UWP/AppThemes/{ThemeName}.xaml")); return await FileIO.ReadTextAsync(xamlDictionaryFile); } } diff --git a/Wino.Core.UWP/Services/ThemeService.cs b/Wino.Core.UWP/Services/ThemeService.cs index d32de95b..2fca1fe1 100644 --- a/Wino.Core.UWP/Services/ThemeService.cs +++ b/Wino.Core.UWP/Services/ThemeService.cs @@ -143,6 +143,15 @@ namespace Wino.Services } } + public bool IsCustomTheme + { + get + { + return currentApplicationThemeId != Guid.Parse(_micaThemeId) && + currentApplicationThemeId != Guid.Parse(_acrylicThemeId); + } + } + public async Task InitializeAsync() { // Already initialized. There is no need. diff --git a/Wino.Core.UWP/Styles/IconTemplates.xaml b/Wino.Core.UWP/Styles/IconTemplates.xaml index 1c885f55..28a2256e 100644 --- a/Wino.Core.UWP/Styles/IconTemplates.xaml +++ b/Wino.Core.UWP/Styles/IconTemplates.xaml @@ -6,43 +6,43 @@ - + - + - + - + - + - + - + - + - + - + - diff --git a/Wino.Core.UWP/Wino.Core.UWP.csproj b/Wino.Core.UWP/Wino.Core.UWP.csproj index c3d90e3b..131918e2 100644 --- a/Wino.Core.UWP/Wino.Core.UWP.csproj +++ b/Wino.Core.UWP/Wino.Core.UWP.csproj @@ -85,6 +85,7 @@ + WinoAppTitleBar.xaml diff --git a/Wino.Mail.ViewModels/MailListPageViewModel.cs b/Wino.Mail.ViewModels/MailListPageViewModel.cs index 3af61c37..a6de7bfe 100644 --- a/Wino.Mail.ViewModels/MailListPageViewModel.cs +++ b/Wino.Mail.ViewModels/MailListPageViewModel.cs @@ -70,6 +70,7 @@ namespace Wino.Mail.ViewModels public INavigationService NavigationService { get; } public IStatePersistanceService StatePersistenceService { get; } public IPreferencesService PreferencesService { get; } + public IThemeService ThemeService { get; } private readonly IMailService _mailService; private readonly IFolderService _folderService; @@ -154,9 +155,11 @@ namespace Wino.Mail.ViewModels IWinoRequestDelegator winoRequestDelegator, IKeyPressService keyPressService, IPreferencesService preferencesService, - IWinoServerConnectionManager winoServerConnectionManager) + IThemeService themeService, + IWinoServerConnectionManager winoServerConnectionManager) { PreferencesService = preferencesService; + ThemeService = themeService; _winoServerConnectionManager = winoServerConnectionManager; StatePersistenceService = statePersistenceService; NavigationService = navigationService; diff --git a/Wino.Mail/App.xaml b/Wino.Mail/App.xaml index 28d63619..965f4756 100644 --- a/Wino.Mail/App.xaml +++ b/Wino.Mail/App.xaml @@ -17,6 +17,9 @@ + + + diff --git a/Wino.Mail/AppShell.xaml b/Wino.Mail/AppShell.xaml index a0ec351e..15bc5094 100644 --- a/Wino.Mail/AppShell.xaml +++ b/Wino.Mail/AppShell.xaml @@ -381,6 +381,7 @@ x:Name="navigationView" Grid.Row="1" Grid.ColumnSpan="3" + Margin="-1,-1,0,0" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch" AlwaysShowHeader="True" diff --git a/Wino.Mail/Views/MailListPage.xaml b/Wino.Mail/Views/MailListPage.xaml index 40fdd0e5..ac72fa0f 100644 --- a/Wino.Mail/Views/MailListPage.xaml +++ b/Wino.Mail/Views/MailListPage.xaml @@ -228,7 +228,7 @@ - + @@ -506,6 +506,7 @@ + + Spacing="6" + Visibility="{x:Bind helpers:XamlHelpers.ReverseBoolToVisibilityConverter(ViewModel.ThemeService.IsCustomTheme)}">