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

Side by Side Diff: Source/devtools/front_end/sdk/DebuggerModel.js

Issue 350153004: DevTools: Activate breakpoints in breakpointManager (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 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 29 matching lines...) Expand all
40 target.registerDebuggerDispatcher(new WebInspector.DebuggerDispatcher(this)) ; 40 target.registerDebuggerDispatcher(new WebInspector.DebuggerDispatcher(this)) ;
41 this._agent = target.debuggerAgent(); 41 this._agent = target.debuggerAgent();
42 42
43 /** @type {?WebInspector.DebuggerPausedDetails} */ 43 /** @type {?WebInspector.DebuggerPausedDetails} */
44 this._debuggerPausedDetails = null; 44 this._debuggerPausedDetails = null;
45 /** @type {!Object.<string, !WebInspector.Script>} */ 45 /** @type {!Object.<string, !WebInspector.Script>} */
46 this._scripts = {}; 46 this._scripts = {};
47 /** @type {!StringMap.<!Array.<!WebInspector.Script>>} */ 47 /** @type {!StringMap.<!Array.<!WebInspector.Script>>} */
48 this._scriptsBySourceURL = new StringMap(); 48 this._scriptsBySourceURL = new StringMap();
49 49
50 this._breakpointsActive = true;
51 /** @type {!WebInspector.Object} */ 50 /** @type {!WebInspector.Object} */
52 this._breakpointResolvedEventTarget = new WebInspector.Object(); 51 this._breakpointResolvedEventTarget = new WebInspector.Object();
53 52
54 this._isPausing = false; 53 this._isPausing = false;
55 WebInspector.settings.pauseOnExceptionEnabled.addChangeListener(this._pauseO nExceptionStateChanged, this); 54 WebInspector.settings.pauseOnExceptionEnabled.addChangeListener(this._pauseO nExceptionStateChanged, this);
56 WebInspector.settings.pauseOnCaughtException.addChangeListener(this._pauseOn ExceptionStateChanged, this); 55 WebInspector.settings.pauseOnCaughtException.addChangeListener(this._pauseOn ExceptionStateChanged, this);
57 56
58 WebInspector.settings.enableAsyncStackTraces.addChangeListener(this._asyncSt ackTracesStateChanged, this); 57 WebInspector.settings.enableAsyncStackTraces.addChangeListener(this._asyncSt ackTracesStateChanged, this);
59 target.profilingLock.addEventListener(WebInspector.Lock.Events.StateChanged, this._profilingStateChanged, this); 58 target.profilingLock.addEventListener(WebInspector.Lock.Events.StateChanged, this._profilingStateChanged, this);
60 59
(...skipping 18 matching lines...) Expand all
79 WebInspector.DebuggerModel.Events = { 78 WebInspector.DebuggerModel.Events = {
80 DebuggerWasEnabled: "DebuggerWasEnabled", 79 DebuggerWasEnabled: "DebuggerWasEnabled",
81 DebuggerWasDisabled: "DebuggerWasDisabled", 80 DebuggerWasDisabled: "DebuggerWasDisabled",
82 DebuggerPaused: "DebuggerPaused", 81 DebuggerPaused: "DebuggerPaused",
83 DebuggerResumed: "DebuggerResumed", 82 DebuggerResumed: "DebuggerResumed",
84 ParsedScriptSource: "ParsedScriptSource", 83 ParsedScriptSource: "ParsedScriptSource",
85 FailedToParseScriptSource: "FailedToParseScriptSource", 84 FailedToParseScriptSource: "FailedToParseScriptSource",
86 GlobalObjectCleared: "GlobalObjectCleared", 85 GlobalObjectCleared: "GlobalObjectCleared",
87 CallFrameSelected: "CallFrameSelected", 86 CallFrameSelected: "CallFrameSelected",
88 ConsoleCommandEvaluatedInSelectedCallFrame: "ConsoleCommandEvaluatedInSelect edCallFrame", 87 ConsoleCommandEvaluatedInSelectedCallFrame: "ConsoleCommandEvaluatedInSelect edCallFrame",
89 BreakpointsActiveStateChanged: "BreakpointsActiveStateChanged"
90 } 88 }
91 89
92 WebInspector.DebuggerModel.BreakReason = { 90 WebInspector.DebuggerModel.BreakReason = {
93 DOM: "DOM", 91 DOM: "DOM",
94 EventListener: "EventListener", 92 EventListener: "EventListener",
95 XHR: "XHR", 93 XHR: "XHR",
96 Exception: "exception", 94 Exception: "exception",
97 Assert: "assert", 95 Assert: "assert",
98 CSPViolation: "CSPViolation", 96 CSPViolation: "CSPViolation",
99 DebugCommand: "debugCommand" 97 DebugCommand: "debugCommand"
(...skipping 541 matching lines...) Expand 10 before | Expand all | Expand 10 after
641 639
642 for (var i = 0; i < selectedCallFrame.scopeChain.length; ++i) { 640 for (var i = 0; i < selectedCallFrame.scopeChain.length; ++i) {
643 var scope = selectedCallFrame.scopeChain[i]; 641 var scope = selectedCallFrame.scopeChain[i];
644 var object = this.target().runtimeModel.createRemoteObject(scope.obj ect); 642 var object = this.target().runtimeModel.createRemoteObject(scope.obj ect);
645 pendingRequests++; 643 pendingRequests++;
646 object.getAllProperties(false, propertiesCollected); 644 object.getAllProperties(false, propertiesCollected);
647 } 645 }
648 }, 646 },
649 647
650 /** 648 /**
651 * @param {boolean} active
652 */
653 setBreakpointsActive: function(active)
654 {
655 if (this._breakpointsActive === active)
656 return;
657 this._breakpointsActive = active;
658 this._agent.setBreakpointsActive(active);
659 this.dispatchEventToListeners(WebInspector.DebuggerModel.Events.Breakpoi ntsActiveStateChanged, active);
660 },
661
662 /**
663 * @return {boolean}
664 */
665 breakpointsActive: function()
666 {
667 return this._breakpointsActive;
668 },
669
670 /**
671 * @param {!WebInspector.DebuggerModel.Location} rawLocation 649 * @param {!WebInspector.DebuggerModel.Location} rawLocation
672 * @param {function(!WebInspector.UILocation):(boolean|undefined)} updateDel egate 650 * @param {function(!WebInspector.UILocation):(boolean|undefined)} updateDel egate
673 * @return {!WebInspector.Script.Location} 651 * @return {!WebInspector.Script.Location}
674 */ 652 */
675 createLiveLocation: function(rawLocation, updateDelegate) 653 createLiveLocation: function(rawLocation, updateDelegate)
676 { 654 {
677 var script = this._scripts[rawLocation.scriptId]; 655 var script = this._scripts[rawLocation.scriptId];
678 return script.createLiveLocation(rawLocation, updateDelegate); 656 return script.createLiveLocation(rawLocation, updateDelegate);
679 }, 657 },
680 658
(...skipping 501 matching lines...) Expand 10 before | Expand all | Expand 10 after
1182 this.asyncStackTrace.dispose(); 1160 this.asyncStackTrace.dispose();
1183 }, 1161 },
1184 1162
1185 __proto__: WebInspector.TargetAware.prototype 1163 __proto__: WebInspector.TargetAware.prototype
1186 } 1164 }
1187 1165
1188 /** 1166 /**
1189 * @type {!WebInspector.DebuggerModel} 1167 * @type {!WebInspector.DebuggerModel}
1190 */ 1168 */
1191 WebInspector.debuggerModel; 1169 WebInspector.debuggerModel;
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698