always-on / always

Always-On Relational Agents for Social Support of Isolated Older Adults
http://www.cs.wpi.edu/~rich/always
4 stars 7 forks source link

Client startup cancels screensaver #445

Open charlesrich opened 10 years ago

charlesrich commented 10 years ago

@lring Testing the most recent version of the client with the boot.bat script, I noticed a new, bad behavior: As soon as the client starts, it now does something that cancels the screensaver, so that you temporarily see the two shell windows and the small-size agent.

I am not sure exactly what things in software could cancel the screensaver. To cancel it in Java, I simulate a mouse click on the screen. Maybe there is some kind of new "make visible" window command that was added recently to the client code?

Note that since booting usually happens in the middle of the night, this is not so bad, except that the screen will light up, which might be disturbing in a dark apartment. I added code (get update from develop) to turn the screen black from Java as soon as it connects to the client, but I cannot figure out how to do anything better unless we determine (e.g., by binary search) exactly where in the client startup the screensaver gets cancelled.

charlesrich commented 9 years ago

Yes, simulating a mouse press is exactly what will cancel the screensaver.

Can you turn the screensaver back on immediately after you do this by calling

  agent/bin/nircmdc.exe screensaver

-CR

charlesrich commented 9 years ago

This is now more important to fix, because the screen stays lighted (in the middle of the night) for a full 90 seconds while Java is waiting to start (Java calls screensaver as soon as it connects to the client).

Btw, putting a call to screensaver in the boot.bat file won't solve the problem, because it will probably run before the client does the click.