diff options
author | Pierre-Charles David | 2017-05-23 07:45:38 +0000 |
---|---|---|
committer | Pierre-Charles David | 2017-05-23 07:45:41 +0000 |
commit | bcdf84db921091e20e35308f1ed3451f8fc7c362 (patch) | |
tree | 713093889850b7d4760164bd1c6978be35b02d71 | |
parent | cd68d6bbc4450fc6b7673d2daaf0a3410d26751f (diff) | |
download | org.eclipse.sirius-bcdf84db921091e20e35308f1ed3451f8fc7c362.tar.gz org.eclipse.sirius-bcdf84db921091e20e35308f1ed3451f8fc7c362.tar.xz org.eclipse.sirius-bcdf84db921091e20e35308f1ed3451f8fc7c362.zip |
[510040] Fix potential IllegalStateException
The callback is called in async, so it may be executed at a time the
widgets have been disposed.
Bug: 510040
Change-Id: I405970ae6bd36a5f14a944396ba760d783bfb1a2
Signed-off-by: Pierre-Charles David <pierre-charles.david@obeo.fr>
-rw-r--r-- | plugins/org.eclipse.sirius.ui/src/org/eclipse/sirius/ui/tools/internal/graphicalcomponents/GraphicalRepresentationHandler.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/plugins/org.eclipse.sirius.ui/src/org/eclipse/sirius/ui/tools/internal/graphicalcomponents/GraphicalRepresentationHandler.java b/plugins/org.eclipse.sirius.ui/src/org/eclipse/sirius/ui/tools/internal/graphicalcomponents/GraphicalRepresentationHandler.java index 68260d6ee6..9058827095 100644 --- a/plugins/org.eclipse.sirius.ui/src/org/eclipse/sirius/ui/tools/internal/graphicalcomponents/GraphicalRepresentationHandler.java +++ b/plugins/org.eclipse.sirius.ui/src/org/eclipse/sirius/ui/tools/internal/graphicalcomponents/GraphicalRepresentationHandler.java @@ -161,7 +161,9 @@ public class GraphicalRepresentationHandler implements SessionManagerListener { // a model may have been added/removed from the model so we have to update content that is // relative to loaded models. PlatformUI.getWorkbench().getDisplay().asyncExec(() -> { - initInput(); + if (!treeViewer.getTree().isDisposed()) { + initInput(); + } }); } break; |