Changeset 251922 in webkit
- Timestamp:
- Nov 1, 2019 9:19:14 AM (5 years ago)
- Location:
- trunk/Source/WebInspectorUI
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebInspectorUI/ChangeLog
r251921 r251922 1 2019-11-01 Devin Rousso <drousso@apple.com> 2 3 Web Inspector: Sources: tab isn't visible after removal of Debugger Tab and Resources Tab 4 https://bugs.webkit.org/show_bug.cgi?id=203719 5 <rdar://problem/56802389> 6 7 Reviewed by Timothy Hatcher. 8 9 * UserInterface/Base/Main.js: 10 (WI.loaded): 11 If the Debugger Tab identifier or Resources Tab identifier still exists in the list of open 12 tabs, remove both and replace the first one with the Sources Tab identifier. 13 1 14 2019-11-01 Devin Rousso <drousso@apple.com> 2 15 -
trunk/Source/WebInspectorUI/UserInterface/Base/Main.js
r251494 r251922 152 152 WI._selectedTabIndexSetting = new WI.Setting("selected-tab-index", 0); 153 153 154 // Replace the Debugger/Resources Tab with the Sources Tab. 155 let debuggerIndex = WI._openTabsSetting.value.indexOf("debugger"); 156 let resourcesIndex = WI._openTabsSetting.value.indexOf("resources"); 157 if (debuggerIndex >= 0 || resourcesIndex >= 0) { 158 WI._openTabsSetting.value.remove("debugger"); 159 WI._openTabsSetting.value.remove("resources"); 160 161 if (debuggerIndex === -1) 162 debuggerIndex = Infinity; 163 if (resourcesIndex === -1) 164 resourcesIndex = Infinity; 165 166 let sourcesIndex = Math.min(debuggerIndex, resourcesIndex); 167 WI._openTabsSetting.value.splice(sourcesIndex, 1, WI.SourcesTabContentView.Type); 168 WI._openTabsSetting.save(); 169 170 if (WI._selectedTabIndexSetting.value === debuggerIndex || WI._selectedTabIndexSetting.value === resourcesIndex) 171 WI._selectedTabIndexSetting.value = sourcesIndex; 172 } 173 154 174 // State. 155 175 WI.printStylesEnabled = false;
Note: See TracChangeset
for help on using the changeset viewer.