xdebugger: allow to hide unrelated breakpoint types in breakpoints dialog

This commit is contained in:
nik
2011-08-08 18:46:15 +04:00
parent e2d96728ca
commit cdf8f184c6
2 changed files with 8 additions and 2 deletions
@@ -163,6 +163,10 @@ public abstract class XBreakpointType<B extends XBreakpoint<P>, P extends XBreak
return null;
}
public boolean shouldShowInBreakpointsDialog(@NotNull Project project) {
return true;
}
@Nullable @NonNls
public String getBreakpointsDialogHelpTopic() {
return null;
@@ -62,8 +62,10 @@ public class XBreakpointPanelProvider extends BreakpointPanelProvider<XBreakpoin
XBreakpointType<?,?>[] types = XBreakpointUtil.getBreakpointTypes();
ArrayList<AbstractBreakpointPanel<XBreakpoint>> panels = new ArrayList<AbstractBreakpointPanel<XBreakpoint>>();
for (XBreakpointType<? extends XBreakpoint<?>, ?> type : types) {
XBreakpointsPanel<?> panel = createBreakpointsPanel(project, parentDialog, type);
panels.add(panel);
if (type.shouldShowInBreakpointsDialog(project)) {
XBreakpointsPanel<?> panel = createBreakpointsPanel(project, parentDialog, type);
panels.add(panel);
}
}
return panels;
}