| OLD | NEW |
| 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 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 66 } | 66 } |
| 67 | 67 |
| 68 WebInspector.NetworkItemView.prototype = { | 68 WebInspector.NetworkItemView.prototype = { |
| 69 wasShown: function() | 69 wasShown: function() |
| 70 { | 70 { |
| 71 WebInspector.TabbedPane.prototype.wasShown.call(this); | 71 WebInspector.TabbedPane.prototype.wasShown.call(this); |
| 72 this._selectTab(); | 72 this._selectTab(); |
| 73 }, | 73 }, |
| 74 | 74 |
| 75 /** | 75 /** |
| 76 * @return {?WebInspector.SourceFrame} |
| 77 */ |
| 78 currentSourceFrame: function() |
| 79 { |
| 80 var view = this.visibleView; |
| 81 if (view && view instanceof WebInspector.SourceFrame) |
| 82 return /** @type {!WebInspector.SourceFrame} */ (view); |
| 83 return null; |
| 84 }, |
| 85 |
| 86 /** |
| 76 * @param {string=} tabId | 87 * @param {string=} tabId |
| 77 */ | 88 */ |
| 78 _selectTab: function(tabId) | 89 _selectTab: function(tabId) |
| 79 { | 90 { |
| 80 if (!tabId) | 91 if (!tabId) |
| 81 tabId = WebInspector.settings.resourceViewTab.get(); | 92 tabId = WebInspector.settings.resourceViewTab.get(); |
| 82 | 93 |
| 83 if (!this.selectTab(tabId)) { | 94 if (!this.selectTab(tabId)) { |
| 84 this._isInFallbackSelection = true; | 95 this._isInFallbackSelection = true; |
| 85 this.selectTab("headers"); | 96 this.selectTab("headers"); |
| (...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 166 } | 177 } |
| 167 | 178 |
| 168 this.request.requestContent(callback.bind(this)); | 179 this.request.requestContent(callback.bind(this)); |
| 169 }, | 180 }, |
| 170 | 181 |
| 171 contentLoaded: function() | 182 contentLoaded: function() |
| 172 { | 183 { |
| 173 // Should be implemented by subclasses. | 184 // Should be implemented by subclasses. |
| 174 }, | 185 }, |
| 175 | 186 |
| 176 /** | |
| 177 * @override | |
| 178 * @return {boolean} | |
| 179 */ | |
| 180 canHighlightPosition: function() | |
| 181 { | |
| 182 return this._innerView && this._innerView.canHighlightPosition(); | |
| 183 }, | |
| 184 | |
| 185 /** | |
| 186 * @override | |
| 187 */ | |
| 188 highlightPosition: function(line, column) | |
| 189 { | |
| 190 if (this.canHighlightPosition()) | |
| 191 this._innerView.highlightPosition(line, column); | |
| 192 }, | |
| 193 | |
| 194 __proto__: WebInspector.RequestView.prototype | 187 __proto__: WebInspector.RequestView.prototype |
| 195 } | 188 } |
| OLD | NEW |