From 0d4c60c548ffc487c66ca055efb18c7f09faa0c6 Mon Sep 17 00:00:00 2001 From: sr55 Date: Fri, 6 Mar 2015 19:40:08 +0000 Subject: [PATCH] WinGui: Restore the preview functionality after refactoring. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@6969 b64f7644-9d1e-0410-96f1-a4d463321fa5 --- .../Interop/Model/Preview/PreviewSettings.cs | 13 ++++++++++++- .../Services/Scan/LibScan.cs | 3 ++- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/win/CS/HandBrake.ApplicationServices/Interop/Model/Preview/PreviewSettings.cs b/win/CS/HandBrake.ApplicationServices/Interop/Model/Preview/PreviewSettings.cs index af1403360..e2a07d1cc 100644 --- a/win/CS/HandBrake.ApplicationServices/Interop/Model/Preview/PreviewSettings.cs +++ b/win/CS/HandBrake.ApplicationServices/Interop/Model/Preview/PreviewSettings.cs @@ -16,6 +16,17 @@ namespace HandBrake.ApplicationServices.Interop.Model.Preview /// public class PreviewSettings : EncodeTask { - // TODO flesh this out into a proper model. + /// + /// Initializes a new instance of the class. + /// + /// + /// The task. + /// + public PreviewSettings(EncodeTask task) + : base(task) + { + } + + // TODO flesh this out into a proper model. } } diff --git a/win/CS/HandBrake.ApplicationServices/Services/Scan/LibScan.cs b/win/CS/HandBrake.ApplicationServices/Services/Scan/LibScan.cs index 1d5e94299..903497200 100644 --- a/win/CS/HandBrake.ApplicationServices/Services/Scan/LibScan.cs +++ b/win/CS/HandBrake.ApplicationServices/Services/Scan/LibScan.cs @@ -267,7 +267,8 @@ namespace HandBrake.ApplicationServices.Services.Scan BitmapImage bitmapImage = null; try { - bitmapImage = this.instance.GetPreview((PreviewSettings)job, preview); + PreviewSettings settings = new PreviewSettings(job); + bitmapImage = this.instance.GetPreview(settings, preview); } catch (AccessViolationException e) { -- 2.40.0