Author: scabanovich
Date: 2011-02-11 07:00:28 -0500 (Fri, 11 Feb 2011)
New Revision: 29109
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkLineFieldEditor.java
Log:
JBIDE-8264
https://issues.jboss.org/browse/JBIDE-8264
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkLineFieldEditor.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkLineFieldEditor.java 2011-02-11
09:41:35 UTC (rev 29108)
+++
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/attribute/editor/JavaHyperlinkLineFieldEditor.java 2011-02-11
12:00:28 UTC (rev 29109)
@@ -36,12 +36,15 @@
import org.eclipse.jdt.ui.JavaUI;
import org.eclipse.jface.action.Action;
import org.eclipse.jface.resource.JFaceResources;
+import org.eclipse.jface.viewers.StructuredSelection;
import org.eclipse.jface.wizard.WizardDialog;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.swt.widgets.Text;
+import org.eclipse.ui.IWorkbenchWizard;
import org.eclipse.ui.dialogs.FilteredItemsSelectionDialog;
+import org.eclipse.ui.menus.IWorkbenchWidget;
import org.jboss.tools.common.meta.XAttribute;
import org.jboss.tools.common.meta.key.WizardKeys;
import org.jboss.tools.common.model.XModelObject;
@@ -178,6 +181,9 @@
}
if(wizard == null) {
wizard = new NewClassWizard();
+ }
+ if(wizard instanceof IWorkbenchWizard) {
+ ((IWorkbenchWizard)wizard).init(ModelUIPlugin.getDefault().getWorkbench(), new
StructuredSelection());
}
wizard.setAdapter(wizardAdapter);
WizardDialog dialog = new
WizardDialog(ModelUIPlugin.getDefault().getWorkbench().getActiveWorkbenchWindow().getShell(),
wizard);