From 7fc9b35859cdc4d22bfc35e14fee0b3fa66cc3bd Mon Sep 17 00:00:00 2001 From: "marco.silipo" Date: Sat, 14 Mar 2020 19:45:50 +0100 Subject: [PATCH] Fixed NotSupportedException in ErrorWindow --- Arma.Studio.ErrorWindow/PluginMain.cs | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Arma.Studio.ErrorWindow/PluginMain.cs b/Arma.Studio.ErrorWindow/PluginMain.cs index aa9fcfb..8d58712 100644 --- a/Arma.Studio.ErrorWindow/PluginMain.cs +++ b/Arma.Studio.ErrorWindow/PluginMain.cs @@ -75,10 +75,13 @@ private void FileManagement_CollectionChanged(object sender, System.Collections. continue; } var lintinfos = await lintable.GetLintInfos(file.GetText(), CancellationToken.None); - foreach (var it in lintinfos) + System.Windows.Application.Current.Dispatcher.Invoke(() => { - this.LintInfos.Add(it); - } + foreach (var it in lintinfos) + { + this.LintInfos.Add(it); + } + }); } }, String.Format(Properties.Language.PBO_LintingFiles_0file, pbo.Name)); }