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

Side by Side Diff: chrome/browser/resources/chromeos/wallpaper_manager/js/event_page.js

Issue 1631923004: Sync 3rd party wallpaper app name (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 var WALLPAPER_PICKER_WIDTH = 574; 5 var WALLPAPER_PICKER_WIDTH = 574;
6 var WALLPAPER_PICKER_HEIGHT = 420; 6 var WALLPAPER_PICKER_HEIGHT = 420;
7 7
8 var wallpaperPickerWindow; 8 var wallpaperPickerWindow;
9 9
10 var surpriseWallpaper = null; 10 var surpriseWallpaper = null;
(...skipping 405 matching lines...) Expand 10 before | Expand all | Expand 10 after
416 chrome.wallpaperPrivate.onWallpaperChangedBy3rdParty.addListener(function( 416 chrome.wallpaperPrivate.onWallpaperChangedBy3rdParty.addListener(function(
417 wallpaper, thumbnail, layout) { 417 wallpaper, thumbnail, layout) {
418 WallpaperUtil.saveToLocalStorage( 418 WallpaperUtil.saveToLocalStorage(
419 Constants.AccessLocalSurpriseMeEnabledKey, false, function() { 419 Constants.AccessLocalSurpriseMeEnabledKey, false, function() {
420 WallpaperUtil.saveToSyncStorage(Constants.AccessSyncSurpriseMeEnabledKey, 420 WallpaperUtil.saveToSyncStorage(Constants.AccessSyncSurpriseMeEnabledKey,
421 false); 421 false);
422 }); 422 });
423 SurpriseWallpaper.getInstance().disable(); 423 SurpriseWallpaper.getInstance().disable();
424 424
425 // Make third party wallpaper syncable through different devices. 425 // Make third party wallpaper syncable through different devices.
426 // TODO(xdai): also sync the third party app name.
427 var filename = Constants.ThirdPartyWallpaperPrefix + new Date().getTime(); 426 var filename = Constants.ThirdPartyWallpaperPrefix + new Date().getTime();
428 var thumbnailFilename = filename + Constants.CustomWallpaperThumbnailSuffix; 427 var thumbnailFilename = filename + Constants.CustomWallpaperThumbnailSuffix;
429 WallpaperUtil.storeWallpaperToSyncFS(filename, wallpaper); 428 WallpaperUtil.storeWallpaperToSyncFS(filename, wallpaper);
430 WallpaperUtil.storeWallpaperToSyncFS(thumbnailFilename, thumbnail); 429 WallpaperUtil.storeWallpaperToSyncFS(thumbnailFilename, thumbnail);
431 WallpaperUtil.saveWallpaperInfo(filename, layout, 430 WallpaperUtil.saveWallpaperInfo(filename, layout,
432 Constants.WallpaperSourceEnum.Custom); 431 Constants.WallpaperSourceEnum.Custom);
433 }); 432 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698