Downsize MB is now user-configurable
Probably doesn't matter most of the time since we resize down HEIC and PNG anyway... Closes #7
This commit is contained in:
@@ -706,7 +706,7 @@ class MainViewModel : BaseViewModel, IFontResolver, ICanCheckShutdown
|
||||
didAdjust = true;
|
||||
}
|
||||
// perform needed image manipulations
|
||||
if (isHEIC || isWebp || isPNG || (!isPDF && info.Length > 1.5 * 1024 * 1024 /* 1.5 MB */))
|
||||
if (isHEIC || isWebp || isPNG || (!isPDF && info.Length > _settings.ImageResizeThreshold * 1024 * 1024))
|
||||
{
|
||||
// Save image as jpg
|
||||
mImage.Quality = 80;
|
||||
|
||||
@@ -87,6 +87,16 @@ class SettingsViewModel: ChangeNotifier
|
||||
}
|
||||
}
|
||||
|
||||
public decimal ImageResizeThreshold
|
||||
{
|
||||
get => _settings.ImageResizeThreshold;
|
||||
set
|
||||
{
|
||||
_settings.ImageResizeThreshold = value;
|
||||
NotifyPropertyChanged(nameof(ImageResizeThreshold));
|
||||
}
|
||||
}
|
||||
|
||||
public async void ChooseOutputFolder()
|
||||
{
|
||||
var topLevel = _topLevelGrabber?.GetTopLevel();
|
||||
|
||||
Reference in New Issue
Block a user