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

Side by Side Diff: chrome/browser/resources/file_manager/js/file_manager_pyauto.js

Issue 12225135: [Cleanup] Files.app: add missing periods on comments. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: comment fix Created 7 years, 10 months 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 /** 5 /**
6 * pyautoAPI object provides a set of functions used by PyAuto tests 6 * pyautoAPI object provides a set of functions used by PyAuto tests
7 * to drive the file manager. 7 * to drive the file manager.
8 * 8 *
9 * Refer to chrome/test/functional/chromeos_file_browser.py for examples 9 * Refer to chrome/test/functional/chromeos_file_browser.py for examples
10 * of how this API is used. 10 * of how this API is used.
11 * 11 *
12 * TODO(olege): Fix style warnings. 12 * TODO(olege): Fix style warnings.
13 */ 13 */
14 var pyautoAPI = { 14 var pyautoAPI = {
15 /** 15 /**
16 * Add the item with given name to the current selection. 16 * Add the item with given name to the current selection.
17 * @param {string} name Name of the item to add to selection 17 * @param {string} name Name of the item to add to selection.
18 */ 18 */
19 addItemToSelection: function(name) { 19 addItemToSelection: function(name) {
20 var entryExists = false; 20 var entryExists = false;
21 var dm = fileManager.directoryModel_.getFileList(); 21 var dm = fileManager.directoryModel_.getFileList();
22 for (var i = 0; i < dm.length; i++) { 22 for (var i = 0; i < dm.length; i++) {
23 if (dm.item(i).name == name) { 23 if (dm.item(i).name == name) {
24 fileManager.currentList_.selectionModel.setIndexSelected(i, true); 24 fileManager.currentList_.selectionModel.setIndexSelected(i, true);
25 fileManager.currentList_.scrollIndexIntoView(i); 25 fileManager.currentList_.scrollIndexIntoView(i);
26 fileManager.focusCurrentList_(); 26 fileManager.focusCurrentList_();
27 entryExists = true; 27 entryExists = true;
(...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after
235 window.domAutomationController.send(JSON.stringify(value)); 235 window.domAutomationController.send(JSON.stringify(value));
236 }, 236 },
237 237
238 /** 238 /**
239 * Callback function signalling completion of operation. 239 * Callback function signalling completion of operation.
240 */ 240 */
241 sendDone_: function() { 241 sendDone_: function() {
242 window.domAutomationController.send('done'); 242 window.domAutomationController.send('done');
243 } 243 }
244 }; 244 };
OLDNEW
« no previous file with comments | « chrome/browser/resources/file_manager/js/directory_model.js ('k') | chrome/browser/resources/file_manager/js/file_table.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698