Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(302)

Unified Diff: third_party/WebKit/Source/devtools/front_end/ui/TabbedPane.js

Issue 2571983002: DevTools: do not add paint profiler tab more than once on Layers panel (Closed)
Patch Set: Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/devtools/front_end/layers/LayersPanel.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/devtools/front_end/ui/TabbedPane.js
diff --git a/third_party/WebKit/Source/devtools/front_end/ui/TabbedPane.js b/third_party/WebKit/Source/devtools/front_end/ui/TabbedPane.js
index d9ad72fd65cae6229ba246d3ef431aea7e4680b4..21868b1f9ccb21c22d9d161a616aa658bbcce439 100644
--- a/third_party/WebKit/Source/devtools/front_end/ui/TabbedPane.js
+++ b/third_party/WebKit/Source/devtools/front_end/ui/TabbedPane.js
@@ -191,6 +191,7 @@ UI.TabbedPane = class extends UI.VBox {
isCloseable = typeof isCloseable === 'boolean' ? isCloseable : this._closeableTabs;
var tab = new UI.TabbedPaneTab(this, id, tabTitle, isCloseable, view, tabTooltip);
tab.setDelegate(this._delegate);
+ console.assert(!this._tabsById[id], `Tabbed pane already contains a tab with id '${id}'`);
this._tabsById[id] = tab;
if (index !== undefined)
this._tabs.splice(index, 0, tab);
« no previous file with comments | « third_party/WebKit/Source/devtools/front_end/layers/LayersPanel.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698