Bug 126839 [DataBinding] IObservable refactoring
bundles/org.eclipse.jface.databinding/src/org/eclipse/jface/internal/databinding/viewers/TreeViewerUpdatableTree.java
}
	public void removeElement(final Object parentElement, final int index) {
		SyncRunnable runnable = new SyncRunnable() {
			public Object run() {
				removeElement(parentElement, index, true);
				return null;
			}
		};
		runnable.run();
	}
	
	
	protected void removeElement(final Object parentElement, final int index, final boolean fire) {
		if (hasChildren(parentElement)) {
			TreeNode parentNode = getTreeNode(parentElement);
			List children = parentNode.getChildren();
			if (children!=null) {
				final Object element = children.remove(index);			
				updateViewer(new Runnable() {			
					public void run() {
							viewer.remove(element);		
							if (fire) {
								fireChangeEvent(ChangeEvent.REMOVE, element, null, parentElement, index);
							}
					}
				});
			}
			if (children.size()==0) {
				parentNode.setChildren(null);
			}