summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLaurent Wouters2014-04-14 07:07:15 (EDT)
committerLaurent Wouters2014-04-14 07:20:11 (EDT)
commite28849f7903a6e0927ae8104bcda61033ce2273c (patch)
tree4b39fa5485e03c15377cabb02f57a87b7223282a
parent182c1a1383dd44f82f45c7fee72fbf18832e08b8 (diff)
downloadorg.eclipse.papyrus-e28849f7903a6e0927ae8104bcda61033ce2273c.zip
org.eclipse.papyrus-e28849f7903a6e0927ae8104bcda61033ce2273c.tar.gz
org.eclipse.papyrus-e28849f7903a6e0927ae8104bcda61033ce2273c.tar.bz2
Fixed viewpoint-related NPE when destroying tablesrefs/changes/52/24952/2
Change-Id: If7b067202ebedd792f9cb68755aba04d7890cafe Signed-off-by: Laurent Wouters <laurent.wouters@cea.fr>
-rw-r--r--plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.properties/src/org/eclipse/papyrus/infra/nattable/properties/modelelement/NatTableModelElement.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.properties/src/org/eclipse/papyrus/infra/nattable/properties/modelelement/NatTableModelElement.java b/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.properties/src/org/eclipse/papyrus/infra/nattable/properties/modelelement/NatTableModelElement.java
index 00ec6b1..991a505 100644
--- a/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.properties/src/org/eclipse/papyrus/infra/nattable/properties/modelelement/NatTableModelElement.java
+++ b/plugins/infra/nattable/org.eclipse.papyrus.infra.nattable.properties/src/org/eclipse/papyrus/infra/nattable/properties/modelelement/NatTableModelElement.java
@@ -580,10 +580,16 @@ public class NatTableModelElement extends EMFModelElement {
public void dispose() { }
public boolean isLabelProperty(Object element, String property) { return false; }
public Image getImage(Object element) {
+ if (element == null) {
+ return null;
+ }
ViewPrototype proto = ViewPrototype.get((PapyrusView)element);
return proto.getIcon();
}
public String getText(Object element) {
+ if (element == null) {
+ return null;
+ }
ViewPrototype proto = ViewPrototype.get((PapyrusView)element);
return proto.getQualifiedName();
}