When my window desktop app loses focus, both rendering and updating come to a halt. This also happen in the HTML build and likely other builds as well.
While this behavior may be acceptable on mobile platforms where typically only one task is displayed at a time, it becomes inconvenient on desktop. Specifically, I want my app, which functions as a clock, to continue rendering even when I'm focused on another application.
Any suggestions on how to address this would be greatly appreciated!
While this behavior may be acceptable on mobile platforms where typically only one task is displayed at a time, it becomes inconvenient on desktop. Specifically, I want my app, which functions as a clock, to continue rendering even when I'm focused on another application.
Any suggestions on how to address this would be greatly appreciated!
Code:
Import mojo
Class MyApp Extends App
Field x:Float
Field y
Method OnCreate()
SetUpdateRate 60
Seed=Millisecs()
y=Rnd(100)
End
Method OnUpdate()
x=x+0.5
End
Method OnRender()
Cls 128,0,255
DrawRect 10,10,100,100
DrawText "Hello World!",x,y
End
Method OnSuspend()
Print "OnSuspend"
End
Method OnResume()
Print "OnResume"
End
End
Function Main()
New MyApp
End