Menu

#21 Bug - closing window via utility causes PSM to crash

v1.0 (example)
open
nobody
None
5
2014-01-31
2014-01-31
dsl101
No

Apologies - this is a complicated one to explain. I use a utility called AWM (www.actualtools.com) to add extra functionality to the regular Win32 windowing system. One of the things AWM can do is close / minimise / roll-up windows which aren't active. I want to use the PSM window as a kind of transient pop-up window rather than have it visible all the time. So, I created an AWM rule that would close the PSM window when it became inactive.

The problem is that when PSM launches, it opens its window, and if I then focus another window immediately, PSM crashes (its System Tray icon vanishes along with the window, and on running PSM again, I get a system.invalidoperationexception error dialog (closing this allows me to run PSM again without any errors).

I can workaround this by following a very specific procedure:

  1. Open PSM
  2. Without giving any other app focus (tricky, as I also use XMouse), close the PSM window via the red 'X' button (no crash, and System Tray icon still available)
  3. Open the PSM window via the System Tray icon

Once I've done this, I can happily let AWM close the PSM window by focussing on another app - it doesn't crash PSM now, providing I've been through the 'click the Red 'X' button' routine before PSM loses initial focus.

My guess is that there's some code behind that button click event which needs to run to avoid the crash, but which isn't triggered if PSM just receives a windows message (from AWM) to close the window.

Any thoughts gratefully appreciated!

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.