diff --git a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/cview/CViewLabelProvider.java b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/cview/CViewLabelProvider.java index cddcad6a2d8..e762607b5fa 100644 --- a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/cview/CViewLabelProvider.java +++ b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/cview/CViewLabelProvider.java @@ -14,6 +14,7 @@ import org.eclipse.cdt.core.model.IIncludeReference; import org.eclipse.cdt.internal.ui.IAdornmentProvider; import org.eclipse.cdt.internal.ui.StandardCElementLabelProvider; import org.eclipse.core.runtime.IPath; +import org.eclipse.core.runtime.Path; /* * CViewLabelProvider @@ -46,6 +47,7 @@ public class CViewLabelProvider extends StandardCElementLabelProvider { IPath p = ref.getPath(); IPath parentLocation = ((IIncludeReference)parent).getPath(); if (parentLocation.isPrefixOf(p)) { + p = p.setDevice(null); p = p.removeFirstSegments(parentLocation.segmentCount()); } return p.toString();