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

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

Issue 102073008: Allow multiple NaCl modules to be debugged. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix mac Created 7 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
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 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 this.onSelectionChange.bind(this)); 109 this.onSelectionChange.bind(this));
110 110
111 // Initializes compare functions for column sort. 111 // Initializes compare functions for column sort.
112 var dm = this.dataModel_; 112 var dm = this.dataModel_;
113 // List of columns to sort by its numerical value as opposed to the 113 // List of columns to sort by its numerical value as opposed to the
114 // formatted value, e.g., 20480 vs. 20KB. 114 // formatted value, e.g., 20480 vs. 20KB.
115 var COLUMNS_SORTED_BY_VALUE = [ 115 var COLUMNS_SORTED_BY_VALUE = [
116 'cpuUsage', 'physicalMemory', 'sharedMemory', 'privateMemory', 116 'cpuUsage', 'physicalMemory', 'sharedMemory', 'privateMemory',
117 'networkUsage', 'webCoreImageCacheSize', 'webCoreScriptsCacheSize', 117 'networkUsage', 'webCoreImageCacheSize', 'webCoreScriptsCacheSize',
118 'webCoreCSSCacheSize', 'fps', 'videoMemory', 'sqliteMemoryUsed', 118 'webCoreCSSCacheSize', 'fps', 'videoMemory', 'sqliteMemoryUsed',
119 'goatsTeleported', 'v8MemoryAllocatedSize']; 119 'naclDebugStubPort', 'goatsTeleported', 'v8MemoryAllocatedSize'];
120 120
121 for (var i = 0; i < DEFAULT_COLUMNS.length; i++) { 121 for (var i = 0; i < DEFAULT_COLUMNS.length; i++) {
122 var columnId = DEFAULT_COLUMNS[i][0]; 122 var columnId = DEFAULT_COLUMNS[i][0];
123 var compareFunc = (function() { 123 var compareFunc = (function() {
124 var columnIdToSort = columnId; 124 var columnIdToSort = columnId;
125 if (COLUMNS_SORTED_BY_VALUE.indexOf(columnId) != -1) 125 if (COLUMNS_SORTED_BY_VALUE.indexOf(columnId) != -1)
126 columnIdToSort += 'Value'; 126 columnIdToSort += 'Value';
127 127
128 return function(a, b) { 128 return function(a, b) {
129 var aValues = a[columnIdToSort]; 129 var aValues = a[columnIdToSort];
(...skipping 557 matching lines...) Expand 10 before | Expand all | Expand 10 after
687 687
688 function init() { 688 function init() {
689 var params = parseQueryParams(window.location); 689 var params = parseQueryParams(window.location);
690 var opt = {}; 690 var opt = {};
691 opt['isShowCloseButton'] = params.showclose; 691 opt['isShowCloseButton'] = params.showclose;
692 taskmanager.initialize(document.body, opt); 692 taskmanager.initialize(document.body, opt);
693 } 693 }
694 694
695 document.addEventListener('DOMContentLoaded', init); 695 document.addEventListener('DOMContentLoaded', init);
696 document.addEventListener('Close', taskmanager.onClose.bind(taskmanager)); 696 document.addEventListener('Close', taskmanager.onClose.bind(taskmanager));
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698