| 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 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 93 */ | 93 */ |
| 94 syncToolbarItems() { | 94 syncToolbarItems() { |
| 95 var result = super.syncToolbarItems(); | 95 var result = super.syncToolbarItems(); |
| 96 var originURL = WebInspector.CompilerScriptMapping.uiSourceCodeOrigin(this.u
iSourceCode()); | 96 var originURL = WebInspector.CompilerScriptMapping.uiSourceCodeOrigin(this.u
iSourceCode()); |
| 97 if (originURL) { | 97 if (originURL) { |
| 98 var parsedURL = originURL.asParsedURL(); | 98 var parsedURL = originURL.asParsedURL(); |
| 99 if (parsedURL) | 99 if (parsedURL) |
| 100 result.push( | 100 result.push( |
| 101 new WebInspector.ToolbarText(WebInspector.UIString('(source mapped f
rom %s)', parsedURL.displayName))); | 101 new WebInspector.ToolbarText(WebInspector.UIString('(source mapped f
rom %s)', parsedURL.displayName))); |
| 102 } | 102 } |
| 103 |
| 104 if (this.uiSourceCode().project().type() === WebInspector.projectTypes.Snipp
ets) { |
| 105 result.push(new WebInspector.ToolbarSeparator(true)); |
| 106 var runSnippet = WebInspector.Toolbar.createActionButtonForId('debugger.ru
n-snippet'); |
| 107 runSnippet.setText(WebInspector.isMac() ? |
| 108 WebInspector.UIString('\u2318+Enter') : |
| 109 WebInspector.UIString('Ctrl+Enter')); |
| 110 result.push(runSnippet); |
| 111 } |
| 112 |
| 103 return result; | 113 return result; |
| 104 } | 114 } |
| 105 | 115 |
| 106 _updateInfobars() { | 116 _updateInfobars() { |
| 107 this.attachInfobars([this._blackboxInfobar, this._divergedInfobar]); | 117 this.attachInfobars([this._blackboxInfobar, this._divergedInfobar]); |
| 108 } | 118 } |
| 109 | 119 |
| 110 _showDivergedInfobar() { | 120 _showDivergedInfobar() { |
| 111 if (!this.uiSourceCode().contentType().isScript()) | 121 if (!this.uiSourceCode().contentType().isScript()) |
| 112 return; | 122 return; |
| (...skipping 948 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1061 WebInspector.UISourceCode.Events.WorkingCopyChanged, this._workingCopyCh
anged, this); | 1071 WebInspector.UISourceCode.Events.WorkingCopyChanged, this._workingCopyCh
anged, this); |
| 1062 this.uiSourceCode().removeEventListener( | 1072 this.uiSourceCode().removeEventListener( |
| 1063 WebInspector.UISourceCode.Events.WorkingCopyCommitted, this._workingCopy
Committed, this); | 1073 WebInspector.UISourceCode.Events.WorkingCopyCommitted, this._workingCopy
Committed, this); |
| 1064 this.uiSourceCode().removeEventListener( | 1074 this.uiSourceCode().removeEventListener( |
| 1065 WebInspector.UISourceCode.Events.TitleChanged, this._showBlackboxInfobar
IfNeeded, this); | 1075 WebInspector.UISourceCode.Events.TitleChanged, this._showBlackboxInfobar
IfNeeded, this); |
| 1066 WebInspector.moduleSetting('skipStackFramesPattern').removeChangeListener(th
is._showBlackboxInfobarIfNeeded, this); | 1076 WebInspector.moduleSetting('skipStackFramesPattern').removeChangeListener(th
is._showBlackboxInfobarIfNeeded, this); |
| 1067 WebInspector.moduleSetting('skipContentScripts').removeChangeListener(this._
showBlackboxInfobarIfNeeded, this); | 1077 WebInspector.moduleSetting('skipContentScripts').removeChangeListener(this._
showBlackboxInfobarIfNeeded, this); |
| 1068 super.dispose(); | 1078 super.dispose(); |
| 1069 } | 1079 } |
| 1070 }; | 1080 }; |
| OLD | NEW |