OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. |
3 * Copyright (C) 2011 Google Inc. All rights reserved. | 3 * Copyright (C) 2011 Google Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 627 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
638 } | 638 } |
639 | 639 |
640 /** | 640 /** |
641 * @param {!Workspace.UILocation} uiLocation | 641 * @param {!Workspace.UILocation} uiLocation |
642 */ | 642 */ |
643 _continueToLocation(uiLocation) { | 643 _continueToLocation(uiLocation) { |
644 var executionContext = UI.context.flavor(SDK.ExecutionContext); | 644 var executionContext = UI.context.flavor(SDK.ExecutionContext); |
645 if (!executionContext) | 645 if (!executionContext) |
646 return; | 646 return; |
647 // Always use 0 column. | 647 // Always use 0 column. |
648 var rawLocations = | 648 var rawLocation = |
649 Bindings.debuggerWorkspaceBinding.uiLocationToRawLocations(uiLocation.ui
SourceCode, uiLocation.lineNumber, 0); | 649 Bindings.debuggerWorkspaceBinding.uiLocationToRawLocation(uiLocation.uiS
ourceCode, uiLocation.lineNumber, 0); |
650 // TODO(kozyatinskiy): make it possible to continue to multiple locations (w
hichever is hit first). | 650 if (!rawLocation || rawLocation.debuggerModel !== executionContext.debuggerM
odel) |
651 var location = rawLocations.find(location => location.debuggerModel === exec
utionContext.debuggerModel); | |
652 if (!location) | |
653 return; | 651 return; |
654 if (!this._prepareToResume()) | 652 if (!this._prepareToResume()) |
655 return; | 653 return; |
656 | 654 |
657 location.continueToLocation(); | 655 rawLocation.continueToLocation(); |
658 } | 656 } |
659 | 657 |
660 _toggleBreakpointsActive() { | 658 _toggleBreakpointsActive() { |
661 Bindings.breakpointManager.setBreakpointsActive(!Bindings.breakpointManager.
breakpointsActive()); | 659 Bindings.breakpointManager.setBreakpointsActive(!Bindings.breakpointManager.
breakpointsActive()); |
662 } | 660 } |
663 | 661 |
664 _breakpointsActiveStateChanged(event) { | 662 _breakpointsActiveStateChanged(event) { |
665 var active = event.data; | 663 var active = event.data; |
666 this._toggleBreakpointsActiveAction.setToggled(!active); | 664 this._toggleBreakpointsActiveAction.setToggled(!active); |
667 this._sourcesView.toggleBreakpointsActiveState(active); | 665 this._sourcesView.toggleBreakpointsActiveState(active); |
(...skipping 629 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1297 */ | 1295 */ |
1298 willHide() { | 1296 willHide() { |
1299 UI.inspectorView.setDrawerMinimized(false); | 1297 UI.inspectorView.setDrawerMinimized(false); |
1300 setImmediate(() => Sources.SourcesPanel.updateResizerAndSidebarButtons(Sourc
es.SourcesPanel.instance())); | 1298 setImmediate(() => Sources.SourcesPanel.updateResizerAndSidebarButtons(Sourc
es.SourcesPanel.instance())); |
1301 } | 1299 } |
1302 | 1300 |
1303 _showViewInWrapper() { | 1301 _showViewInWrapper() { |
1304 this._view.show(this.element); | 1302 this._view.show(this.element); |
1305 } | 1303 } |
1306 }; | 1304 }; |
OLD | NEW |