summaryrefslogtreecommitdiffstatsabout
diff options
context:
space:
mode:
authorMarco Descher2013-03-18 12:54:32 (EDT)
committer Paul Webster2013-03-18 12:54:32 (EDT)
commitfcb702818ec1dee00c5af2fe745e30355e039dc0 (patch)
treef4d747061e89e5212f967984a29268788151b9cd
parent092f6e09e79a9b8a8fc36f205f4d61df420283d4 (diff)
downloadeclipse.platform.ui-fcb702818ec1dee00c5af2fe745e30355e039dc0.zip
eclipse.platform.ui-fcb702818ec1dee00c5af2fe745e30355e039dc0.tar.gz
eclipse.platform.ui-fcb702818ec1dee00c5af2fe745e30355e039dc0.tar.bz2
Bug 403433 - Fix for Bug397677 does not consider logger being optional
-rw-r--r--bundles/org.eclipse.e4.ui.workbench.renderers.swt/src/org/eclipse/e4/ui/workbench/renderers/swt/HandledContributionItem.java7
1 files changed, 5 insertions, 2 deletions
diff --git a/bundles/org.eclipse.e4.ui.workbench.renderers.swt/src/org/eclipse/e4/ui/workbench/renderers/swt/HandledContributionItem.java b/bundles/org.eclipse.e4.ui.workbench.renderers.swt/src/org/eclipse/e4/ui/workbench/renderers/swt/HandledContributionItem.java
index ef1baf0..89db426 100644
--- a/bundles/org.eclipse.e4.ui.workbench.renderers.swt/src/org/eclipse/e4/ui/workbench/renderers/swt/HandledContributionItem.java
+++ b/bundles/org.eclipse.e4.ui.workbench.renderers.swt/src/org/eclipse/e4/ui/workbench/renderers/swt/HandledContributionItem.java
@@ -280,8 +280,11 @@ public class HandledContributionItem extends ContributionItem {
model = item;
setId(model.getElementId());
generateCommand();
- if (model.getCommand() == null)
- logger.error("Element " + model.getElementId() + " invalid, no command defined."); //$NON-NLS-1$ //$NON-NLS-2$
+ if (model.getCommand() == null) {
+ if (logger != null) {
+ logger.error("Element " + model.getElementId() + " invalid, no command defined."); //$NON-NLS-1$ //$NON-NLS-2$
+ }
+ }
updateVisible();
}