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

Side by Side Diff: chrome/browser/resources/task_manager/main.js

Issue 11280253: Fixing column widths in tables. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Code review fixes. Created 8 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/resources/shared/js/cr/ui/table/table_splitter.js ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 /** @constructor */ 5 /** @constructor */
6 function TaskManager() { } 6 function TaskManager() { }
7 7
8 cr.addSingletonGetter(TaskManager); 8 cr.addSingletonGetter(TaskManager);
9 9
10 TaskManager.prototype = { 10 TaskManager.prototype = {
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
199 // Initialize a context-menu, if the label exists and its context- 199 // Initialize a context-menu, if the label exists and its context-
200 // menu is not initialized yet. 200 // menu is not initialized yet.
201 if (label && !label.contextMenu) 201 if (label && !label.contextMenu)
202 cr.ui.contextMenuHandler.setContextMenu(label, 202 cr.ui.contextMenuHandler.setContextMenu(label,
203 this.tableContextMenu_); 203 this.tableContextMenu_);
204 } 204 }
205 } 205 }
206 } 206 }
207 207
208 this.isFinishedInitDelayed_ = true; 208 this.isFinishedInitDelayed_ = true;
209 this.table_.redraw(); 209 var t = this.table_;
210 t.redraw();
211 addEventListener('resize', t.redraw.bind(t));
210 }, 212 },
211 213
212 initColumnModel_: function() { 214 initColumnModel_: function() {
213 var table_columns = new Array(); 215 var table_columns = new Array();
214 for (var i = 0; i < DEFAULT_COLUMNS.length; i++) { 216 for (var i = 0; i < DEFAULT_COLUMNS.length; i++) {
215 var column = DEFAULT_COLUMNS[i]; 217 var column = DEFAULT_COLUMNS[i];
216 var columnId = column[0]; 218 var columnId = column[0];
217 if (!isColumnEnabled(columnId)) 219 if (!isColumnEnabled(columnId))
218 continue; 220 continue;
219 221
(...skipping 468 matching lines...) Expand 10 before | Expand all | Expand 10 after
688 function init() { 690 function init() {
689 var params = parseQueryParams(window.location); 691 var params = parseQueryParams(window.location);
690 var opt = {}; 692 var opt = {};
691 opt['isBackgroundMode'] = params.background; 693 opt['isBackgroundMode'] = params.background;
692 opt['isShowCloseButton'] = params.showclose; 694 opt['isShowCloseButton'] = params.showclose;
693 taskmanager.initialize(document.body, opt); 695 taskmanager.initialize(document.body, opt);
694 } 696 }
695 697
696 document.addEventListener('DOMContentLoaded', init); 698 document.addEventListener('DOMContentLoaded', init);
697 document.addEventListener('Close', taskmanager.onClose.bind(taskmanager)); 699 document.addEventListener('Close', taskmanager.onClose.bind(taskmanager));
OLDNEW
« no previous file with comments | « chrome/browser/resources/shared/js/cr/ui/table/table_splitter.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698