Project: Eclipse_Platform_UI
Bug 255576 [Model] No longer able to create a WorkbenchLabelProvider in a non-UI thread.
Reported: 2008-11-17 17:25:01 | Status: verified fixed

Build ID: M20080911-1700 Steps To Reproduce: 1. Create a WorkbenchLabelProvider in a non-UI thread. 2. Observe a NPE when JFaceResources.getResources() attempts to access the Display associated with the current thread. 3. Notice that Javadoc on JFaceResources.getResources() states that the method must be called from UI thread. More information: The following line was added to the WorkbenchLabelProvider constructor (line 77) in 3.4: this.resourceManager = new LocalResourceManager(JFaceResources.getResources()); The method JFaceResources.getResources() may only be called from a UI thread since it attempts to find the Display associated with the current thread.

Files changed in fix:
bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/model/WorkbenchLabelProvider.java