Free, open-source file converter. Convert 263 formats offline by drag & drop — images, PDF, Word, Excel, PowerPoint, HWP/HWPX, video, audio, e-books and archives. No upload, no Office needed.
C# audio-converteravaloniabatch-conversionconvertercsharpdocument-converterdocx-to-pdfdotnetdrag-and-dropfile-conversionfile-converterheic-converterhwphwpximage-converterlinuxmacospdf-convertervideo-converterwindows
Guard the close-action and PDF compression choices like the others
KnifeLemon7076bcd4c92c
diff --git a/src/Filee.App/ViewModels/Pages/GeneralPageViewModel.cs b/src/Filee.App/ViewModels/Pages/GeneralPageViewModel.csindex d595e3bf..c67b9e2e 100644--- a/src/Filee.App/ViewModels/Pages/GeneralPageViewModel.cs+++ b/src/Filee.App/ViewModels/Pages/GeneralPageViewModel.cs@@ -86,10 +86,10 @@ public sealed partial class GeneralPageViewModel : ObservableObject, IDisposable[ObservableProperty] private Choice<CloseAction> _closeChoice;- partial void OnCloseChoiceChanged(Choice<CloseAction> value)+ partial void OnCloseChoiceChanged(Choice<CloseAction>? oldValue, Choice<CloseAction> newValue){- if (_store.Settings.CloseAction != value.Value)- Save(s => s.CloseAction = value.Value);+ if (!Choices.Restore(oldValue, newValue, v => CloseChoice = v) && _store.Settings.CloseAction != newValue.Value)+ Save(s => s.CloseAction = newValue.Value);}// The close dialog may answer "Don't ask again" while this page stays open behind the hidden window.diff --git a/src/Filee.App/ViewModels/PresetEditorViewModel.cs b/src/Filee.App/ViewModels/PresetEditorViewModel.csindex f3c2423e..cbba2856 100644--- a/src/Filee.App/ViewModels/PresetEditorViewModel.cs+++ b/src/Filee.App/ViewModels/PresetEditorViewModel.cs@@ -364,6 +364,8 @@ public sealed partial class PresetEditorViewModel : ObservableObjectpartial void OnWavFormatChanged(Choice<WavSampleFormat>? oldValue, Choice<WavSampleFormat> newValue) => Choices.Restore(oldValue, newValue, v => WavFormat = v);partial void OnArchiveLevelChanged(Choice<ArchiveLevel>? oldValue, Choice<ArchiveLevel> newValue) => Choices.Restore(oldValue, newValue, v => ArchiveLevel = v);partial void OnTraceModeChanged(Choice<TracingMode>? oldValue, Choice<TracingMode> newValue) => Choices.Restore(oldValue, newValue, v => TraceMode = v);+ partial void OnCompressionLevelChanged(Choice<PdfCompression>? oldValue, Choice<PdfCompression> newValue) =>+ Choices.Restore(oldValue, newValue, v => CompressionLevel = v);private string TargetId => Target.Value;private FormatCategory? TargetCategory => FormatRegistry.FindById(TargetId)?.Category;