diff --git a/libse/TaskbarList.cs b/libse/TaskbarList.cs index 79ab5b5c2..0ffef6404 100644 --- a/libse/TaskbarList.cs +++ b/libse/TaskbarList.cs @@ -8,7 +8,7 @@ namespace Nikse.SubtitleEdit.Core /// public static class TaskbarList { - private static readonly Lazy SupportedLazy = new Lazy(() => Environment.OSVersion.Version >= new Version(6, 1)); + private static readonly Lazy SupportedLazy = new Lazy(() => Environment.OSVersion.Platform == PlatformID.Win32NT && Environment.OSVersion.Version >= new Version(6, 1)); private static readonly Lazy TaskbarListLazy = new Lazy(() => (ITaskbarList3)new CLSID_TaskbarList()); public static bool Supported { get { return SupportedLazy.Value; } } diff --git a/src/Forms/AddWaveformBatch.cs b/src/Forms/AddWaveformBatch.cs index 8f3644864..113deb707 100644 --- a/src/Forms/AddWaveformBatch.cs +++ b/src/Forms/AddWaveformBatch.cs @@ -319,7 +319,7 @@ namespace Nikse.SubtitleEdit.Forms labelProgress.Text = string.Empty; labelInfo.Text = string.Empty; progressBar1.Visible = false; - TaskbarList.SetProgressState(Handle, TaskbarButtonProgressFlags.NoProgress); + TaskbarList.SetProgressState(Owner.Handle, TaskbarButtonProgressFlags.NoProgress); buttonRipWave.Enabled = true; buttonInputBrowse.Enabled = true; buttonSearchFolder.Enabled = true; @@ -342,7 +342,7 @@ namespace Nikse.SubtitleEdit.Forms { if (progressBar1.Value < progressBar1.Maximum) progressBar1.Value++; - TaskbarList.SetProgressValue(Handle, progressBar1.Value, progressBar1.Maximum); + TaskbarList.SetProgressValue(Owner.Handle, progressBar1.Value, progressBar1.Maximum); labelProgress.Text = progressBar1.Value + " / " + progressBar1.Maximum; }