diff options
| author | Dean Roberts | 2011-11-09 13:39:29 +0000 |
|---|---|---|
| committer | Paul Webster | 2011-11-09 13:39:29 +0000 |
| commit | 1d016deba61f8585bd568dddf6e51c25d06dcc65 (patch) | |
| tree | 183e3860d3fbc26a69da18189cb8a96f2fd8581c | |
| parent | 5e15d8954551428c720c68600403d5ceb8fc74b6 (diff) | |
| download | eclipse.platform.ui-1d016deba61f8585bd568dddf6e51c25d06dcc65.tar.gz eclipse.platform.ui-1d016deba61f8585bd568dddf6e51c25d06dcc65.tar.xz eclipse.platform.ui-1d016deba61f8585bd568dddf6e51c25d06dcc65.zip | |
Bug 362345 - TrimStack throws IAE
Always show the restore icon
| -rw-r--r-- | bundles/org.eclipse.e4.ui.workbench.addons.swt/src/org/eclipse/e4/ui/workbench/addons/minmax/TrimStack.java | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/bundles/org.eclipse.e4.ui.workbench.addons.swt/src/org/eclipse/e4/ui/workbench/addons/minmax/TrimStack.java b/bundles/org.eclipse.e4.ui.workbench.addons.swt/src/org/eclipse/e4/ui/workbench/addons/minmax/TrimStack.java index 8e643eb2a2a..ece1f94bb1b 100644 --- a/bundles/org.eclipse.e4.ui.workbench.addons.swt/src/org/eclipse/e4/ui/workbench/addons/minmax/TrimStack.java +++ b/bundles/org.eclipse.e4.ui.workbench.addons.swt/src/org/eclipse/e4/ui/workbench/addons/minmax/TrimStack.java @@ -456,13 +456,11 @@ public class TrimStack { if (isEditorStack()) { if (trimStackTB.getItemCount() == 1) { MUIElement data = getLeafPart(minimizedElement); - if (data != null) { - ToolItem ti = new ToolItem(trimStackTB, SWT.CHECK); - ti.setToolTipText(Messages.TrimStack_SharedAreaTooltip); - ti.setImage(getLayoutImage()); - ti.setData(data); - ti.addSelectionListener(toolItemSelectionListener); - } + ToolItem ti = new ToolItem(trimStackTB, SWT.CHECK); + ti.setToolTipText(Messages.TrimStack_SharedAreaTooltip); + ti.setImage(getLayoutImage()); + ti.setData(data); + ti.addSelectionListener(toolItemSelectionListener); } } else if (minimizedElement instanceof MPartStack) { MPartStack theStack = (MPartStack) minimizedElement; |
