Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(824)

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/bindings/BreakpointManager.js

Issue 2898473002: [DevTools] breakpoint manager should be ready for location from different model (Closed)
Patch Set: Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 792 matching lines...) Expand 10 before | Expand all | Expand 10 after
803 return; 803 return;
804 } 804 }
805 805
806 var uiSourceCode = this._breakpoint.uiSourceCode(); 806 var uiSourceCode = this._breakpoint.uiSourceCode();
807 var lineNumber = this._breakpoint._lineNumber; 807 var lineNumber = this._breakpoint._lineNumber;
808 var columnNumber = this._breakpoint._columnNumber; 808 var columnNumber = this._breakpoint._columnNumber;
809 var condition = this._breakpoint.condition(); 809 var condition = this._breakpoint.condition();
810 810
811 var debuggerLocation = uiSourceCode && 811 var debuggerLocation = uiSourceCode &&
812 Bindings.debuggerWorkspaceBinding.uiLocationToRawLocation(uiSourceCode, lineNumber, columnNumber); 812 Bindings.debuggerWorkspaceBinding.uiLocationToRawLocation(uiSourceCode, lineNumber, columnNumber);
813 if (debuggerLocation && debuggerLocation.debuggerModel !== this._debuggerMod el)
814 debuggerLocation = null;
813 var newState; 815 var newState;
814 if (this._breakpoint._isRemoved || !this._breakpoint.enabled() || this._scri ptDiverged()) { 816 if (this._breakpoint._isRemoved || !this._breakpoint.enabled() || this._scri ptDiverged()) {
815 newState = null; 817 newState = null;
816 } else if (debuggerLocation) { 818 } else if (debuggerLocation) {
817 var script = debuggerLocation.script(); 819 var script = debuggerLocation.script();
818 if (script.sourceURL) { 820 if (script.sourceURL) {
819 newState = new Bindings.BreakpointManager.Breakpoint.State( 821 newState = new Bindings.BreakpointManager.Breakpoint.State(
820 script.sourceURL, null, debuggerLocation.lineNumber, debuggerLocatio n.columnNumber, condition); 822 script.sourceURL, null, debuggerLocation.lineNumber, debuggerLocatio n.columnNumber, condition);
821 } else { 823 } else {
822 newState = new Bindings.BreakpointManager.Breakpoint.State( 824 newState = new Bindings.BreakpointManager.Breakpoint.State(
(...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after
1080 this.url = breakpoint._url; 1082 this.url = breakpoint._url;
1081 this.lineNumber = breakpoint.lineNumber(); 1083 this.lineNumber = breakpoint.lineNumber();
1082 this.columnNumber = breakpoint.columnNumber(); 1084 this.columnNumber = breakpoint.columnNumber();
1083 this.condition = breakpoint.condition(); 1085 this.condition = breakpoint.condition();
1084 this.enabled = breakpoint.enabled(); 1086 this.enabled = breakpoint.enabled();
1085 } 1087 }
1086 }; 1088 };
1087 1089
1088 /** @type {!Bindings.BreakpointManager} */ 1090 /** @type {!Bindings.BreakpointManager} */
1089 Bindings.breakpointManager; 1091 Bindings.breakpointManager;
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/inspector/sources/debugger-breakpoints/breakpoints-in-anonymous-script-with-two-targets-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698