Chromium Code Reviews| Index: chrome/browser/resources/net_internals/tabswitcherview.js |
| =================================================================== |
| --- chrome/browser/resources/net_internals/tabswitcherview.js (revision 68021) |
| +++ chrome/browser/resources/net_internals/tabswitcherview.js (working copy) |
| @@ -22,7 +22,10 @@ |
| * |
| * @constructor |
| */ |
| -function TabSwitcherView(tabHandleView) { |
| +function TabSwitcherView(tabHandleDivId) { |
|
arv (Not doing code reviews)
2010/12/08 17:55:19
I find it bad practice to pass around IDs to eleme
nduca
2010/12/08 19:08:22
Noted, and agreed for fresh code.
The rest of Net
|
| + document.getElementById(tabHandleDivId).classList.add('tab-switcher-view'); |
| + var tabHandleView = new DivView(tabHandleDivId); |
| + |
| View.call(this); |
| this.tabHandleView_ = tabHandleView; |
| this.tabs_ = []; |
| @@ -122,7 +125,8 @@ |
| // Update data needed by newly active tab, as it may be |
| // significantly out of date. |
| - g_browser.checkForUpdatedInfo(); |
| + if (typeof g_browser != 'undefined' && g_browser.checkForUpdatedInfo) |
| + g_browser.checkForUpdatedInfo(); |
| }; |
| TabSwitcherView.prototype.getAllTabIds = function() { |