@Override
public String getText(Object element) {
if (element instanceof DebugTargetImpl) {
DebugTargetImpl debugTargetImpl = (DebugTargetImpl) element;
JsLabelProvider labelProvider = debugTargetImpl.getLabelProvider();
try {
return labelProvider.getTargetLabel(debugTargetImpl);
} catch (DebugException e) {
ChromiumDebugPlugin.log(
new Exception("Failed to read debug target label", e)); //$NON-NLS-1$
}
return null;