I have a few different ideas on how to handle this, but not sure what the BEST way to go about it would be.
I have a script that I really want to run only 60 seconds, but it doesn’t need to run if nobody is looking at screen X.
I could of course put an if statement in the gateway timer script that checks for a flag that the window is open somewhere, but I want the script to run right away when the screen is first opened. I don’t want the user to wait for the 60s timer to run again before getting fresh data. Additionally, if another client opens the screen it shouldn’t cause a new run, just continue running every 60s.
I’m sure I’m missing something obvious here, thanks!