Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Piggott2011-03-14 18:08:28 +0000
committerMatthew Piggott2011-03-14 18:08:28 +0000
commite26726c91912fcfefc8aa28d0c8dabfa9c4aac92 (patch)
treeef8c7f41631399ecac4a637562c4bcfec1948d90
parent730c33122041f6b8f99f1a7d72af5c5372c991be (diff)
downloadm2e-core-3.7-M6a.tar.gz
m2e-core-3.7-M6a.tar.xz
m2e-core-3.7-M6a.zip
NPE in Import > Check out Maven Projects from SCM3.7-M6a
-rw-r--r--org.eclipse.m2e.core.ui/src/org/eclipse/m2e/core/ui/internal/wizards/MavenImportWizardPage.java65
1 files changed, 33 insertions, 32 deletions
diff --git a/org.eclipse.m2e.core.ui/src/org/eclipse/m2e/core/ui/internal/wizards/MavenImportWizardPage.java b/org.eclipse.m2e.core.ui/src/org/eclipse/m2e/core/ui/internal/wizards/MavenImportWizardPage.java
index d61a9602..fa0f82cf 100644
--- a/org.eclipse.m2e.core.ui/src/org/eclipse/m2e/core/ui/internal/wizards/MavenImportWizardPage.java
+++ b/org.eclipse.m2e.core.ui/src/org/eclipse/m2e/core/ui/internal/wizards/MavenImportWizardPage.java
@@ -157,6 +157,39 @@ public class MavenImportWizardPage extends AbstractMavenWizardPage {
}
}
});
+
+ rootDirectoryCombo.addModifyListener(new ModifyListener() {
+ public void modifyText(ModifyEvent e) {
+// if (rootDirectoryChanged()) {
+// scanProjects();
+// }
+ }
+ });
+ rootDirectoryCombo.addFocusListener(new FocusAdapter() {
+ public void focusLost(FocusEvent e) {
+ if(rootDirectoryChanged()) {
+ scanProjects();
+ }
+ }
+ });
+ rootDirectoryCombo.addSelectionListener(new SelectionAdapter() {
+ public void widgetDefaultSelected(SelectionEvent e) {
+ if(rootDirectoryChanged()) {
+ scanProjects();
+ }
+ }
+
+ public void widgetSelected(SelectionEvent e) {
+ if(rootDirectoryChanged()) {
+ //in runnable to have the combo popup collapse before disabling controls.
+ Display.getDefault().asyncExec(new Runnable() {
+ public void run() {
+ scanProjects();
+ }
+ });
+ }
+ }
+ });
}
final Label projectsLabel = new Label(composite, SWT.NONE);
@@ -294,38 +327,6 @@ public class MavenImportWizardPage extends AbstractMavenWizardPage {
if(locations!=null && !locations.isEmpty()) {
scanProjects();
}
-
- rootDirectoryCombo.addModifyListener(new ModifyListener() {
- public void modifyText(ModifyEvent e) {
-// if (rootDirectoryChanged()) {
-// scanProjects();
-// }
- }
- });
- rootDirectoryCombo.addFocusListener(new FocusAdapter() {
- public void focusLost(FocusEvent e) {
- if (rootDirectoryChanged()) {
- scanProjects();
- }
- }
- });
- rootDirectoryCombo.addSelectionListener(new SelectionAdapter() {
- public void widgetDefaultSelected(SelectionEvent e) {
- if (rootDirectoryChanged()) {
- scanProjects();
- }
- }
- public void widgetSelected(SelectionEvent e) {
- if (rootDirectoryChanged()) {
- //in runnable to have the combo popup collapse before disabling controls.
- Display.getDefault().asyncExec(new Runnable() {
- public void run() {
- scanProjects();
- }
- });
- }
- }
- });
}

Back to the top