Author: adietish
Date: 2012-02-13 09:57:07 -0500 (Mon, 13 Feb 2012)
New Revision: 38656
Modified:
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationSelectionDialog.java
Log:
[JBIDE-10856] extracted #setApplicationSelected()
Modified:
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationSelectionDialog.java
===================================================================
---
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationSelectionDialog.java 2012-02-13
14:17:08 UTC (rev 38655)
+++
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationSelectionDialog.java 2012-02-13
14:57:07 UTC (rev 38656)
@@ -161,18 +161,23 @@
return new IDoubleClickListener() {
@Override
public void doubleClick(DoubleClickEvent event) {
- final ISelection selection = event.getSelection();
- if(selection instanceof StructuredSelection) {
- final Object firstElement = ((StructuredSelection) selection).getFirstElement();
- if(firstElement instanceof IApplication) {
- dialogModel.setSelectedApplication((IApplication) firstElement);
- close();
- }
- }
+// openDetailsDialog();
+ setApplicationSelected(event.getSelection());
}
};
}
+ private void setApplicationSelected(ISelection selection) {
+ if(selection instanceof StructuredSelection) {
+ final Object firstElement = ((StructuredSelection) selection).getFirstElement();
+ if(firstElement instanceof IApplication) {
+ IApplication application = (IApplication) firstElement;
+ dialogModel.setSelectedApplication(application);
+ close();
+ }
+ }
+ }
+
protected TableViewer createTable(Composite tableContainer) {
Table table = new Table(tableContainer, SWT.BORDER | SWT.FULL_SELECTION | SWT.V_SCROLL
| SWT.H_SCROLL);
int desiredHeight = table.getItemHeight() * 10 + table.getHeaderHeight();
Show replies by date