use of org.eclipse.jdt.internal.debug.ui.breakpoints.AbstractJavaBreakpointEditor in project xtext-eclipse by eclipse.
the class XbaseBreakpointDetailPaneFactory method createDetailPane.
@Override
public IDetailPane createDetailPane(String paneID) {
if (XBASE_DETAIL_PANE.equals(paneID)) {
return new LineBreakpointDetailPane() {
@Override
public void display(IStructuredSelection selection) {
super.display(selection);
AbstractJavaBreakpointEditor editor = getEditor();
Object input = null;
if (selection != null && selection.size() == 1) {
input = selection.getFirstElement();
}
try {
if (input instanceof IJavaStratumLineBreakpoint) {
IJavaStratumLineBreakpoint stratumBreakpoint = (IJavaStratumLineBreakpoint) input;
URI uri = URI.createURI((String) stratumBreakpoint.getMarker().getAttribute(StratumBreakpointAdapterFactory.ORG_ECLIPSE_XTEXT_XBASE_SOURCE_URI));
IResourceServiceProvider resourceServiceProvider = registry.getResourceServiceProvider(uri);
if (resourceServiceProvider != null) {
JavaBreakPointProvider javaBreakPointProvider = resourceServiceProvider.get(JavaBreakPointProvider.class);
input = javaBreakPointProvider.getBreakpointWithJavaLocation(stratumBreakpoint);
}
}
editor.setInput(input);
} catch (CoreException e) {
JDIDebugUIPlugin.log(e);
}
}
};
} else {
return super.createDetailPane(paneID);
}
}
Aggregations