user2997681
user2997681

Reputation: 121

Wait for Display.getDefault.asyncexec

I am trying to use Display.getDefault().asyncExec to execute some work i need to do on my eclipse plugin but i need to wait until this work is done. I cannot wait for the thread without pausing the UI. How do i wait for Display?

Upvotes: 0

Views: 457

Answers (1)

Alexey Romanov
Alexey Romanov

Reputation: 170815

I am trying to use Display.getDefault().asyncExec to execute some work i need to do on my eclipse plugin but i need to wait until this work is done

Either use syncExec instead, which will return when the work is done, or add a call to the code which needs to wait at the end of the Runnable you pass to asyncExec.

Upvotes: 1

Related Questions