| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com> | 3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com> |
| 4 * Copyright (C) 2009 Joseph Pecoraro | 4 * Copyright (C) 2009 Joseph Pecoraro |
| 5 * | 5 * |
| 6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
| 7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
| 8 * are met: | 8 * are met: |
| 9 * | 9 * |
| 10 * 1. Redistributions of source code must retain the above copyright | 10 * 1. Redistributions of source code must retain the above copyright |
| (...skipping 367 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 378 if (!selectedNode && this._lastValidSelectedNode) | 378 if (!selectedNode && this._lastValidSelectedNode) |
| 379 this._selectedPathOnReset = this._lastValidSelectedNode.path(); | 379 this._selectedPathOnReset = this._lastValidSelectedNode.path(); |
| 380 | 380 |
| 381 this._breadcrumbs.setSelectedNode(selectedNode); | 381 this._breadcrumbs.setSelectedNode(selectedNode); |
| 382 | 382 |
| 383 WebInspector.context.setFlavor(WebInspector.DOMNode, selectedNode); | 383 WebInspector.context.setFlavor(WebInspector.DOMNode, selectedNode); |
| 384 | 384 |
| 385 if (selectedNode) { | 385 if (selectedNode) { |
| 386 selectedNode.setAsInspectedNode(); | 386 selectedNode.setAsInspectedNode(); |
| 387 this._lastValidSelectedNode = selectedNode; | 387 this._lastValidSelectedNode = selectedNode; |
| 388 |
| 389 var executionContexts = selectedNode.target().runtimeModel.execution
Contexts(); |
| 390 var nodeFrameId = selectedNode.frameId(); |
| 391 for (var context of executionContexts) { |
| 392 if (context.frameId == nodeFrameId) { |
| 393 WebInspector.context.setFlavor(WebInspector.ExecutionContext
, context); |
| 394 break; |
| 395 } |
| 396 } |
| 388 } | 397 } |
| 389 WebInspector.notifications.dispatchEventToListeners(WebInspector.Notific
ationService.Events.SelectedNodeChanged); | 398 WebInspector.notifications.dispatchEventToListeners(WebInspector.Notific
ationService.Events.SelectedNodeChanged); |
| 390 this._selectedNodeChangedForTest(); | 399 this._selectedNodeChangedForTest(); |
| 391 }, | 400 }, |
| 392 | 401 |
| 393 _selectedNodeChangedForTest: function() { }, | 402 _selectedNodeChangedForTest: function() { }, |
| 394 | 403 |
| 395 _reset: function() | 404 _reset: function() |
| 396 { | 405 { |
| 397 delete this.currentQuery; | 406 delete this.currentQuery; |
| (...skipping 877 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1275 */ | 1284 */ |
| 1276 wasShown: function() | 1285 wasShown: function() |
| 1277 { | 1286 { |
| 1278 this._toolbarItem.setToggled(true); | 1287 this._toolbarItem.setToggled(true); |
| 1279 this._nodeChanged(); | 1288 this._nodeChanged(); |
| 1280 WebInspector.ThrottledWidget.prototype.wasShown.call(this); | 1289 WebInspector.ThrottledWidget.prototype.wasShown.call(this); |
| 1281 }, | 1290 }, |
| 1282 | 1291 |
| 1283 __proto__: WebInspector.ThrottledWidget.prototype | 1292 __proto__: WebInspector.ThrottledWidget.prototype |
| 1284 } | 1293 } |
| OLD | NEW |