Bug 32254 [Viewers] AbstractTreeViewer uses HashSet to remember expansion state
I20030216 The custom hash table should be used instead. Otherwise expansion state may be lost due to a different equals implementation of the element and the IElementComparer.
bundles/org.eclipse.jface/src/org/eclipse/jface/viewers/CheckboxTreeViewer.java
checkedElements.add(elements[i]);
	}
	Control tree = getControl();
	tree.setRedraw(false);
	internalSetChecked(checkedElements, tree);
	tree.setRedraw(true);
}
/**
 * Sets the grayed state for the given element in this viewer.
 *
 * @param element the element
 * @param state <code>true</code> if the item should be grayed,
 *  and <code>false</code> if it should be ungrayed
 * @return <code>true</code> if the gray state could be set, 
 *  and <code>false</code> otherwise
 */
public boolean setGrayed(Object element, boolean state) {
	Assert.isNotNull(element);
	Widget widget = internalExpand(element, false);
	if (widget instanceof TreeItem) {
		((TreeItem) widget).setGrayed(state);
		return true;
	}
	return false;
}
/**
 * Check and gray the selection rather than calling both
 * setGrayed and setChecked as an optimization.
 * @param element the item being checked
 * @param state a boolean indicating selection or deselection