Package org.eclipse.e4.ui.di
Class UISynchronize
java.lang.Object
org.eclipse.e4.ui.di.UISynchronize
- Direct Known Subclasses:
DisplayUISynchronize
Widget toolkit abstract to synchronize back into the UI-Thread from other
threads
- Since:
- 1.0
- Restriction:
- This class is not intended to be subclassed by clients.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionabstract void
Schedules the runnable on the UI-Thread for execution and returns immediatelyprotected abstract boolean
Request to perform an event dispatch cycle.protected abstract boolean
isUIThread
(Thread thread) Checks if the given thread is the UI-Thread.protected abstract void
showBusyWhile
(Runnable runnable) Shows a busy-indicator to the user while this runnable is executed, long running operations in the UI thread may freeze the UI.abstract void
Executes the runnable on the UI-Thread and blocks until the runnable is finished
-
Constructor Details
-
UISynchronize
public UISynchronize()
-
-
Method Details
-
syncExec
Executes the runnable on the UI-Thread and blocks until the runnable is finished- Parameters:
runnable
- the runnable to execute
-
asyncExec
Schedules the runnable on the UI-Thread for execution and returns immediately- Parameters:
runnable
- the runnable to execute
-
isUIThread
Checks if the given thread is the UI-Thread.- Parameters:
thread
- to check- Returns:
true
if the thread is the UI-Threadfalse
otherwise- Since:
- 1.3
-
showBusyWhile
Shows a busy-indicator to the user while this runnable is executed, long running operations in the UI thread may freeze the UI.- Parameters:
runnable
- the runnable to execute- Since:
- 1.3
-
dispatchEvents
protected abstract boolean dispatchEvents()Request to perform an event dispatch cycle.- Returns:
true
if there might be more work to performfalse
otherwise- Since:
- 1.3
-