<div dir="ltr">Thank you SO MUCH for explaining that!<div>Wrapping some of my code in a block and sending <font face="monospace">#fork</font> to it works perfectly.</div></div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">On Fri, Jan 17, 2025 at 11:14 AM Weslleymberg Lisboa via Cuis-dev <<a href="mailto:cuis-dev@lists.cuis.st">cuis-dev@lists.cuis.st</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex">Hi, Mark<br>
<br>
It seems your method is delaying UI updades. AFAIK our code runs on the <br>
UI process by default, so long-running computations will block the UI. <br>
You can see this by evaluating:<br>
<br>
1 to: 10 do: [ :n |<br>
n print.<br>
(Delay forSeconds: 1) wait. ]<br>
<br>
On Windows, my transcript updates but the rest of the UI freezes completly.<br>
<br>
To avoid this you can start the long-running method on a new process:<br>
<br>
[ 1 to: 10 do: [ :n |<br>
n print.<br>
(Delay forSeconds: 1) wait. ]] fork.<br>
<br>
If you want to control when to start your computation, you can call <br>
#newProcess instead of #fork and save the returned process so you can <br>
call #resume on it later.<br>
<br>
<br>
Em 17/01/2025 09:48, Mark Volkmann via Cuis-dev escreveu:<br>
> I have a long-running method (a couple of seconds) that is invoked by <br>
> clicking a button. At the beginning of the method I want to write to the <br>
> Transcript and update the text in a LabelMorph. But it seems both <br>
> updates get batched and I don't see the results until my method finishes <br>
> executing. Is there a way I can "flush" those updates so they take place <br>
> immediately? I see that Transcript has a flush method, but sending that <br>
> message didn't cause the Transcript to update immediately.<br>
> <br>
> -- <br>
> R. Mark Volkmann<br>
> Object Computing, Inc.<br>
> <br>
<br>
-- <br>
Wéslleymberg Lisboa<br>
Graduado em Sistemas de Informação<br>
Docente no IFFluminense - Campus Itaboraí<br>
<br>
-- <br>
Cuis-dev mailing list<br>
<a href="mailto:Cuis-dev@lists.cuis.st" target="_blank">Cuis-dev@lists.cuis.st</a><br>
<a href="https://lists.cuis.st/mailman/listinfo/cuis-dev" rel="noreferrer" target="_blank">https://lists.cuis.st/mailman/listinfo/cuis-dev</a><br>
</blockquote></div><div><br clear="all"></div><div><br></div><span class="gmail_signature_prefix">-- </span><br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><div><font face="arial, helvetica, sans-serif">R. Mark Volkmann</font></div><div><span style="font-size:12.8px"><font face="arial, helvetica, sans-serif">Object Computing, Inc.</font></span></div></div></div></div></div></div></div></div>