diff --git a/.gitmodules b/.gitmodules deleted file mode 100644 index eb19e66..0000000 --- a/.gitmodules +++ /dev/null @@ -1,3 +0,0 @@ -[submodule "MahApps.Metro"] - path = MahApps.Metro - url = https://github.com/Dreamcooled/MahApps.Metro.git diff --git a/MahApps.Metro b/MahApps.Metro deleted file mode 160000 index 0bf7384..0000000 --- a/MahApps.Metro +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 0bf73841643ca3e02c10c4862ed3155b7105c471 diff --git a/SjUpdater.sln b/SjUpdater.sln index 41e4bdf..bf352a9 100644 --- a/SjUpdater.sln +++ b/SjUpdater.sln @@ -5,12 +5,8 @@ VisualStudioVersion = 12.0.30723.0 MinimumVisualStudioVersion = 10.0.40219.1 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SjUpdater", "SjUpdater\SjUpdater.csproj", "{96123159-7974-4FEB-BD8C-7AB562DF3E01}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MahApps.Metro", "MahApps.Metro\MahApps.Metro\MahApps.Metro.csproj", "{5B1710D2-5DC8-4754-91B2-19165DE49B3D}" -EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "updaterhasher", "updaterhasher\updaterhasher.csproj", "{89B40DD8-7928-4B21-B792-89AF030F6B55}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MahApps.Metro.Resources", "MahApps.Metro\MahApps.Metro.Resources\MahApps.Metro.Resources.csproj", "{E708AC99-605B-42A0-8D20-ABCA8FE42DD2}" -EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -21,18 +17,10 @@ Global {96123159-7974-4FEB-BD8C-7AB562DF3E01}.Debug|Any CPU.Build.0 = Debug|Any CPU {96123159-7974-4FEB-BD8C-7AB562DF3E01}.Release|Any CPU.ActiveCfg = Release|Any CPU {96123159-7974-4FEB-BD8C-7AB562DF3E01}.Release|Any CPU.Build.0 = Release|Any CPU - {5B1710D2-5DC8-4754-91B2-19165DE49B3D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {5B1710D2-5DC8-4754-91B2-19165DE49B3D}.Debug|Any CPU.Build.0 = Debug|Any CPU - {5B1710D2-5DC8-4754-91B2-19165DE49B3D}.Release|Any CPU.ActiveCfg = Release|Any CPU - {5B1710D2-5DC8-4754-91B2-19165DE49B3D}.Release|Any CPU.Build.0 = Release|Any CPU {89B40DD8-7928-4B21-B792-89AF030F6B55}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {89B40DD8-7928-4B21-B792-89AF030F6B55}.Debug|Any CPU.Build.0 = Debug|Any CPU {89B40DD8-7928-4B21-B792-89AF030F6B55}.Release|Any CPU.ActiveCfg = Release|Any CPU {89B40DD8-7928-4B21-B792-89AF030F6B55}.Release|Any CPU.Build.0 = Release|Any CPU - {E708AC99-605B-42A0-8D20-ABCA8FE42DD2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {E708AC99-605B-42A0-8D20-ABCA8FE42DD2}.Debug|Any CPU.Build.0 = Debug|Any CPU - {E708AC99-605B-42A0-8D20-ABCA8FE42DD2}.Release|Any CPU.ActiveCfg = Release|Any CPU - {E708AC99-605B-42A0-8D20-ABCA8FE42DD2}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/SjUpdater/App.xaml b/SjUpdater/App.xaml index 684aad6..c3c0d38 100644 --- a/SjUpdater/App.xaml +++ b/SjUpdater/App.xaml @@ -10,7 +10,7 @@ - + diff --git a/SjUpdater/EpisodeView.cs b/SjUpdater/EpisodeView.cs deleted file mode 100644 index 93aebb6..0000000 --- a/SjUpdater/EpisodeView.cs +++ /dev/null @@ -1,192 +0,0 @@ -using System.ComponentModel; -using System.Runtime.CompilerServices; -using System.Runtime.Serialization; -using System.Windows.Input; -using System.Windows.Markup; -using System.Windows.Media; -using System; -using System.CodeDom; -using System.Collections.Generic; -using System.Configuration; -using System.Linq; -using System.Security.RightsManagement; -using System.Text; -using System.Threading.Tasks; -using SjUpdater.Annotations; - -namespace SjUpdater -{ - public class EpisodeView : INotifyPropertyChanged - { - - public EpisodeView() - { - - EpisodeDescriptors = new List(); - - - } - - public int Episode - { - get - { - if (EpisodeDescriptors.Any()) - { - return EpisodeDescriptors.First().Episode; - } - return -1; - } - } - - public List EpisodeDescriptors - { - get; - private set; - } - - public string DetailTitle - { - get - { - String s = EpisodeDescriptors.First().SeasonShowName + " "; - if (EpisodeDescriptors.First().Season != -1) - { - s += "Season " + EpisodeDescriptors.First().Season +" "; - if (Episode != -1) - { - s += "Episode " + Episode; - } - } - return s; - } - } - public string Title - { - get - { - if (EpisodeDescriptors.First().Season == -1) - { - return EpisodeDescriptors.First().Title; - } - if (Episode == -1) - { - return EpisodeDescriptors.Count().ToString() + " Others"; - } - return "Episode" + Episode; - - } - } - - public string Languages - { - get - { - EpisodeDescriptor.Lang langs = EpisodeDescriptors.Aggregate(0, (current, episodeDescriptor) => current | episodeDescriptor.Language); - - switch (langs) - { - case EpisodeDescriptor.Lang.English: - return "English"; - case EpisodeDescriptor.Lang.German: - return "German"; - case EpisodeDescriptor.Lang.Both: - return "German,English"; - } - return ""; - - } - } - - public string Formats - { - - get - { - var lisFormats = new List(); - var lisFormatsComp = new List(); - foreach (var descriptor in EpisodeDescriptors) - { - string f = descriptor.Format; - if(String.IsNullOrWhiteSpace(f)) - continue; - if(!lisFormatsComp.Contains(f.ToLower())){ - lisFormats.Add(f); - lisFormatsComp.Add(f.ToLower()); - } - } - - return string.Join(",", lisFormats); - - } - } - - - public Brush Background - { - get - { - - var colors = new Color[] - { - Color.FromRgb(111, 189, 69), - Color.FromRgb(75, 179, 221), - Color.FromRgb(65, 100, 165), - Color.FromRgb(225, 32, 38), - Color.FromRgb(128, 0, 128), - Color.FromRgb(0, 128, 64), - Color.FromRgb(0, 148, 255), - Color.FromRgb(255, 0, 199), - Color.FromRgb(255, 135, 15), - Color.FromRgb(45, 255, 87), - Color.FromRgb(127, 0, 55) - }; - - int season = EpisodeDescriptors.First().Season; - if (season == -1) season = 0; - Color c = colors[season%colors.Length]; - Color cb = Colors.Black; - float a = (Episode == -1) ? 0.8f : 0.5f; - byte r = (byte) (a*cb.R + (1 - a)*c.R); - byte g = (byte)(a * cb.G + (1 - a) * c.G); - byte b = (byte)(a * cb.B + (1 - a) * c.B); - return new SolidColorBrush(Color.FromRgb(r,g,b)); - - - } - } - - #region tile stuff - - public bool IsDoubleWidth { - get - { - return Episode == -1; - } - } - - - public bool IsPressed - { - get { return _isPressed; } - set - { - if (_isPressed != value) - { - _isPressed = value; - OnPropertyChanged(); - } - } - } - private bool _isPressed; - public event PropertyChangedEventHandler PropertyChanged; - - [NotifyPropertyChangedInvocator] - protected virtual void OnPropertyChanged([CallerMemberName] string propertyName = null) - { - PropertyChangedEventHandler handler = PropertyChanged; - if (handler != null) handler(this, new PropertyChangedEventArgs(propertyName)); - } - #endregion - } -} diff --git a/SjUpdater/Hardcodet.Wpf.TaskbarNotification.dll b/SjUpdater/Hardcodet.Wpf.TaskbarNotification.dll deleted file mode 100644 index cf96345..0000000 Binary files a/SjUpdater/Hardcodet.Wpf.TaskbarNotification.dll and /dev/null differ diff --git a/SjUpdater/MainWindow.xaml b/SjUpdater/MainWindow.xaml index adb22d6..452d538 100644 --- a/SjUpdater/MainWindow.xaml +++ b/SjUpdater/MainWindow.xaml @@ -5,13 +5,13 @@ xmlns:controls="http://metro.mahapps.com/winfx/xaml/controls" xmlns:viewModel="clr-namespace:SjUpdater.ViewModel" xmlns:utils="clr-namespace:SjUpdater.Utils" - xmlns:tb="http://www.hardcodet.net/taskbar" xmlns:model="clr-namespace:SjUpdater.Model" xmlns:metro="clr-namespace:MahApps.Metro;assembly=MahApps.Metro" + xmlns:taskbarNotification="clr-namespace:Hardcodet.Wpf.TaskbarNotification;assembly=Hardcodet.Wpf.TaskbarNotification" x:Class="SjUpdater.MainWindow" Title="Serienjunkies Updater" Height="784.65" Width="1096" x:Name="Window" SaveWindowPosition="True" MinWidth="800" MinHeight="600" - Closing="MainWindow_OnClosing" AllowsTransparency="True" WindowStyle="None" Icon="icon3.ico" TextOptions.TextFormattingMode="Display" > - + Closing="MainWindow_OnClosing" AllowsTransparency="True" WindowStyle="None" Icon="Resources/icon3.ico" TextOptions.TextFormattingMode="Display" > + - + @@ -42,8 +42,8 @@ - + + + - + + + + + + + + + + + - + - - - - - - - - + + + @@ -289,7 +304,7 @@