Bug 90646 [Viewers] SWTException from DeferredContentProvider
20050405 I get this exception when closing the view where I have a table using the DeferredContentProvider. org.eclipse.swt.SWTException: Widget is disposed at org.eclipse.swt.SWT.error(SWT.java:2896) at org.eclipse.swt.SWT.error(SWT.java:2819) at org.eclipse.swt.SWT.error(SWT.java:2790) at org.eclipse.swt.widgets.Widget.error(Widget.java:393) at org.eclipse.swt.widgets.Widget.checkWidget(Widget.java:295) at org.eclipse.swt.widgets.Table.getTopIndex(Table.java:1487) at org.eclipse.jface.viewers.deferred.DeferredContentProvider$TableViewerAdapter.getTopIndex(DeferredContentProvider.java:89) at org.eclipse.jface.viewers.deferred.ConcurrentTableUpdator.updateTable(ConcurrentTableUpdator.java:313) at org.eclipse.jface.viewers.deferred.ConcurrentTableUpdator.access$1(ConcurrentTableUpdator.java:299) at org.eclipse.jface.viewers.deferred.ConcurrentTableUpdator$1.run(ConcurrentTableUpdator.java:108) at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35) at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:118) at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:2871) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2530) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1570) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1534) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:306) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:143) at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:103) at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:228) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:156) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60) at java.lang.reflect.Method.invoke(Method.java:391) at org.eclipse.core.launcher.Main.invokeFramework(Main.java:315) at org.eclipse.core.launcher.Main.basicRun(Main.java:268) at org.eclipse.core.launcher.Main.run(Main.java:947) at org.eclipse.core.launcher.Main.main(Main.java:931)
bundles/org.eclipse.jface/src/org/eclipse/jface/viewers/deferred/DeferredContentProvider.java
if (provider != null) {
			provider.setSortOrder(sortOrder);
		}
	}
	
	/**
	 * Sets the filter for this content provider. This filter takes priority over
	 * anything that was supplied to the <code>TableViewer</code>. The filter
	 * must be capable of being used in a background thread.
	 * 
	 * @param toSet filter to set
	 */
	public void setFilter(IFilter toSet) {
		this.filter = toSet;
		if (provider != null) {
			provider.setFilter(toSet);
		}
	}
	
	/**
	 * Sets the maximum number of rows in the table. If the model contains more
	 * than this number of elements, only the top elements will be shown based on
	 * the current sort order. 
	 * 
	 * @param limit maximum number of rows to show or -1 if unbounded
	 */
	public void setLimit(int limit) {
		this.limit = limit;
		if (provider != null) {
			provider.setLimit(limit);