RFR: JMC-6555 Convert JOverflow plugin to SWT

Mario Torre neugens at redhat.com
Mon Aug 26 13:59:09 UTC 2019


On Mon, Aug 26, 2019 at 3:56 PM Arvin Kangcheng Xu <kxu at redhat.com> wrote:

> While updateModel() is not accessed outside the thread, it's possible
> to be called multiple times, before the previous calls finish, from
> the SWT event thread. From what I understand, SWT operates on some
> kind of event loop design. In the process of updating the UI, it's
> possible for some SWT listeners to be invoked and call updateModel()
> again. (eg. SelectionListener listener is called when the table
> content is updated.) Without this mIsUpdatingModel, it can easily
> result in an endless recursion. However, I do agree that guarding with
> a boolean is not the most elegant solution. Please let me know if
> there is a better approach coming across your mind.

But if the call is synchronous those calls would be queued, not? What
you described seems to imply a multi-thread call.

Cheers,
Mario

-- 
Mario Torre
Associate Manager, Software Engineering
Red Hat GmbH <https://www.redhat.com>
9704 A60C B4BE A8B8 0F30  9205 5D7E 4952 3F65 7898


More information about the jmc-dev mailing list