Bug 186025 [Viewers] Virtual Manager should be cleared when Viewer is disposed
Got a nasty memory leak where the Workbench would keep my disposed viewer in a field since it was registered as a selection provider. In StructuredViewer#handleDisposed(), the input is set to null, however this does not clear a possible virtual manager being used from the Table Viewer. The Table Viewer should clear the cache of the virtual manager on handleDispose to make sure, no reference to any model object is retained.
bundles/org.eclipse.jface/src/org/eclipse/jface/viewers/AbstractTableViewer.java
}
	protected void hookControl(Control control) {
		super.hookControl(control);
		initializeVirtualManager(getControl().getStyle());
	}
	/**
	 * Initialize the virtual manager to manage the virtual state if the table
	 * is VIRTUAL. If not use the default no-op version.
	 *
	 * @param style
	 */
	private void initializeVirtualManager(int style) {
		if ((style & SWT.VIRTUAL) == 0) {
			return;
		}
		virtualManager = new VirtualManager();
	}
	/**
	 * Adds the given elements to this table viewer. If this viewer does not
	 * have a sorter, the elements are added at the end in the order given;
	 * otherwise the elements are inserted at appropriate positions.
	 * <p>
	 * This method should be called (by the content provider) when elements have
	 * been added to the model, in order to cause the viewer to accurately
	 * reflect the model. This method only affects the viewer, not the model.
	 * </p>
	 *
	 * @param elements
	 *            the elements to add
	 */