开发者

Strategies for keeping a .NET alt-tab replacement responsive after a long period of non-use?

I'm working on a simple alt-tab replacement program. It's implemented in C# as a hidden WPF window that's brought to the foreground by a global keyboard hotkey.

For the most part this works great, and the application window appears immediately after the hotkey is pressed. However, if it has been a long time since the user has activated the window, it 开发者_StackOverflow中文版can be slow in "spinning up," and take 3-5 seconds to appear. I assume it has something to do with Windows paging app's memory to disk.

Are there any good strategies for keeping the application responsive after long periods of inactivity?

(Since it's open source, you can look at the full code, if it helps.)


Why don't you just use a timer in your code that fires once every minute, and in that timer tick handler, execute some code. This should keep your process "active".

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜