| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 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 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 if (this._divergedInfobar) | 107 if (this._divergedInfobar) |
| 108 this._divergedInfobar.dispose(); | 108 this._divergedInfobar.dispose(); |
| 109 | 109 |
| 110 var infobar = new WebInspector.Infobar(WebInspector.Infobar.Type.Warning
, WebInspector.UIString("Workspace mapping mismatch")); | 110 var infobar = new WebInspector.Infobar(WebInspector.Infobar.Type.Warning
, WebInspector.UIString("Workspace mapping mismatch")); |
| 111 this._divergedInfobar = infobar; | 111 this._divergedInfobar = infobar; |
| 112 | 112 |
| 113 var fileURL = this.uiSourceCode().url(); | 113 var fileURL = this.uiSourceCode().url(); |
| 114 infobar.createDetailsRowMessage(WebInspector.UIString("The content of th
is file on the file system:\u00a0")).appendChild( | 114 infobar.createDetailsRowMessage(WebInspector.UIString("The content of th
is file on the file system:\u00a0")).appendChild( |
| 115 WebInspector.linkifyURLAsNode(fileURL, fileURL, "source-frame-infoba
r-details-url", true)); | 115 WebInspector.linkifyURLAsNode(fileURL, fileURL, "source-frame-infoba
r-details-url", true)); |
| 116 | 116 |
| 117 var scriptURL = WebInspector.networkMapping.networkURL(this.uiSourceCode
()); | 117 var scriptURL = this.uiSourceCode().url(); |
| 118 infobar.createDetailsRowMessage(WebInspector.UIString("does not match th
e loaded script:\u00a0")).appendChild( | 118 infobar.createDetailsRowMessage(WebInspector.UIString("does not match th
e loaded script:\u00a0")).appendChild( |
| 119 WebInspector.linkifyURLAsNode(scriptURL, scriptURL, "source-frame-in
fobar-details-url", true)); | 119 WebInspector.linkifyURLAsNode(scriptURL, scriptURL, "source-frame-in
fobar-details-url", true)); |
| 120 | 120 |
| 121 infobar.createDetailsRowMessage(); | 121 infobar.createDetailsRowMessage(); |
| 122 infobar.createDetailsRowMessage(WebInspector.UIString("Possible solution
s are:")); | 122 infobar.createDetailsRowMessage(WebInspector.UIString("Possible solution
s are:")); |
| 123 | 123 |
| 124 if (WebInspector.moduleSetting("cacheDisabled").get()) | 124 if (WebInspector.moduleSetting("cacheDisabled").get()) |
| 125 infobar.createDetailsRowMessage(" - ").createTextChild(WebInspector.
UIString("Reload inspected page")); | 125 infobar.createDetailsRowMessage(" - ").createTextChild(WebInspector.
UIString("Reload inspected page")); |
| 126 else | 126 else |
| 127 infobar.createDetailsRowMessage(" - ").createTextChild(WebInspector.
UIString("Check \"Disable cache\" in settings and reload inspected page (recomme
nded setup for authoring and debugging)")); | 127 infobar.createDetailsRowMessage(" - ").createTextChild(WebInspector.
UIString("Check \"Disable cache\" in settings and reload inspected page (recomme
nded setup for authoring and debugging)")); |
| (...skipping 11 matching lines...) Expand all Loading... |
| 139 }, | 139 }, |
| 140 | 140 |
| 141 _showBlackboxInfobarIfNeeded: function() | 141 _showBlackboxInfobarIfNeeded: function() |
| 142 { | 142 { |
| 143 var uiSourceCode = this.uiSourceCode(); | 143 var uiSourceCode = this.uiSourceCode(); |
| 144 if (!uiSourceCode.contentType().hasScripts()) | 144 if (!uiSourceCode.contentType().hasScripts()) |
| 145 return; | 145 return; |
| 146 var projectType = uiSourceCode.project().type(); | 146 var projectType = uiSourceCode.project().type(); |
| 147 if (projectType === WebInspector.projectTypes.Snippets) | 147 if (projectType === WebInspector.projectTypes.Snippets) |
| 148 return; | 148 return; |
| 149 var networkURL = WebInspector.networkMapping.networkURL(uiSourceCode); | |
| 150 var url = projectType === WebInspector.projectTypes.Formatter ? uiSource
Code.url() : networkURL; | |
| 151 if (!WebInspector.blackboxManager.isBlackboxedUISourceCode(uiSourceCode)
) { | 149 if (!WebInspector.blackboxManager.isBlackboxedUISourceCode(uiSourceCode)
) { |
| 152 this._hideBlackboxInfobar(); | 150 this._hideBlackboxInfobar(); |
| 153 return; | 151 return; |
| 154 } | 152 } |
| 155 | 153 |
| 156 if (this._blackboxInfobar) | 154 if (this._blackboxInfobar) |
| 157 this._blackboxInfobar.dispose(); | 155 this._blackboxInfobar.dispose(); |
| 158 | 156 |
| 159 var infobar = new WebInspector.Infobar(WebInspector.Infobar.Type.Warning
, WebInspector.UIString("This script is blackboxed in debugger")); | 157 var infobar = new WebInspector.Infobar(WebInspector.Infobar.Type.Warning
, WebInspector.UIString("This script is blackboxed in debugger")); |
| 160 this._blackboxInfobar = infobar; | 158 this._blackboxInfobar = infobar; |
| (...skipping 908 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1069 this.uiSourceCode().removeEventListener(WebInspector.UISourceCode.Events
.WorkingCopyChanged, this._workingCopyChanged, this); | 1067 this.uiSourceCode().removeEventListener(WebInspector.UISourceCode.Events
.WorkingCopyChanged, this._workingCopyChanged, this); |
| 1070 this.uiSourceCode().removeEventListener(WebInspector.UISourceCode.Events
.WorkingCopyCommitted, this._workingCopyCommitted, this); | 1068 this.uiSourceCode().removeEventListener(WebInspector.UISourceCode.Events
.WorkingCopyCommitted, this._workingCopyCommitted, this); |
| 1071 this.uiSourceCode().removeEventListener(WebInspector.UISourceCode.Events
.TitleChanged, this._showBlackboxInfobarIfNeeded, this); | 1069 this.uiSourceCode().removeEventListener(WebInspector.UISourceCode.Events
.TitleChanged, this._showBlackboxInfobarIfNeeded, this); |
| 1072 WebInspector.moduleSetting("skipStackFramesPattern").removeChangeListene
r(this._showBlackboxInfobarIfNeeded, this); | 1070 WebInspector.moduleSetting("skipStackFramesPattern").removeChangeListene
r(this._showBlackboxInfobarIfNeeded, this); |
| 1073 WebInspector.moduleSetting("skipContentScripts").removeChangeListener(th
is._showBlackboxInfobarIfNeeded, this); | 1071 WebInspector.moduleSetting("skipContentScripts").removeChangeListener(th
is._showBlackboxInfobarIfNeeded, this); |
| 1074 WebInspector.UISourceCodeFrame.prototype.dispose.call(this); | 1072 WebInspector.UISourceCodeFrame.prototype.dispose.call(this); |
| 1075 }, | 1073 }, |
| 1076 | 1074 |
| 1077 __proto__: WebInspector.UISourceCodeFrame.prototype | 1075 __proto__: WebInspector.UISourceCodeFrame.prototype |
| 1078 } | 1076 } |
| OLD | NEW |