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

Issue 9839098: Fix wallpaper change to a random one when user first click "set wallpaper". (Closed)

Created:
8 years, 9 months ago by bshe
Modified:
8 years, 9 months ago
CC:
chromium-reviews, stevenjb+watch_chromium.org, nkostylev+watch_chromium.org, davemoore+watch_chromium.org, Emmanuel Saint-loubert-BiƩ
Visibility:
Public.

Description

Fix wallpaper change to a random one when user first click "set wallpaper" or login BUG=119973, 119971 TEST= Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=128817

Patch Set 1 #

Patch Set 2 : Rename SaveWallpaperDefaultIndex to SaveUserWallpaperIndex and nits #

Patch Set 3 : Add comments #

Patch Set 4 : Fix linux_chromeos crash #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+43 lines, -42 lines) Patch
M chrome/browser/chromeos/background/desktop_background_observer.cc View 1 chunk +1 line, -11 lines 0 comments Download
M chrome/browser/chromeos/login/mock_user_manager.h View 1 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/chromeos/login/user_manager.h View 1 1 chunk +8 lines, -10 lines 0 comments Download
M chrome/browser/chromeos/login/user_manager_impl.h View 1 1 chunk +2 lines, -3 lines 0 comments Download
M chrome/browser/chromeos/login/user_manager_impl.cc View 1 2 3 1 chunk +24 lines, -7 lines 2 comments Download
M chrome/browser/ui/webui/options2/chromeos/set_wallpaper_options_handler2.cc View 1 2 3 3 chunks +6 lines, -9 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
bshe
Hi Ben. Could you please take a look at this CL? Basically Emmanuel's change got ...
8 years, 9 months ago (2012-03-25 01:59:26 UTC) #1
Ben Goodger (Google)
lgtm
8 years, 9 months ago (2012-03-25 06:44:56 UTC) #2
Nikita (slow)
8 years, 9 months ago (2012-03-25 21:24:08 UTC) #3
Please fix in a followup CL.

https://chromiumcodereview.appspot.com/9839098/diff/7014/chrome/browser/chrom...
File chrome/browser/chromeos/login/user_manager_impl.cc (right):

https://chromiumcodereview.appspot.com/9839098/diff/7014/chrome/browser/chrom...
chrome/browser/chromeos/login/user_manager_impl.cc:915: if (IsLoggedInAsGuest()
|| !IsUserLoggedIn())
+ IsCurrentUserEphemeral()

In fact you should remove IsLoggedInAsGuest() and add only

if (IsCurrentUserEphemeral() || !IsUserLoggedIn())

IsCurrentUserEphemeral will be true for Demo/Guest/normal users when Ephemeral
policy is enabled / stub user.

Obviously this will block testing change of wallpaper on desktop (where stub
user is normally used) but that should be fixed separately.

https://chromiumcodereview.appspot.com/9839098/diff/7014/chrome/browser/chrom...
chrome/browser/chromeos/login/user_manager_impl.cc:938: if (IsLoggedInAsGuest()
|| !IsUserLoggedIn())
Change IsLoggedInAsGuest() to IsCurrentUserEphemeral() so that ephemeral and
demo users are handled too.

If ephemeral user policy is enabed - no changes should be made to LocalState as
user home will be removed on sign out. All changes should reside in memory.
Demo user / guest user is a variant of ephemeral users.

Powered by Google App Engine
This is Rietveld 408576698