From 465830897b75b6699a39c37c3eca42659f2a410d Mon Sep 17 00:00:00 2001 From: Drommedhar Date: Sun, 6 Oct 2024 11:44:45 +0200 Subject: [PATCH] Version 2.0 --- DlssUpdater/App.xaml | 213 ++++++++++++++++- DlssUpdater/App.xaml.cs | 50 ++-- DlssUpdater/Controls/ChangelogPanel.xaml | 31 +++ DlssUpdater/Controls/ChangelogPanel.xaml.cs | 157 +++++++++++++ DlssUpdater/Controls/DownloadButton.xaml | 35 +-- DlssUpdater/Controls/DownloadButton.xaml.cs | 165 ++++++------- DlssUpdater/Controls/GameButton.xaml | 60 ----- DlssUpdater/Controls/GameButton.xaml.cs | 91 -------- DlssUpdater/Controls/GamePanel.xaml | 108 +++++++++ DlssUpdater/Controls/GamePanel.xaml.cs | 83 +++++++ DlssUpdater/Controls/LauncherPanel.xaml | 29 --- DlssUpdater/Controls/LauncherPanel.xaml.cs | 82 ------- DlssUpdater/Controls/NavButton.xaml | 37 +++ DlssUpdater/Controls/NavButton.xaml.cs | 87 +++++++ DlssUpdater/DLSSUpdater.csproj | 77 +++++- DlssUpdater/Defines/DlssTypes.cs | 13 ++ DlssUpdater/Defines/GameInfo.cs | 121 ++++++++-- DlssUpdater/Defines/UI/NavigationButton.cs | 45 ++++ DlssUpdater/Defines/UI/Pages/ChangelogPage.cs | 46 ++++ DlssUpdater/Defines/UI/Pages/DLSSPage.cs | 110 +++++++++ DlssUpdater/Defines/UI/Pages/IContentPage.cs | 12 + DlssUpdater/Defines/UI/Pages/LibraryPage.cs | 90 +++++++ DlssUpdater/Defines/UI/Pages/SettingsPage.cs | 46 ++++ .../GameLibrary/EpicGames/EpicGamesLibrary.cs | 1 - DlssUpdater/GameLibrary/GOGLibrary.cs | 1 - DlssUpdater/GameLibrary/Steam/SteamLibrary.cs | 1 - .../GameLibrary/UbisoftConnectLibrary.cs | 1 - DlssUpdater/GameLibrary/XboxLibrary.cs | 1 - .../Helpers/HttpClientDownloadWithProgress.cs | 15 +- DlssUpdater/Helpers/UIHelper.cs | 13 +- DlssUpdater/Icons/battleye.png | Bin 0 -> 9811 bytes DlssUpdater/Icons/config.png | Bin 0 -> 3946 bytes DlssUpdater/Icons/cross.png | Bin 0 -> 9970 bytes DlssUpdater/Icons/eac.png | Bin 0 -> 11871 bytes DlssUpdater/Icons/epic.png | Bin 0 -> 7734 bytes DlssUpdater/Icons/filter.png | Bin 0 -> 2427 bytes DlssUpdater/Icons/folder.png | Bin 0 -> 3095 bytes DlssUpdater/Icons/gog.png | Bin 0 -> 3177 bytes DlssUpdater/Icons/hide.png | Bin 0 -> 12612 bytes DlssUpdater/Icons/steam.png | Bin 0 -> 6244 bytes DlssUpdater/Icons/trashcan.png | Bin 0 -> 7263 bytes DlssUpdater/Icons/ubi.png | Bin 0 -> 5605 bytes DlssUpdater/Icons/unhide.png | Bin 0 -> 12607 bytes DlssUpdater/Icons/update.png | Bin 0 -> 24559 bytes DlssUpdater/Icons/xbox.png | Bin 0 -> 5411 bytes .../Services/ApplicationHostService.cs | 3 +- DlssUpdater/Services/PageService.cs | 41 ---- DlssUpdater/Settings.cs | 7 +- .../AntiCheatChecker/AntiCheatChecker.cs | 6 +- .../AntiCheatChecker/IAntiCheatProvider.cs | 2 + DlssUpdater/Singletons/DllUpdater.cs | 57 +++-- DlssUpdater/Singletons/GameContainer.cs | 11 +- .../Pages/ChangelogPageViewModel.cs | 73 ++++++ .../ViewModels/Pages/ChangelogViewModel.cs | 38 --- DlssUpdater/ViewModels/Pages/DLSSViewModel.cs | 58 ----- .../ViewModels/Pages/DlssPageViewModel.cs | 47 ++++ .../ViewModels/Pages/GamePageViewModel.cs | 70 ++++++ .../ViewModels/Pages/GamesViewModel.cs | 122 ---------- .../Pages/SettingsCommonPageViewModel.cs | 171 ++++++++++++++ .../ViewModels/Pages/SettingsViewModel.cs | 95 -------- .../Windows/GameConfigWindowViewModel.cs | 83 +++++++ .../ViewModels/Windows/MainWindowViewModel.cs | 220 ++++++++++-------- DlssUpdater/Views/Pages/ChangelogPage.xaml | 23 -- DlssUpdater/Views/Pages/ChangelogPage.xaml.cs | 19 -- .../Views/Pages/ChangelogPageControl.xaml | 33 +++ .../Views/Pages/ChangelogPageControl.xaml.cs | 42 ++++ DlssUpdater/Views/Pages/DLSSPage.xaml | 94 -------- DlssUpdater/Views/Pages/DLSSPage.xaml.cs | 17 -- DlssUpdater/Views/Pages/DlssPageControl.xaml | 36 +++ .../Views/Pages/DlssPageControl.xaml.cs | 34 +++ DlssUpdater/Views/Pages/GamePageControl.xaml | 108 +++++++++ .../Views/Pages/GamePageControl.xaml.cs | 145 ++++++++++++ DlssUpdater/Views/Pages/GamesPage.xaml | 129 ---------- DlssUpdater/Views/Pages/GamesPage.xaml.cs | 216 ----------------- .../Pages/SettingsCommonPageControl.xaml | 93 ++++++++ .../Pages/SettingsCommonPageControl.xaml.cs | 57 +++++ DlssUpdater/Views/Pages/SettingsPage.xaml | 80 ------- DlssUpdater/Views/Pages/SettingsPage.xaml.cs | 47 ---- .../Views/Windows/GameConfigWindow.xaml | 134 +++++++++++ .../Views/Windows/GameConfigWindow.xaml.cs | 167 +++++++++++++ DlssUpdater/Views/Windows/MainWindow.xaml | 110 +++++---- DlssUpdater/Views/Windows/MainWindow.xaml.cs | 107 +++++---- .../Windows/Splashscreen/Splashscreen.xaml | 54 ++--- .../Windows/Splashscreen/Splashscreen.xaml.cs | 20 +- DlssUpdater/changelog.md | 9 +- DlssUpdater/version.json | 2 +- README.md | 36 +-- docs/images/anticheat.png | Bin 42923 -> 0 bytes docs/images/anticheat_warning.png | Bin 521230 -> 0 bytes docs/images/config_panel.png | Bin 390202 -> 0 bytes docs/images/dlss_page.png | Bin 31221 -> 0 bytes docs/images/games_page.png | Bin 692537 -> 0 bytes docs/images/settings_page.png | Bin 23963 -> 0 bytes docs/images/splashcreen.png | Bin 348030 -> 0 bytes 94 files changed, 3006 insertions(+), 1731 deletions(-) create mode 100644 DlssUpdater/Controls/ChangelogPanel.xaml create mode 100644 DlssUpdater/Controls/ChangelogPanel.xaml.cs delete mode 100644 DlssUpdater/Controls/GameButton.xaml delete mode 100644 DlssUpdater/Controls/GameButton.xaml.cs create mode 100644 DlssUpdater/Controls/GamePanel.xaml create mode 100644 DlssUpdater/Controls/GamePanel.xaml.cs delete mode 100644 DlssUpdater/Controls/LauncherPanel.xaml delete mode 100644 DlssUpdater/Controls/LauncherPanel.xaml.cs create mode 100644 DlssUpdater/Controls/NavButton.xaml create mode 100644 DlssUpdater/Controls/NavButton.xaml.cs create mode 100644 DlssUpdater/Defines/UI/NavigationButton.cs create mode 100644 DlssUpdater/Defines/UI/Pages/ChangelogPage.cs create mode 100644 DlssUpdater/Defines/UI/Pages/DLSSPage.cs create mode 100644 DlssUpdater/Defines/UI/Pages/IContentPage.cs create mode 100644 DlssUpdater/Defines/UI/Pages/LibraryPage.cs create mode 100644 DlssUpdater/Defines/UI/Pages/SettingsPage.cs create mode 100644 DlssUpdater/Icons/battleye.png create mode 100644 DlssUpdater/Icons/config.png create mode 100644 DlssUpdater/Icons/cross.png create mode 100644 DlssUpdater/Icons/eac.png create mode 100644 DlssUpdater/Icons/epic.png create mode 100644 DlssUpdater/Icons/filter.png create mode 100644 DlssUpdater/Icons/folder.png create mode 100644 DlssUpdater/Icons/gog.png create mode 100644 DlssUpdater/Icons/hide.png create mode 100644 DlssUpdater/Icons/steam.png create mode 100644 DlssUpdater/Icons/trashcan.png create mode 100644 DlssUpdater/Icons/ubi.png create mode 100644 DlssUpdater/Icons/unhide.png create mode 100644 DlssUpdater/Icons/update.png create mode 100644 DlssUpdater/Icons/xbox.png delete mode 100644 DlssUpdater/Services/PageService.cs create mode 100644 DlssUpdater/ViewModels/Pages/ChangelogPageViewModel.cs delete mode 100644 DlssUpdater/ViewModels/Pages/ChangelogViewModel.cs delete mode 100644 DlssUpdater/ViewModels/Pages/DLSSViewModel.cs create mode 100644 DlssUpdater/ViewModels/Pages/DlssPageViewModel.cs create mode 100644 DlssUpdater/ViewModels/Pages/GamePageViewModel.cs delete mode 100644 DlssUpdater/ViewModels/Pages/GamesViewModel.cs create mode 100644 DlssUpdater/ViewModels/Pages/SettingsCommonPageViewModel.cs delete mode 100644 DlssUpdater/ViewModels/Pages/SettingsViewModel.cs create mode 100644 DlssUpdater/ViewModels/Windows/GameConfigWindowViewModel.cs delete mode 100644 DlssUpdater/Views/Pages/ChangelogPage.xaml delete mode 100644 DlssUpdater/Views/Pages/ChangelogPage.xaml.cs create mode 100644 DlssUpdater/Views/Pages/ChangelogPageControl.xaml create mode 100644 DlssUpdater/Views/Pages/ChangelogPageControl.xaml.cs delete mode 100644 DlssUpdater/Views/Pages/DLSSPage.xaml delete mode 100644 DlssUpdater/Views/Pages/DLSSPage.xaml.cs create mode 100644 DlssUpdater/Views/Pages/DlssPageControl.xaml create mode 100644 DlssUpdater/Views/Pages/DlssPageControl.xaml.cs create mode 100644 DlssUpdater/Views/Pages/GamePageControl.xaml create mode 100644 DlssUpdater/Views/Pages/GamePageControl.xaml.cs delete mode 100644 DlssUpdater/Views/Pages/GamesPage.xaml delete mode 100644 DlssUpdater/Views/Pages/GamesPage.xaml.cs create mode 100644 DlssUpdater/Views/Pages/SettingsCommonPageControl.xaml create mode 100644 DlssUpdater/Views/Pages/SettingsCommonPageControl.xaml.cs delete mode 100644 DlssUpdater/Views/Pages/SettingsPage.xaml delete mode 100644 DlssUpdater/Views/Pages/SettingsPage.xaml.cs create mode 100644 DlssUpdater/Views/Windows/GameConfigWindow.xaml create mode 100644 DlssUpdater/Views/Windows/GameConfigWindow.xaml.cs delete mode 100644 docs/images/anticheat.png delete mode 100644 docs/images/anticheat_warning.png delete mode 100644 docs/images/config_panel.png delete mode 100644 docs/images/dlss_page.png delete mode 100644 docs/images/games_page.png delete mode 100644 docs/images/settings_page.png delete mode 100644 docs/images/splashcreen.png diff --git a/DlssUpdater/App.xaml b/DlssUpdater/App.xaml index 828c5dd..8731166 100644 --- a/DlssUpdater/App.xaml +++ b/DlssUpdater/App.xaml @@ -2,15 +2,222 @@ x:Class="DlssUpdater.App" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" - xmlns:ui="http://schemas.lepo.co/wpfui/2022/xaml" + xmlns:adonisUi="clr-namespace:AdonisUI;assembly=AdonisUI" + xmlns:adonisExtensions="clr-namespace:AdonisUI.Extensions;assembly=AdonisUI" + xmlns:adonisControls="clr-namespace:AdonisUI.Controls;assembly=AdonisUI" + xmlns:adonisConverters="clr-namespace:AdonisUI.Converters;assembly=AdonisUI" DispatcherUnhandledException="OnDispatcherUnhandledException" Exit="OnExit" Startup="OnStartup"> + + - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/DlssUpdater/App.xaml.cs b/DlssUpdater/App.xaml.cs index 91708c6..815357f 100644 --- a/DlssUpdater/App.xaml.cs +++ b/DlssUpdater/App.xaml.cs @@ -4,16 +4,17 @@ using DlssUpdater.Services; using DlssUpdater.Singletons; using DlssUpdater.Singletons.AntiCheatChecker; -using DlssUpdater.ViewModels.Pages; -using DlssUpdater.ViewModels.Windows; -using DlssUpdater.Views.Pages; using DlssUpdater.Views.Windows; using DlssUpdater.Windows.Splashscreen; +using DLSSUpdater.Defines.UI.Pages; using DLSSUpdater.Singletons; +using DLSSUpdater.ViewModels.Pages; +using DLSSUpdater.ViewModels.Windows; +using DLSSUpdater.Views.Pages; +using DLSSUpdater.Views.Windows; using Microsoft.Extensions.Configuration; using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.Hosting; -using Wpf.Ui; using WpfBindingErrors; namespace DlssUpdater; @@ -36,31 +37,18 @@ public partial class App { services.AddHostedService(); - // Page resolver service - services.AddSingleton(); - - // Theme manipulation - services.AddSingleton(); - - // TaskBar manipulation - services.AddSingleton(); - - - // Service containing navigation, same as INavigationWindow... but without window - services.AddSingleton(); + // Windows + services.AddSingleton(); + services.AddSingleton(); - // Main window with navigation + // ViewModel services.AddSingleton(); - services.AddSingleton(); - services.AddSingleton(); - services.AddSingleton(); - services.AddSingleton(); - services.AddSingleton(); - services.AddSingleton(); - services.AddSingleton(); - services.AddSingleton(); - services.AddSingleton(); - services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(NLog.LogManager.GetCurrentClassLogger()); services.AddSingleton(); @@ -70,7 +58,13 @@ public partial class App services.AddSingleton(); services.AddSingleton(); - services.AddSingleton(); + // Pages + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); + services.AddSingleton(); }).Build(); /// diff --git a/DlssUpdater/Controls/ChangelogPanel.xaml b/DlssUpdater/Controls/ChangelogPanel.xaml new file mode 100644 index 0000000..a6d9458 --- /dev/null +++ b/DlssUpdater/Controls/ChangelogPanel.xaml @@ -0,0 +1,31 @@ + + + + + +