More fixes, color scheme changes

This commit is contained in:
Royce551 2021-11-23 14:35:58 -06:00
parent 76575664c8
commit ea623539d8
11 changed files with 29 additions and 37 deletions

View file

@ -3,6 +3,7 @@ using FRESHMusicPlayer.Handlers;
using FRESHMusicPlayer.Utilities;
using Microsoft.Win32;
using System.Collections.Generic;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Input;
@ -37,9 +38,9 @@ namespace FRESHMusicPlayer.Forms.Playlists
this.path = path;
CheckIfPlaylistExists();
}
private void CheckIfPlaylistExists()
private async void CheckIfPlaylistExists()
{
foreach (var thing in library.ReadTracksForPlaylist(playlist))
foreach (var thing in await Task.Run(() => library.ReadTracksForPlaylist(playlist)))
{
if (thing.Path == path)
{

View file

@ -29,7 +29,7 @@
</Grid>
</StackPanel>
</ScrollViewer>
<Grid Grid.Row="2" Background="{StaticResource SecondaryColor}">
<Grid Grid.Row="2" Background="{StaticResource ForegroundColor}">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>

View file

@ -16,7 +16,7 @@
<TextBlock Margin="10,10,0,0" Grid.Row="1" TextTrimming="WordEllipsis" Text="{x:Static resx:Resources.TAGEDITOR_INTEGRATIONDISAMBIGUATION}" TextWrapping="Wrap" Foreground="{StaticResource PrimaryTextColor}" FontSize="16"/>
<ListBox x:Name="ReleaseBox" Background="{StaticResource ForegroundColor}" Margin="15,10" HorizontalContentAlignment="Stretch" BorderBrush="{x:Null}" FontSize="14" Foreground="{StaticResource PrimaryTextColor}" ScrollViewer.VerticalScrollBarVisibility="Auto" Height="265"/>
</StackPanel>
<Grid Grid.Row="2" Background="{StaticResource SecondaryColor}">
<Grid Grid.Row="2" Background="{StaticResource ForegroundColor}">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>

View file

@ -56,7 +56,7 @@
<TextBlock x:Name="Link" Grid.Column="0" Text="Test" Foreground="#3399FF" FontSize="14" VerticalAlignment="Center" Margin="10,0" MouseLeftButtonDown="Link_MouseLeftButtonDown" Cursor="Hand" TextTrimming="CharacterEllipsis"/>
</Grid>
</Grid>
<Grid Grid.Row="2" Background="{StaticResource SecondaryColor}">
<Grid Grid.Row="2" Background="{StaticResource ForegroundColor}">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>

View file

@ -145,7 +145,7 @@
</Grid>
</StackPanel>
</ScrollViewer>
<Grid Grid.Row="2" Background="{StaticResource SecondaryColor}">
<Grid Grid.Row="2" Background="{StaticResource ForegroundColor}">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="250" MaxWidth="250px"/>

View file

@ -8,12 +8,6 @@
mc:Ignorable="d"
d:DesignHeight="372" d:DesignWidth="235"
Unloaded="Page_Unloaded" AllowDrop="True" Drop="Page_Drop">
<UserControl.Resources>
<Style BasedOn="{StaticResource {x:Type Button}}" TargetType="{x:Type Button}" x:Key="{x:Type Button}">
<Setter Property="BorderBrush" Value="{StaticResource ForegroundColor}"/>
<Setter Property="Background" Value="{StaticResource ForegroundColor}"/>
</Style>
</UserControl.Resources>
<Grid Background="{StaticResource SecondaryColor}">
<Grid.ColumnDefinitions>
<ColumnDefinition/>

View file

@ -9,10 +9,6 @@
d:DesignHeight="1072" d:DesignWidth="335"
Unloaded="Page_Unloaded">
<UserControl.Resources>
<Style BasedOn="{StaticResource {x:Type Button}}" TargetType="{x:Type Button}" x:Key="{x:Type Button}">
<Setter Property="BorderBrush" Value="{StaticResource ForegroundColor}"/>
<Setter Property="Background" Value="{StaticResource ForegroundColor}"/>
</Style>
<Style TargetType="{x:Type TextBlock}" x:Key="Subheader">
<Setter Property="Foreground" Value="{StaticResource PrimaryTextColor}"/>
<Setter Property="FontWeight" Value="Bold"/>
@ -36,7 +32,7 @@
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<TextBlock x:Name="RestartNeededHeader" Grid.Row="0" Foreground="{StaticResource PrimaryTextColor}" Text="{x:Static resx:Resources.SETTINGS_RESTART_NEEDED_PROMPT}" TextWrapping="Wrap" Margin="5" FontSize="14" TextAlignment="Center" Visibility="Collapsed"/>
<Button x:Name="RestartNowButton" Grid.Row="1" Margin="0,0,0,5" HorizontalAlignment="Center" Padding="10,5,10,5" Visibility="Collapsed" Click="RestartNowButton_Click" Content="{x:Static resx:Resources.SETTINGS_RESTART_NOW}" Background="{StaticResource SecondaryColor}"/>
<Button x:Name="RestartNowButton" Grid.Row="1" Margin="0,0,0,5" HorizontalAlignment="Center" Padding="10,5,10,5" Visibility="Collapsed" Click="RestartNowButton_Click" Content="{x:Static resx:Resources.SETTINGS_RESTART_NOW}"/>
</Grid>
<ScrollViewer Grid.Row="0" PanningMode="Both">
<StackPanel Background="{StaticResource SecondaryColor}" Grid.Row="0" Margin="20,0,0,0">

View file

@ -2,10 +2,11 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:FRESHMusicPlayer">
<SolidColorBrush x:Key="PrimaryTextColor" Color="White"/>
<SolidColorBrush x:Key="SecondaryTextColor" Color="#FFDADADA"/>
<SolidColorBrush x:Key="ControlBoxColor" Color="#FF2C2F33"/>
<SolidColorBrush x:Key="SecondaryTextColor" Color="#DADADA"/>
<SolidColorBrush x:Key="ControlBoxColor" Color="#2C2F33"/>
<SolidColorBrush x:Key="NavBarColor" Color="Black"/>
<SolidColorBrush x:Key="ForegroundColor" Color="#FF2C2F33"/>
<SolidColorBrush x:Key="SecondaryColor" Color="#FF3A3C40"/>
<SolidColorBrush x:Key="ForegroundColor" Color="#2C2F33"/>
<SolidColorBrush x:Key="SecondaryColor" Color="#323539"/>
<SolidColorBrush x:Key="BackgroundColor" Color="Black"/>
<SolidColorBrush x:Key="ControlColor" Color="#40444A"/>
</ResourceDictionary>

View file

@ -2,10 +2,11 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:FRESHMusicPlayer">
<SolidColorBrush x:Key="PrimaryTextColor" Color="Black"/>
<SolidColorBrush x:Key="SecondaryTextColor" Color="#FF525252"/>
<SolidColorBrush x:Key="ControlBoxColor" Color="#FFDEE0E3"/>
<SolidColorBrush x:Key="NavBarColor" Color="#FFBDC0C7"/>
<SolidColorBrush x:Key="ForegroundColor" Color="#FFDEE0E3"/>
<SolidColorBrush x:Key="SecondaryColor" Color="#FFCBCED2"/>
<SolidColorBrush x:Key="BackgroundColor" Color="#FFBDC0C7"/>
<SolidColorBrush x:Key="SecondaryTextColor" Color="#525252"/>
<SolidColorBrush x:Key="NavBarColor" Color="#DEE0E3"/>
<SolidColorBrush x:Key="ControlBoxColor" Color="#BDC0C7"/>
<SolidColorBrush x:Key="BackgroundColor" Color="#DEE0E3"/>
<SolidColorBrush x:Key="SecondaryColor" Color="#D3D6D9"/>
<SolidColorBrush x:Key="ForegroundColor" Color="#BDC0C7"/>
<SolidColorBrush x:Key="ControlColor" Color="#B5B9C0"/>
</ResourceDictionary>

View file

@ -5,7 +5,7 @@
<Style x:Key="{x:Type Button}" TargetType="{x:Type Button}">
<Setter Property="HorizontalContentAlignment" Value="Center"/>
<Setter Property="VerticalContentAlignment" Value="Center"/>
<Setter Property="Background" Value="{StaticResource ForegroundColor}"/>
<Setter Property="Background" Value="{StaticResource ControlColor}"/>
<Setter Property="Foreground" Value="{StaticResource PrimaryTextColor}"/>
<Setter Property="Padding" Value="20,1"/>
<Setter Property="Template">
@ -315,13 +315,13 @@
x:Name="Border"
Grid.ColumnSpan="2"
CornerRadius="2" Padding="5"
Background="{StaticResource ForegroundColor}"/>
Background="{StaticResource ControlColor}"/>
<Border
x:Name="Border2"
Grid.Column="0"
CornerRadius="2"
Margin="1"
Background="{StaticResource ForegroundColor}" />
Background="{StaticResource ControlColor}" />
<Path
x:Name="Arrow"
Grid.Column="1"
@ -349,7 +349,7 @@
<Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Auto"/>
<Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto"/>
<Setter Property="ScrollViewer.CanContentScroll" Value="true"/>
<Setter Property="BorderBrush" Value="{StaticResource ForegroundColor}"/>
<Setter Property="BorderBrush" Value="{StaticResource ControlColor}"/>
<Setter Property="Foreground" Value="{StaticResource PrimaryTextColor}"/>
<Setter Property="Template">
<Setter.Value>
@ -377,7 +377,7 @@
VerticalAlignment="Center"
Margin="3,3,23,3"
Focusable="True"
Background="{StaticResource ForegroundColor}"
Background="{StaticResource ControlColor}"
Foreground="Green"
Visibility="Hidden"
IsReadOnly="{TemplateBinding IsReadOnly}"/>
@ -395,7 +395,7 @@
MaxHeight="{TemplateBinding MaxDropDownHeight}">
<Border
x:Name="DropDownBorder"
Background="{StaticResource ForegroundColor}"/>
Background="{StaticResource ControlColor}"/>
<ScrollViewer Margin="4,6,4,6" SnapsToDevicePixels="True">
<StackPanel IsItemsHost="True" KeyboardNavigation.DirectionalNavigation="Contained" />
</ScrollViewer>
@ -457,11 +457,10 @@
<Style x:Key="{x:Type TextBox}" TargetType="{x:Type TextBox}">
<Setter Property="SnapsToDevicePixels" Value="True"/>
<Setter Property="CaretBrush" Value="#FF338BC1"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type TextBoxBase}">
<Border x:Name="TextBorder" CornerRadius="2" Background="{StaticResource ForegroundColor}" BorderBrush="{StaticResource ForegroundColor}" BorderThickness="2">
<Border x:Name="TextBorder" CornerRadius="2" Background="{StaticResource ControlColor}" BorderBrush="{StaticResource ControlColor}" BorderThickness="2">
<ScrollViewer Margin="0" x:Name="PART_ContentHost" />
</Border>
<ControlTemplate.Triggers>
@ -480,8 +479,8 @@
<!--CheckBox-->
<Style x:Key="{x:Type CheckBox}" TargetType="{x:Type CheckBox}">
<Setter Property="Background" Value="{StaticResource ForegroundColor}"/>
<Setter Property="BorderBrush" Value="{StaticResource ForegroundColor}"/>
<Setter Property="Background" Value="{StaticResource ControlColor}"/>
<Setter Property="BorderBrush" Value="{StaticResource ControlColor}"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="CheckBox">