private void handleDoubleClick(DoubleClickEvent e){
  ISelection selection=e.getSelection();
  if (selection instanceof IStructuredSelection) {
    IStructuredSelection structured=(IStructuredSelection)selection;
    if (structured.size() == 1) {
      Object first=structured.getFirstElement();
      if (first instanceof ISVNRemoteFile) {
        openAction.selectionChanged(null,selection);
        openAction.run(null);
      }
 else {
        treeViewer.setExpandedState(first,!treeViewer.getExpandedState(first));
      }
    }
  }
}

private void handleDoubleClick ( DoubleClickEvent e ) { ISelection selection = e . getSelection ( ) ; if ( selection instanceof IStructuredSelection ) { IStructuredSelection structured = ( IStructuredSelection ) selection ; if ( structured . size ( ) == 1 ) { Object first = structured . getFirstElement ( ) ; if ( first instanceof ISVNRemoteFile ) { openAction . selectionChanged ( null , selection ) ; openAction . run ( null ) ; } else { treeViewer . setExpandedState ( first , ! treeViewer . getExpandedState ( first ) ) ; } } } }
the mouse has been double - clicked in the tree , perform appropriate behaviour .
