From e0df513a93eed3530941d6f0e2f40dbb9d6af7b0 Mon Sep 17 00:00:00 2001 From: pizzaboxer Date: Thu, 11 May 2023 13:23:47 +0100 Subject: [PATCH] Rename HyperionDialog as ByfronDialog --- .../Dialogs/{HyperionDialog.xaml => ByfronDialog.xaml} | 2 +- .../{HyperionDialog.xaml.cs => ByfronDialog.xaml.cs} | 10 +++++----- Bloxstrap/Enums/BootstrapperStyle.cs | 2 +- Bloxstrap/Extensions/BootstrapperStyleEx.cs | 2 +- Bloxstrap/ViewModels/AppearanceViewModel.cs | 9 +++++++-- ...rionDialogViewModel.cs => ByfronDialogViewModel.cs} | 4 ++-- 6 files changed, 17 insertions(+), 12 deletions(-) rename Bloxstrap/Dialogs/{HyperionDialog.xaml => ByfronDialog.xaml} (99%) rename Bloxstrap/Dialogs/{HyperionDialog.xaml.cs => ByfronDialog.xaml.cs} (93%) rename Bloxstrap/ViewModels/{HyperionDialogViewModel.cs => ByfronDialogViewModel.cs} (80%) diff --git a/Bloxstrap/Dialogs/HyperionDialog.xaml b/Bloxstrap/Dialogs/ByfronDialog.xaml similarity index 99% rename from Bloxstrap/Dialogs/HyperionDialog.xaml rename to Bloxstrap/Dialogs/ByfronDialog.xaml index 75b19ce..2fbb704 100644 --- a/Bloxstrap/Dialogs/HyperionDialog.xaml +++ b/Bloxstrap/Dialogs/ByfronDialog.xaml @@ -1,4 +1,4 @@ - - /// Interaction logic for HyperionDialog.xaml + /// Interaction logic for ByfronDialog.xaml /// - public partial class HyperionDialog : IBootstrapperDialog + public partial class ByfronDialog : IBootstrapperDialog { - private readonly HyperionDialogViewModel _viewModel; + private readonly ByfronDialogViewModel _viewModel; public Bootstrapper? Bootstrapper { get; set; } @@ -60,9 +60,9 @@ namespace Bloxstrap.Dialogs } #endregion - public HyperionDialog() + public ByfronDialog() { - _viewModel = new HyperionDialogViewModel(this); + _viewModel = new ByfronDialogViewModel(this); DataContext = _viewModel; Title = App.Settings.Prop.BootstrapperTitle; Icon = App.Settings.Prop.BootstrapperIcon.GetIcon().GetImageSource(); diff --git a/Bloxstrap/Enums/BootstrapperStyle.cs b/Bloxstrap/Enums/BootstrapperStyle.cs index 733b570..cade7cb 100644 --- a/Bloxstrap/Enums/BootstrapperStyle.cs +++ b/Bloxstrap/Enums/BootstrapperStyle.cs @@ -7,6 +7,6 @@ LegacyDialog2011, ProgressDialog, FluentDialog, - HyperionDialog + ByfronDialog } } diff --git a/Bloxstrap/Extensions/BootstrapperStyleEx.cs b/Bloxstrap/Extensions/BootstrapperStyleEx.cs index 4191ea1..f25c616 100644 --- a/Bloxstrap/Extensions/BootstrapperStyleEx.cs +++ b/Bloxstrap/Extensions/BootstrapperStyleEx.cs @@ -14,7 +14,7 @@ namespace Bloxstrap.Extensions BootstrapperStyle.LegacyDialog2011 => new LegacyDialog2011(), BootstrapperStyle.ProgressDialog => new ProgressDialog(), BootstrapperStyle.FluentDialog => new FluentDialog(), - BootstrapperStyle.HyperionDialog => new HyperionDialog(), + BootstrapperStyle.ByfronDialog => new ByfronDialog(), _ => new FluentDialog() }; } diff --git a/Bloxstrap/ViewModels/AppearanceViewModel.cs b/Bloxstrap/ViewModels/AppearanceViewModel.cs index 7e0a469..ba85815 100644 --- a/Bloxstrap/ViewModels/AppearanceViewModel.cs +++ b/Bloxstrap/ViewModels/AppearanceViewModel.cs @@ -29,7 +29,12 @@ namespace Bloxstrap.ViewModels private void PreviewBootstrapper() { IBootstrapperDialog dialog = App.Settings.Prop.BootstrapperStyle.GetNew(); - dialog.Message = (App.Settings.Prop.BootstrapperStyle == BootstrapperStyle.HyperionDialog) ? "Style preview - Click the X button on top right to close" : "Style preview - Click Cancel to close"; + + if (App.Settings.Prop.BootstrapperStyle == BootstrapperStyle.ByfronDialog) + dialog.Message = "Style preview - Click the X button at the top right to close"; + else + dialog.Message = "Style preview - Click Cancel to close"; + dialog.CancelEnabled = true; dialog.ShowBootstrapper(); } @@ -75,7 +80,7 @@ namespace Bloxstrap.ViewModels { "Legacy (2011 - 2014)", BootstrapperStyle.LegacyDialog2011 }, { "Legacy (2009 - 2011)", BootstrapperStyle.LegacyDialog2009 }, { "Vista (2009 - 2011)", BootstrapperStyle.VistaDialog }, - { "Hyperion (2022 - Fake)", BootstrapperStyle.HyperionDialog }, + { "Fake Byfron (2023)", BootstrapperStyle.ByfronDialog }, }; public string Dialog diff --git a/Bloxstrap/ViewModels/HyperionDialogViewModel.cs b/Bloxstrap/ViewModels/ByfronDialogViewModel.cs similarity index 80% rename from Bloxstrap/ViewModels/HyperionDialogViewModel.cs rename to Bloxstrap/ViewModels/ByfronDialogViewModel.cs index d052fe5..20b8e46 100644 --- a/Bloxstrap/ViewModels/HyperionDialogViewModel.cs +++ b/Bloxstrap/ViewModels/ByfronDialogViewModel.cs @@ -5,7 +5,7 @@ using Bloxstrap.Dialogs; namespace Bloxstrap.ViewModels { - public class HyperionDialogViewModel : FluentDialogViewModel, INotifyPropertyChanged + public class ByfronDialogViewModel : FluentDialogViewModel, INotifyPropertyChanged { public string Version => $"Bloxstrap v{App.Version}"; // Using dark theme for default values. @@ -14,7 +14,7 @@ namespace Bloxstrap.ViewModels public Brush Foreground { get; set; } = new SolidColorBrush(Color.FromRgb(216, 216, 216)); public Brush IconColor { get; set; } = new SolidColorBrush(Color.FromRgb(255, 255, 255)); public Brush ProgressBarBackground { get; set; } = new SolidColorBrush(Color.FromRgb(86, 86, 86)); - public HyperionDialogViewModel(IBootstrapperDialog dialog) : base(dialog) + public ByfronDialogViewModel(IBootstrapperDialog dialog) : base(dialog) { } }