OLD | NEW |
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 989 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1000 } | 1000 } |
1001 | 1001 |
1002 /** | 1002 /** |
1003 * @constructor | 1003 * @constructor |
1004 * @param {!WebInspector.BreakpointManager} breakpointManager | 1004 * @param {!WebInspector.BreakpointManager} breakpointManager |
1005 * @param {?WebInspector.Setting} setting | 1005 * @param {?WebInspector.Setting} setting |
1006 */ | 1006 */ |
1007 WebInspector.BreakpointManager.Storage = function(breakpointManager, setting) | 1007 WebInspector.BreakpointManager.Storage = function(breakpointManager, setting) |
1008 { | 1008 { |
1009 this._breakpointManager = breakpointManager; | 1009 this._breakpointManager = breakpointManager; |
1010 this._setting = setting || WebInspector.settings.createSetting("breakpoints"
, []); | 1010 this._setting = setting || WebInspector.settings.createLocalSetting("breakpo
ints", []); |
1011 var breakpoints = this._setting.get(); | 1011 var breakpoints = this._setting.get(); |
1012 /** @type {!Object.<string, !WebInspector.BreakpointManager.Storage.Item>} *
/ | 1012 /** @type {!Object.<string, !WebInspector.BreakpointManager.Storage.Item>} *
/ |
1013 this._breakpoints = {}; | 1013 this._breakpoints = {}; |
1014 for (var i = 0; i < breakpoints.length; ++i) { | 1014 for (var i = 0; i < breakpoints.length; ++i) { |
1015 var breakpoint = /** @type {!WebInspector.BreakpointManager.Storage.Item
} */ (breakpoints[i]); | 1015 var breakpoint = /** @type {!WebInspector.BreakpointManager.Storage.Item
} */ (breakpoints[i]); |
1016 breakpoint.columnNumber = breakpoint.columnNumber || 0; | 1016 breakpoint.columnNumber = breakpoint.columnNumber || 0; |
1017 this._breakpoints[breakpoint.sourceFileId + ":" + breakpoint.lineNumber
+ ":" + breakpoint.columnNumber] = breakpoint; | 1017 this._breakpoints[breakpoint.sourceFileId + ":" + breakpoint.lineNumber
+ ":" + breakpoint.columnNumber] = breakpoint; |
1018 } | 1018 } |
1019 } | 1019 } |
1020 | 1020 |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1083 { | 1083 { |
1084 this.sourceFileId = breakpoint._sourceFileId; | 1084 this.sourceFileId = breakpoint._sourceFileId; |
1085 this.lineNumber = breakpoint.lineNumber(); | 1085 this.lineNumber = breakpoint.lineNumber(); |
1086 this.columnNumber = breakpoint.columnNumber(); | 1086 this.columnNumber = breakpoint.columnNumber(); |
1087 this.condition = breakpoint.condition(); | 1087 this.condition = breakpoint.condition(); |
1088 this.enabled = breakpoint.enabled(); | 1088 this.enabled = breakpoint.enabled(); |
1089 } | 1089 } |
1090 | 1090 |
1091 /** @type {!WebInspector.BreakpointManager} */ | 1091 /** @type {!WebInspector.BreakpointManager} */ |
1092 WebInspector.breakpointManager; | 1092 WebInspector.breakpointManager; |
OLD | NEW |