Refresh GUI does not work instantly in macOS 11.2.3, rather reprints the GUI only after a time consuming process

If this were a serious bug more people would whine about it. And they would have whined way earlier.

We’ve been fighting this battle since the Real.Studio days. If you search for App.DoEvents() in the threads, you find my comments liberally sprinkled through the results.

It’s the kind of bug where you try Refresh and it doesn’t do what the docs say it’s supposed to do and you just shrug and figure that you are not understanding what it’s supposed to do and put up with controls not refreshing properly. Now after all this time I find that it wasn’t me after all and it’s been broken in Xojo all along :frowning: To me that’s pretty serious, but you’re right, it’s not something that makes applications not work at all, so the whining is not very audible.

2 Likes

As a long time Xojo user if things don’t seem to work as documented you get used just keep trying things until you find a way to get the result you want… But that is not very RADish, and does not help the product gain respect…

As i said we are used to it so fatalistically tended not to complain most of the time … until relatively recently.

-Karen

2 Likes

So what is the difference between this and DoEvents() for a desktop GUI application? Is this “safer” to use within a loop or other process on the main thread?

The runOnce runs the run loop once to do all pending events.
Basically this is similar to DoEvents except for Xojo’s internal event dispatch.

Anyway, the coding is a bad idea in the first place as you should not simply block the main thread for seconds.

2 Likes