(feature) Launch into background, then take foreground on timer.


I went to the bathroom last night and upon my return my two-year old had managed to do severe damage. So my suggestion is that after a configurable amount of minutes, BS! becomes the foreground app, with an attendant option to send it to the background upon return.
Closed Jul 15, 2008 at 8:42 PM by
OK, I've added this timer which should help!
  void timer_Tick(object sender, EventArgs e)
     if (isOptionsDialogShown) return;

        IntPtr windowHandle = new WindowInteropHelper(Application.Current.MainWindow).Handle;
     catch (Exception)
        //Wish me luck!


shanselman wrote Jul 15, 2008 at 5:19 AM

I'm really sorry to hear that. Do you have any idea how they got into the system? You can look at the code if you think I missed anything.

Right now BS! is set to be Topmost=True. You're suggesting basically finding a way to "Reassert focus" in case someone gets out. I'll look into that, and any ideas are appreciated.

KevDog wrote Jul 16, 2008 at 1:31 AM

The stuff that happened above had nothing to do with BS!, it wasn't even running at the time. Let me write a better use case for it.
  1. Programmer launches BabySmash, tells it to wait in the background.
  2. Programmer pretends to work, typing aimlessly into the IDE, checking blogs, and plotting against his superiors.
  3. Programmer gets up and does something completely unrelated to the work at hand.
  4. BabySmash notices the absence of the computer and pops up at topmost.
  5. Programmer returns to computer, tells BS! to sleep again.
In essence, I'm looking for BS! to be my screensaver.