From fc6a34d987be363ff2768c4a651f9422ea2963f1 Mon Sep 17 00:00:00 2001 From: Matt Nadareski Date: Sun, 11 Oct 2020 20:46:24 -0700 Subject: [PATCH] Use CD-ROM as default when no type detection (fixes #237) --- CHANGELIST.md | 4 ++++ DICUI.Avalonia/MainWindow.axaml.cs | 9 +++++++-- DICUI/Windows/MainWindow.xaml.cs | 9 +++++++-- 3 files changed, 18 insertions(+), 4 deletions(-) diff --git a/CHANGELIST.md b/CHANGELIST.md index 608f0792..48766676 100644 --- a/CHANGELIST.md +++ b/CHANGELIST.md @@ -10,6 +10,10 @@ - Updated to BurnOutSharp 1.4.1 - Added split archives for AppVeyor builds - Remove subdump from both UI and run steps +- Removed default config file +- Fixed copy protect scan using wrong drive when using UI option +- Changed default to skip fixed drives +- Fixed default media type when skipping type detection ### 1.17.1 (2020-09-14) - Shuffled some shared, internal UI variables diff --git a/DICUI.Avalonia/MainWindow.axaml.cs b/DICUI.Avalonia/MainWindow.axaml.cs index dc634e5a..1b729565 100644 --- a/DICUI.Avalonia/MainWindow.axaml.cs +++ b/DICUI.Avalonia/MainWindow.axaml.cs @@ -125,8 +125,13 @@ namespace DICUI.Avalonia // Get the drive letter from the selected item if (this.Find("DriveLetterComboBox").SelectedItem is Drive drive) { - // Get the current media type - if (!UIOptions.Options.SkipMediaTypeDetection) + // Get the current media type, if possible + if (UIOptions.Options.SkipMediaTypeDetection) + { + ViewModels.LoggerViewModel.VerboseLog("Media type detection disabled, defaulting to CD-ROM"); + CurrentMediaType = MediaType.CDROM; + } + else { ViewModels.LoggerViewModel.VerboseLog("Trying to detect media type for drive {0}.. ", drive.Letter); CurrentMediaType = Validators.GetMediaType(drive); diff --git a/DICUI/Windows/MainWindow.xaml.cs b/DICUI/Windows/MainWindow.xaml.cs index a54c6add..9acba402 100644 --- a/DICUI/Windows/MainWindow.xaml.cs +++ b/DICUI/Windows/MainWindow.xaml.cs @@ -114,8 +114,13 @@ namespace DICUI.Windows // Get the drive letter from the selected item if (DriveLetterComboBox.SelectedItem is Drive drive) { - // Get the current media type - if (!UIOptions.Options.SkipMediaTypeDetection) + // Get the current media type, if possible + if (UIOptions.Options.SkipMediaTypeDetection) + { + ViewModels.LoggerViewModel.VerboseLog("Media type detection disabled, defaulting to CD-ROM"); + CurrentMediaType = MediaType.CDROM; + } + else { ViewModels.LoggerViewModel.VerboseLog("Trying to detect media type for drive {0}.. ", drive.Letter); CurrentMediaType = Validators.GetMediaType(drive);