Skip to main content

This CGIT instance is deprecated, and repositories have been moved to Gitlab or Github. See the repository descriptions for specific locations.

summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpfullbright2010-08-11 19:08:43 +0000
committerpfullbright2010-08-11 19:08:43 +0000
commit74884d45f75d563fe6bc800c6425b5fb8e3eb0de (patch)
tree81e6919083b1b9b438b737c8b9e971e77f4f7903 /jpa/plugins/org.eclipse.jpt.ui
parent73c7b0d80643fe65eaf157eff78f517c71abe3a3 (diff)
downloadwebtools.dali-74884d45f75d563fe6bc800c6425b5fb8e3eb0de.tar.gz
webtools.dali-74884d45f75d563fe6bc800c6425b5fb8e3eb0de.tar.xz
webtools.dali-74884d45f75d563fe6bc800c6425b5fb8e3eb0de.zip
bug 322419 - NPE when launching wizard with nothing selected (from toolbar dropdown)
Diffstat (limited to 'jpa/plugins/org.eclipse.jpt.ui')
-rw-r--r--jpa/plugins/org.eclipse.jpt.ui/src/org/eclipse/jpt/ui/internal/wizards/orm/MappingFileWizard.java6
1 files changed, 2 insertions, 4 deletions
diff --git a/jpa/plugins/org.eclipse.jpt.ui/src/org/eclipse/jpt/ui/internal/wizards/orm/MappingFileWizard.java b/jpa/plugins/org.eclipse.jpt.ui/src/org/eclipse/jpt/ui/internal/wizards/orm/MappingFileWizard.java
index f4b6c9128d..fcd635ca1e 100644
--- a/jpa/plugins/org.eclipse.jpt.ui/src/org/eclipse/jpt/ui/internal/wizards/orm/MappingFileWizard.java
+++ b/jpa/plugins/org.eclipse.jpt.ui/src/org/eclipse/jpt/ui/internal/wizards/orm/MappingFileWizard.java
@@ -80,8 +80,9 @@ public class MappingFileWizard extends Wizard
public void init(IWorkbench workbench, IStructuredSelection selection) {
this.initialSelection = selection;
+ this.mungedSelection = selection;
- if (selection == null || selection.isEmpty()) {
+ if (selection == null || selection.isEmpty()) {
return;
}
@@ -93,9 +94,6 @@ public class MappingFileWizard extends Wizard
if (container != null) {
this.mungedSelection = new StructuredSelection(container);
}
- else {
- this.mungedSelection = this.initialSelection;
- }
if (pUnit != null) {
getDataModel().setBooleanProperty(ADD_TO_PERSISTENCE_UNIT, true);

Back to the top