This commit is contained in:
bao-qian 2015-11-02 13:43:19 +00:00
parent 89dc9e7e7f
commit c9edc217fd
3 changed files with 8 additions and 4 deletions

View File

@ -1,7 +1,7 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2013
VisualStudioVersion = 12.0.21005.1
# Visual Studio 14
VisualStudioVersion = 14.0.23107.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Wox.Test", "Wox.Test\Wox.Test.csproj", "{FF742965-9A80-41A5-B042-D6C7D3A21708}"
EndProject
@ -60,6 +60,9 @@ EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Wox.Plugin.Everything", "Plugins\Wox.Plugin.Everything\Wox.Plugin.Everything.csproj", "{230AE83F-E92E-4E69-8355-426B305DA9C0}"
EndProject
Global
GlobalSection(Performance) = preSolution
HasPerformanceSessions = true
EndGlobalSection
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU

View File

@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading;
using System.Windows;
using Wox.CommandArgs;
using Wox.Core.Plugin;
@ -34,9 +35,9 @@ namespace Wox
DispatcherUnhandledException += ErrorReporting.DispatcherUnhandledException;
AppDomain.CurrentDomain.UnhandledException += ErrorReporting.UnhandledExceptionHandle;
//ThreadPool.QueueUserWorkItem(o => { ImageLoader.ImageLoader.PreloadImages(); });
Window = new MainWindow();
PluginManager.Init(Window);
ImageLoader.ImageLoader.PreloadImages();
CommandArgsFactory.Execute(e.Args.ToList());
}

View File

@ -70,7 +70,7 @@ namespace Wox.ImageLoader
if (!imageCache.ContainsKey(image.Key))
{
KeyValuePair<string, int> copyedImg = image;
App.Window.Dispatcher.Invoke(new Action(() => imageCache.Add(copyedImg.Key, img)));
imageCache.Add(copyedImg.Key, img);
}
}
}