If some process takes too long (about 5 seconds) and the GUI can't refresh, Windows add the words "Not Responding" to the title bar of some or all windows. Its been hard to figure out what is going on, but it seems this notification causes my MFC application to run the "OnSize" handler for the top most window (I suppose the one that got the "Not Responding" text added). This is very annoying and was causing my App to crash until I wrote special code to try to determine if a given call to OnSize is legitimate or not -- if not I just return. Now, at least, it doesn't crash -- but something in this process is taking a lot of time -- my App seems to freeze for a while to try to figure this all out, then resumes again. Hard to figure out what is going on. Anyone seen this before?
(btw - I know I should not have long processes in the GUI loop and they should be in a separate thread - and going thru my whole app and making sure that is true is one approach I'm working on, but I think this oddity can occur when some other process on the PC is taking a long time)