diff options
author | ptessier | 2011-07-28 09:35:56 +0000 |
---|---|---|
committer | ptessier | 2011-07-28 09:35:56 +0000 |
commit | f117bc86982b85ddc392745593e734653feb8815 (patch) | |
tree | 783cbe7f1d21ee9e5c3b40bcd2ccf0a3fcfbe862 /plugins/others | |
parent | f83d58a56473a7d13e752c272b218d0b69349284 (diff) | |
download | org.eclipse.papyrus-f117bc86982b85ddc392745593e734653feb8815.tar.gz org.eclipse.papyrus-f117bc86982b85ddc392745593e734653feb8815.tar.xz org.eclipse.papyrus-f117bc86982b85ddc392745593e734653feb8815.zip |
merge to fix bug 332016: [Profile] ClassCastException in context menu
https://bugs.eclipse.org/bugs/show_bug.cgi?id=332016
Diffstat (limited to 'plugins/others')
-rw-r--r-- | plugins/others/org.eclipse.papyrus.profile/src/org/eclipse/papyrus/profile/ui/actions/AbstractViewActionDelegate.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/plugins/others/org.eclipse.papyrus.profile/src/org/eclipse/papyrus/profile/ui/actions/AbstractViewActionDelegate.java b/plugins/others/org.eclipse.papyrus.profile/src/org/eclipse/papyrus/profile/ui/actions/AbstractViewActionDelegate.java index 39a39433a3d..f9edf9701e9 100644 --- a/plugins/others/org.eclipse.papyrus.profile/src/org/eclipse/papyrus/profile/ui/actions/AbstractViewActionDelegate.java +++ b/plugins/others/org.eclipse.papyrus.profile/src/org/eclipse/papyrus/profile/ui/actions/AbstractViewActionDelegate.java @@ -91,13 +91,15 @@ public abstract class AbstractViewActionDelegate implements IViewActionDelegate * the new selected element */ protected void setSelectedElement(Object selectedElement) { - this.selectedElement = (Element)selectedElement; + if( selectedElement instanceof Element){ + this.selectedElement = (Element)selectedElement; + } } /** * Returns current selected element * - * @return current selected element + * @return current selected element may be null */ protected Element getSelectedElement() { return selectedElement; |