提交 c290bb4e 编写于 作者: I isidor

debug: make sure to not accidently turn old breakpoints into column breakpoints

上级 fe0be9da
......@@ -624,7 +624,8 @@ export class Breakpoint implements debug.IBreakpoint {
public column: number,
public enabled: boolean,
public condition: string,
public hitCondition: string
public hitCondition: string,
public respectColumn: boolean // TODO@Isidor remove this in March
) {
if (enabled === undefined) {
this.enabled = true;
......@@ -777,7 +778,7 @@ export class Model implements debug.IModel {
public addBreakpoints(uri: uri, rawData: debug.IRawBreakpoint[]): void {
this.breakpoints = this.breakpoints.concat(rawData.map(rawBp =>
new Breakpoint(uri, rawBp.lineNumber, rawBp.column, rawBp.enabled, rawBp.condition, rawBp.hitCondition)));
new Breakpoint(uri, rawBp.lineNumber, rawBp.column, rawBp.enabled, rawBp.condition, rawBp.hitCondition, true)));
this.breakpointsActivated = true;
this._onDidChangeBreakpoints.fire();
}
......
......@@ -390,7 +390,7 @@ export class DebugService implements debug.IDebugService {
let result: Breakpoint[];
try {
result = JSON.parse(this.storageService.get(DEBUG_BREAKPOINTS_KEY, StorageScope.WORKSPACE, '[]')).map((breakpoint: any) => {
return new Breakpoint(uri.parse(breakpoint.uri.external || breakpoint.source.uri.external), breakpoint.lineNumber, breakpoint.column, breakpoint.enabled, breakpoint.condition, breakpoint.hitCondition);
return new Breakpoint(uri.parse(breakpoint.uri.external || breakpoint.source.uri.external), breakpoint.lineNumber, breakpoint.respectColumn ? breakpoint.column : undefined, breakpoint.enabled, breakpoint.condition, breakpoint.hitCondition, breakpoint.respectColumn);
});
} catch (e) { }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册