Actually it’s a little more complicated than the subject line:
The base window in my Photon app has a button that brings up Window-A. When the user is done twiddling there, a “Done” button in Window-A closes it. If I then close the base window, everything (Momentics, Photon, etc.) is in fine shape. Another region within the base window has a button that brings up Window-B which is nearly a clone of Window-A in terms of content and mode of realization. The Window-B “Done” button closes its window nicely.
Here’s the nasty part: After closing Window-B and closing the base window, the next mouse click anywhere except in the shelf causes a black screen. The mouse cursor is visible and moves but, otherwise, nothing works (e.g. Ctrl + Alt + digit does not get you another Photon screen). If I close the base window while Window-B is open, the app exits gracefully and all is well. If I run the app outside of Momentics, the same bad behavior happens. There is something about the exiting of Window-B that puts Photon in an unstable state.
Hints? Maybe the callback that is supposed to simply close Window-B with a “Done:” could be implemented differently or with a diagnostic of some kind?
Stumped in Seattle…
The beauty of Photon’s design is that you are dealing with independent processes. They only talk via message passing. It is very unlikely that the order of events in your process could cause Photon to become unstable. There are some ugly scenerios you can get into with a resource manager but I don’t think this is the case for your example. My guess is that in closing Window-B, you get into a hard loop of some kind. You might try the following. Start your program at a lower priority. Have a terminal window ready, and when the problem occurs, run pidin and see what state things are in. If your program is in READY mode, that is sign that it may be in a loop.
Thanks for your thoughts on this matter. I wish there were a loop somewhere to look at but, right now, I have only a prototype GUI and no communication with another process and bare minimum responses to widget events. When I ran this application as a stand-alone (outside Momentics) I did have a terminal window open and, after closing the app, I clicked on its window and, blooey, blackness…
If you feel comfortable posting it, why not? Someone will take a look.
There was another Topic already, “Black Screen of Death”
They concluded in the end to a pwm crash, which was caused by false Flags
Ph_WM_FOCUS flag in Pt_ARG_WINDOW_MANAGED_FLAGS
I think this will help here too, as we have the same problems with black screens, but reproducable,
after opening and leaving a window twice in the app, the next click causes a black screen with mouse
You also can still run apps, which are shown in front of the black “layer” (try per telnet)
GL for us both