diff options
author | Milos Kleint | 2011-04-27 09:19:53 +0000 |
---|---|---|
committer | Milos Kleint | 2011-04-27 09:19:53 +0000 |
commit | 2fd4172712cd141cbb0811cc04879f2437faaf90 (patch) | |
tree | b30cdb897c31ce82773c052292da902eb58ff790 /org.eclipse.m2e.core.ui/src | |
parent | 6b6a6fa83807099bbd85ebfa1bed57c9a0e16788 (diff) | |
download | m2e-core-2fd4172712cd141cbb0811cc04879f2437faaf90.tar.gz m2e-core-2fd4172712cd141cbb0811cc04879f2437faaf90.tar.xz m2e-core-2fd4172712cd141cbb0811cc04879f2437faaf90.zip |
don't allow text edits in combo, got stuck indefinitely when I tried.
Diffstat (limited to 'org.eclipse.m2e.core.ui/src')
-rw-r--r-- | org.eclipse.m2e.core.ui/src/org/eclipse/m2e/core/ui/internal/wizards/LifecycleMappingPage.java | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/org.eclipse.m2e.core.ui/src/org/eclipse/m2e/core/ui/internal/wizards/LifecycleMappingPage.java b/org.eclipse.m2e.core.ui/src/org/eclipse/m2e/core/ui/internal/wizards/LifecycleMappingPage.java index 5ce55253..b37082d1 100644 --- a/org.eclipse.m2e.core.ui/src/org/eclipse/m2e/core/ui/internal/wizards/LifecycleMappingPage.java +++ b/org.eclipse.m2e.core.ui/src/org/eclipse/m2e/core/ui/internal/wizards/LifecycleMappingPage.java @@ -38,6 +38,7 @@ import org.eclipse.jface.viewers.ViewerComparator; import org.eclipse.jface.wizard.WizardPage; import org.eclipse.osgi.util.NLS; import org.eclipse.swt.SWT; +import org.eclipse.swt.custom.CCombo; import org.eclipse.swt.events.SelectionAdapter; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.graphics.FontMetrics; @@ -47,6 +48,7 @@ import org.eclipse.swt.layout.GridData; import org.eclipse.swt.layout.GridLayout; import org.eclipse.swt.widgets.Button; import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Control; import org.eclipse.swt.widgets.Group; import org.eclipse.swt.widgets.Label; import org.eclipse.swt.widgets.Text; @@ -216,6 +218,12 @@ public class LifecycleMappingPage extends WizardPage { addIgnoreProposals(values, prov); ComboBoxCellEditor edit = new ComboBoxCellEditor(treeViewer.getTree(), values.toArray(new String[values .size()])); + Control cont = edit.getControl(); + //this attempts to disable text edits in the combo.. + if (cont instanceof CCombo) { + CCombo combo = (CCombo)cont; + combo.setEditable(false); + } return edit; } throw new IllegalStateException(); |