| 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 721 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 732 | 732 |
| 733 /** | 733 /** |
| 734 * @override | 734 * @override |
| 735 * @param {!Event} event | 735 * @param {!Event} event |
| 736 * @param {!WebInspector.ContextMenu} contextMenu | 736 * @param {!WebInspector.ContextMenu} contextMenu |
| 737 * @param {!Object} target | 737 * @param {!Object} target |
| 738 */ | 738 */ |
| 739 appendApplicableItems: function(event, contextMenu, target) | 739 appendApplicableItems: function(event, contextMenu, target) |
| 740 { | 740 { |
| 741 this._appendUISourceCodeItems(event, contextMenu, target); | 741 this._appendUISourceCodeItems(event, contextMenu, target); |
| 742 this._appendUISourceCodeFrameItems(event, contextMenu, target); |
| 742 this.appendUILocationItems(contextMenu, target); | 743 this.appendUILocationItems(contextMenu, target); |
| 743 this._appendRemoteObjectItems(contextMenu, target); | 744 this._appendRemoteObjectItems(contextMenu, target); |
| 744 this._appendNetworkRequestItems(contextMenu, target); | 745 this._appendNetworkRequestItems(contextMenu, target); |
| 745 contextMenu.appendAction("debugger.evaluate-selection"); | |
| 746 }, | 746 }, |
| 747 | 747 |
| 748 /** | 748 /** |
| 749 * @param {!WebInspector.UISourceCode} uiSourceCode | 749 * @param {!WebInspector.UISourceCode} uiSourceCode |
| 750 */ | 750 */ |
| 751 mapFileSystemToNetwork: function(uiSourceCode) | 751 mapFileSystemToNetwork: function(uiSourceCode) |
| 752 { | 752 { |
| 753 WebInspector.SelectUISourceCodeForProjectTypesDialog.show(uiSourceCode.n
ame(), [WebInspector.projectTypes.Network, WebInspector.projectTypes.ContentScri
pts], mapFileSystemToNetwork.bind(this)); | 753 WebInspector.SelectUISourceCodeForProjectTypesDialog.show(uiSourceCode.n
ame(), [WebInspector.projectTypes.Network, WebInspector.projectTypes.ContentScri
pts], mapFileSystemToNetwork.bind(this)); |
| 754 | 754 |
| 755 /** | 755 /** |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 838 if (projectType !== WebInspector.projectTypes.Debugger && !event.target.
isSelfOrDescendant(this._navigatorTabbedLocation.widget().element)) { | 838 if (projectType !== WebInspector.projectTypes.Debugger && !event.target.
isSelfOrDescendant(this._navigatorTabbedLocation.widget().element)) { |
| 839 contextMenu.appendItem(WebInspector.UIString.capitalize("Reveal in ^
navigator"), this._handleContextMenuReveal.bind(this, uiSourceCode)); | 839 contextMenu.appendItem(WebInspector.UIString.capitalize("Reveal in ^
navigator"), this._handleContextMenuReveal.bind(this, uiSourceCode)); |
| 840 contextMenu.appendSeparator(); | 840 contextMenu.appendSeparator(); |
| 841 } | 841 } |
| 842 this._appendUISourceCodeMappingItems(contextMenu, uiSourceCode); | 842 this._appendUISourceCodeMappingItems(contextMenu, uiSourceCode); |
| 843 if (projectType !== WebInspector.projectTypes.FileSystem) | 843 if (projectType !== WebInspector.projectTypes.FileSystem) |
| 844 contextMenu.appendItem(WebInspector.UIString.capitalize("Local ^modi
fications\u2026"), this._showLocalHistory.bind(this, uiSourceCode)); | 844 contextMenu.appendItem(WebInspector.UIString.capitalize("Local ^modi
fications\u2026"), this._showLocalHistory.bind(this, uiSourceCode)); |
| 845 }, | 845 }, |
| 846 | 846 |
| 847 /** | 847 /** |
| 848 * @param {!Event} event |
| 849 * @param {!WebInspector.ContextMenu} contextMenu |
| 850 * @param {!Object} target |
| 851 */ |
| 852 _appendUISourceCodeFrameItems: function(event, contextMenu, target) |
| 853 { |
| 854 if (!(target instanceof WebInspector.UISourceCodeFrame)) |
| 855 return; |
| 856 contextMenu.appendAction("debugger.evaluate-selection"); |
| 857 }, |
| 858 |
| 859 /** |
| 848 * @param {!WebInspector.ContextMenu} contextMenu | 860 * @param {!WebInspector.ContextMenu} contextMenu |
| 849 * @param {!Object} object | 861 * @param {!Object} object |
| 850 */ | 862 */ |
| 851 appendUILocationItems: function(contextMenu, object) | 863 appendUILocationItems: function(contextMenu, object) |
| 852 { | 864 { |
| 853 if (!(object instanceof WebInspector.UILocation)) | 865 if (!(object instanceof WebInspector.UILocation)) |
| 854 return; | 866 return; |
| 855 var uiLocation = /** @type {!WebInspector.UILocation} */ (object); | 867 var uiLocation = /** @type {!WebInspector.UILocation} */ (object); |
| 856 var uiSourceCode = uiLocation.uiSourceCode; | 868 var uiSourceCode = uiLocation.uiSourceCode; |
| 857 var projectType = uiSourceCode.project().type(); | 869 var projectType = uiSourceCode.project().type(); |
| (...skipping 512 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1370 __proto__: WebInspector.VBox.prototype | 1382 __proto__: WebInspector.VBox.prototype |
| 1371 } | 1383 } |
| 1372 | 1384 |
| 1373 /** | 1385 /** |
| 1374 * @return {boolean} | 1386 * @return {boolean} |
| 1375 */ | 1387 */ |
| 1376 WebInspector.SourcesPanel.WrapperView.isShowing = function() | 1388 WebInspector.SourcesPanel.WrapperView.isShowing = function() |
| 1377 { | 1389 { |
| 1378 return !!WebInspector.SourcesPanel.WrapperView._instance && WebInspector.Sou
rcesPanel.WrapperView._instance.isShowing(); | 1390 return !!WebInspector.SourcesPanel.WrapperView._instance && WebInspector.Sou
rcesPanel.WrapperView._instance.isShowing(); |
| 1379 } | 1391 } |
| OLD | NEW |