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

Side by Side Diff: chrome/browser/resources/chromeos/user_images_grid.js

Issue 566063002: Compile chrome://settings, part 8: the final battle (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@H_options_errors_6
Patch Set: rebase Created 6 years, 2 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
« no previous file with comments | « no previous file | chrome/browser/resources/options/browser_options.js » ('j') | 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 cr.define('options', function() { 5 cr.define('options', function() {
6 /** @const */ var ArrayDataModel = cr.ui.ArrayDataModel; 6 /** @const */ var ArrayDataModel = cr.ui.ArrayDataModel;
7 /** @const */ var Grid = cr.ui.Grid; 7 /** @const */ var Grid = cr.ui.Grid;
8 /** @const */ var GridItem = cr.ui.GridItem; 8 /** @const */ var GridItem = cr.ui.GridItem;
9 /** @const */ var GridSelectionController = cr.ui.GridSelectionController; 9 /** @const */ var GridSelectionController = cr.ui.GridSelectionController;
10 /** @const */ var ListSingleSelectionModel = cr.ui.ListSingleSelectionModel; 10 /** @const */ var ListSingleSelectionModel = cr.ui.ListSingleSelectionModel;
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after
239 // Cancel any pending getUserMedia() checks. 239 // Cancel any pending getUserMedia() checks.
240 this.cameraStartInProgress_ = false; 240 this.cameraStartInProgress_ = false;
241 }, 241 },
242 242
243 /** 243 /**
244 * Handles successful camera check. 244 * Handles successful camera check.
245 * @param {function(): boolean} onAvailable Callback to call. If it returns 245 * @param {function(): boolean} onAvailable Callback to call. If it returns
246 * |true|, capture is started immediately. 246 * |true|, capture is started immediately.
247 * @param {!MediaStream} stream Stream object as returned by getUserMedia. 247 * @param {!MediaStream} stream Stream object as returned by getUserMedia.
248 * @private 248 * @private
249 * @suppress {deprecated}
249 */ 250 */
250 handleCameraAvailable_: function(onAvailable, stream) { 251 handleCameraAvailable_: function(onAvailable, stream) {
251 if (this.cameraStartInProgress_ && onAvailable()) { 252 if (this.cameraStartInProgress_ && onAvailable()) {
252 this.cameraVideo_.src = URL.createObjectURL(stream); 253 this.cameraVideo_.src = URL.createObjectURL(stream);
253 this.cameraStream_ = stream; 254 this.cameraStream_ = stream;
254 } else { 255 } else {
255 stream.stop(); 256 stream.stop();
256 } 257 }
257 this.cameraStartInProgress_ = false; 258 this.cameraStartInProgress_ = false;
258 }, 259 },
(...skipping 385 matching lines...) Expand 10 before | Expand all | Expand 10 after
644 UserImagesGrid.ButtonImages = { 645 UserImagesGrid.ButtonImages = {
645 TAKE_PHOTO: 'chrome://theme/IDR_BUTTON_USER_IMAGE_TAKE_PHOTO', 646 TAKE_PHOTO: 'chrome://theme/IDR_BUTTON_USER_IMAGE_TAKE_PHOTO',
646 CHOOSE_FILE: 'chrome://theme/IDR_BUTTON_USER_IMAGE_CHOOSE_FILE', 647 CHOOSE_FILE: 'chrome://theme/IDR_BUTTON_USER_IMAGE_CHOOSE_FILE',
647 PROFILE_PICTURE: 'chrome://theme/IDR_PROFILE_PICTURE_LOADING' 648 PROFILE_PICTURE: 'chrome://theme/IDR_PROFILE_PICTURE_LOADING'
648 }; 649 };
649 650
650 return { 651 return {
651 UserImagesGrid: UserImagesGrid 652 UserImagesGrid: UserImagesGrid
652 }; 653 };
653 }); 654 });
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/resources/options/browser_options.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698