aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeff Johnston2018-07-20 10:40:14 -0400
committerJeff Johnston2018-07-20 11:22:37 -0400
commit04ccf3d141e1871ede08141a5d8d6ddc0384ac2d (patch)
tree088479281c6caaaeb361097ce6deac5370167c41
parentd6937aadcf2b606bbab6bfde87e519816833348d (diff)
downloadorg.eclipse.linuxtools-04ccf3d141e1871ede08141a5d8d6ddc0384ac2d.tar.gz
org.eclipse.linuxtools-04ccf3d141e1871ede08141a5d8d6ddc0384ac2d.tar.xz
org.eclipse.linuxtools-04ccf3d141e1871ede08141a5d8d6ddc0384ac2d.zip
Bug 537236 - Fix BaseResourceAwareLaunchShortcut ClassCastException
- fix BaseResourceAwareLaunchShortcut to refer to selectedElement instead of selection Change-Id: Ifb0253028a96e7ff48b737074bd1592880599f3c Reviewed-on: https://git.eclipse.org/r/126398 Tested-by: CI Bot Reviewed-by: Jeff Johnston <jjohnstn@redhat.com>
-rw-r--r--containers/org.eclipse.linuxtools.docker.ui/src/org/eclipse/linuxtools/internal/docker/ui/launch/BaseResourceAwareLaunchShortcut.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/containers/org.eclipse.linuxtools.docker.ui/src/org/eclipse/linuxtools/internal/docker/ui/launch/BaseResourceAwareLaunchShortcut.java b/containers/org.eclipse.linuxtools.docker.ui/src/org/eclipse/linuxtools/internal/docker/ui/launch/BaseResourceAwareLaunchShortcut.java
index ae84b5690b..ff60e34660 100644
--- a/containers/org.eclipse.linuxtools.docker.ui/src/org/eclipse/linuxtools/internal/docker/ui/launch/BaseResourceAwareLaunchShortcut.java
+++ b/containers/org.eclipse.linuxtools.docker.ui/src/org/eclipse/linuxtools/internal/docker/ui/launch/BaseResourceAwareLaunchShortcut.java
@@ -79,7 +79,7 @@ public abstract class BaseResourceAwareLaunchShortcut implements ILaunchShortcut
return (IResource) selectedElement;
} else if (selectedElement instanceof IAdaptable) {
// may return null, which will be dealt with in the caller method
- return ((IAdaptable) selection).getAdapter(IResource.class);
+ return ((IAdaptable) selectedElement).getAdapter(IResource.class);
}
// if the selected element is neither a resource nor an 'adaptable'
return null;