Option to have scripts run while widget is hidden.

I have a (script) widget that displays information from my calendar. It updates every 5 minutes to see if there's something interesting happening and how long it is until it happens. If there's nothing interesting going on, I'd like it to hide itself and come back when there is something interesting. The "hide itself when there's nothing happening" is easy. The problem is that the script then no longer runs, so it can't reappear when there is something.

At the moment, I have to keep it visible and have a "nothing happening" message, which is a bit unsightly.

Could we possibly have an option on scripts to run when the widget is invisible as well as when it's visible? Just a checkbox next to the "run when widget becomes visible" checkbox would do.

If you return an empty value the button will hide from the bar but the script will continue to run. (at least that's what is supposed to happen)

//edit: yup, I just tested it using this: