summaryrefslogtreecommitdiffstats
path: root/ash/accelerators
diff options
context:
space:
mode:
authorbshe@chromium.org <bshe@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-03-15 16:24:47 +0000
committerbshe@chromium.org <bshe@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-03-15 16:24:47 +0000
commite70cf0ed41432b87472fcfb7afda83c86091f0be (patch)
treedc71dca1f858760d79c5da83e837f244d260236e /ash/accelerators
parent51533e1bea52a6a7d16578bca8d676e00801b120 (diff)
downloadchromium_src-e70cf0ed41432b87472fcfb7afda83c86091f0be.zip
chromium_src-e70cf0ed41432b87472fcfb7afda83c86091f0be.tar.gz
chromium_src-e70cf0ed41432b87472fcfb7afda83c86091f0be.tar.bz2
Retry landing "Enable users change desktop background image from settings page in Chromeos Aura build"
Enable user change background image in settings page in Aura build. Only support change between default background images currently. This is a second try to land, last time it fails on win_aura build. The original CL is here: http://codereview.chromium.org/9580023/ TBR=flackr,ben,jhawkins BUG=105508 TEST=Go to settings page and click "set wallpaper" button to change background image. Review URL: https://chromiumcodereview.appspot.com/9703031 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@126923 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ash/accelerators')
-rw-r--r--ash/accelerators/accelerator_controller.cc11
1 files changed, 7 insertions, 4 deletions
diff --git a/ash/accelerators/accelerator_controller.cc b/ash/accelerators/accelerator_controller.cc
index 0eb7ce8..b43b5f4 100644
--- a/ash/accelerators/accelerator_controller.cc
+++ b/ash/accelerators/accelerator_controller.cc
@@ -5,6 +5,7 @@
#include "ash/accelerators/accelerator_controller.h"
#include "ash/accelerators/accelerator_table.h"
+#include "ash/desktop_background/desktop_background_controller.h"
#include "ash/ash_switches.h"
#include "ash/caps_lock_delegate.h"
#include "ash/ime_control_delegate.h"
@@ -90,11 +91,13 @@ bool HandleRotateScreen() {
}
bool HandleToggleDesktopBackgroundMode() {
- ash::Shell* shell = ash::Shell::GetInstance();
- if (shell->desktop_background_mode() == ash::Shell::BACKGROUND_IMAGE)
- shell->SetDesktopBackgroundMode(ash::Shell::BACKGROUND_SOLID_COLOR);
+ ash::DesktopBackgroundController* desktop_background_controller =
+ ash::Shell::GetInstance()->desktop_background_controller();
+ if (desktop_background_controller->desktop_background_mode() ==
+ ash::DesktopBackgroundController::BACKGROUND_IMAGE)
+ desktop_background_controller->SetDesktopBackgroundSolidColorMode();
else
- shell->SetDesktopBackgroundMode(ash::Shell::BACKGROUND_IMAGE);
+ desktop_background_controller->SetPreviousDesktopBackgroundImage();
return true;
}