Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnsgar Radermacher2014-03-03 14:49:48 +0000
committerAnsgar Radermacher2014-03-03 14:51:10 +0000
commit7868dc22701b4f5636a28f8afdfab1b024a48508 (patch)
tree4872523b6433deb8f31644eb5cdca643ca8190d8 /plugins/uml/properties/org.eclipse.papyrus.uml.properties.xtext
parent1c33f80f4c00d6c657b913743eecb42959141b3e (diff)
downloadorg.eclipse.papyrus-7868dc22701b4f5636a28f8afdfab1b024a48508.tar.gz
org.eclipse.papyrus-7868dc22701b4f5636a28f8afdfab1b024a48508.tar.xz
org.eclipse.papyrus-7868dc22701b4f5636a28f8afdfab1b024a48508.zip
Bug 427025 - [OCL For Papyrus] Cannot create OCL constraints in Luna
- fix NPE in property sheet
Diffstat (limited to 'plugins/uml/properties/org.eclipse.papyrus.uml.properties.xtext')
-rw-r--r--plugins/uml/properties/org.eclipse.papyrus.uml.properties.xtext/src/org/eclipse/papyrus/uml/properties/xtext/sheet/AdvancedEditingPropertySectionFilter.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/plugins/uml/properties/org.eclipse.papyrus.uml.properties.xtext/src/org/eclipse/papyrus/uml/properties/xtext/sheet/AdvancedEditingPropertySectionFilter.java b/plugins/uml/properties/org.eclipse.papyrus.uml.properties.xtext/src/org/eclipse/papyrus/uml/properties/xtext/sheet/AdvancedEditingPropertySectionFilter.java
index 014c4edda46..b8bd9e2a7fa 100644
--- a/plugins/uml/properties/org.eclipse.papyrus.uml.properties.xtext/src/org/eclipse/papyrus/uml/properties/xtext/sheet/AdvancedEditingPropertySectionFilter.java
+++ b/plugins/uml/properties/org.eclipse.papyrus.uml.properties.xtext/src/org/eclipse/papyrus/uml/properties/xtext/sheet/AdvancedEditingPropertySectionFilter.java
@@ -14,6 +14,9 @@ public class AdvancedEditingPropertySectionFilter implements IFilter {
public boolean select(Object toTest) {
if (toTest instanceof IGraphicalEditPart) {
IGraphicalEditPart part = (IGraphicalEditPart) toTest;
+ if (part.resolveSemanticElement() == null) {
+ return false;
+ }
IPreferenceStore store = Activator.getDefault().getPreferenceStore();
String key = IDirectEditorsIds.EDITOR_FOR_ELEMENT
+ part.resolveSemanticElement().eClass().getInstanceClassName();

Back to the top