Bug 54096 deleting elements in the outline asks for confirmation twice
i20040304 Deleting Java outline elements is behaving in a weird way in this build. I have a Java source open. I select some methods in the Outline view, and press <Del>. A dialog opens saying "Are you sure you want to delete these <#elems> elements?". I say "Yes", but the dialog opens for the second time. And while the dialog is showing up, the elements are removed from the outline. Of course, confirm the second deletion fails because the elemnts are not there anymore.
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
if (action.isEnabled())
				action.run();
		}
	}
	
	
	
	protected void fillToolBar(IToolBarManager tbm) {
	}	
	/**
	 * Called when the context menu is about to open.
	 * Override to add your own context dependent menu contributions.
	 */
	public void menuAboutToShow(IMenuManager menu) {
		JavaPlugin.createStandardGroups(menu);
		
		IStructuredSelection selection= (IStructuredSelection) fViewer.getSelection();
		int size= selection.size();		
		Object element= selection.getFirstElement();
		
		if (size == 1)
			addOpenNewWindowAction(menu, element);
		fActionGroups.setContext(new ActionContext(selection));
		fActionGroups.fillContextMenu(menu);
		fActionGroups.setContext(null);
	}
	
	private void addOpenNewWindowAction(IMenuManager menu, Object element) {
		if (element instanceof IJavaElement) {
			element= ((IJavaElement)element).getResource();