OLD | NEW |
---|---|
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 #include "ash/accelerators/accelerator_controller.h" | 5 #include "ash/accelerators/accelerator_controller.h" |
6 | 6 |
7 #include "ash/desktop_background/desktop_background_controller.h" | |
7 #include "ash/caps_lock_delegate.h" | 8 #include "ash/caps_lock_delegate.h" |
8 #include "ash/ime_control_delegate.h" | 9 #include "ash/ime_control_delegate.h" |
9 #include "ash/launcher/launcher.h" | 10 #include "ash/launcher/launcher.h" |
10 #include "ash/launcher/launcher_model.h" | 11 #include "ash/launcher/launcher_model.h" |
11 #include "ash/screenshot_delegate.h" | 12 #include "ash/screenshot_delegate.h" |
12 #include "ash/shell.h" | 13 #include "ash/shell.h" |
13 #include "ash/shell_delegate.h" | 14 #include "ash/shell_delegate.h" |
14 #include "ash/shell_window_ids.h" | 15 #include "ash/shell_window_ids.h" |
15 #include "ash/system/brightness/brightness_control_delegate.h" | 16 #include "ash/system/brightness/brightness_control_delegate.h" |
16 #include "ash/volume_control_delegate.h" | 17 #include "ash/volume_control_delegate.h" |
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
192 new ui::LayerAnimationSequence(new ui::ScreenRotation(delta))); | 193 new ui::LayerAnimationSequence(new ui::ScreenRotation(delta))); |
193 screen_rotation->AddObserver(ash::Shell::GetRootWindow()); | 194 screen_rotation->AddObserver(ash::Shell::GetRootWindow()); |
194 ash::Shell::GetRootWindow()->layer()->GetAnimator()->StartAnimation( | 195 ash::Shell::GetRootWindow()->layer()->GetAnimator()->StartAnimation( |
195 screen_rotation.release()); | 196 screen_rotation.release()); |
196 return true; | 197 return true; |
197 } | 198 } |
198 | 199 |
199 bool HandleToggleDesktopBackgroundMode() { | 200 bool HandleToggleDesktopBackgroundMode() { |
200 ash::Shell* shell = ash::Shell::GetInstance(); | 201 ash::Shell* shell = ash::Shell::GetInstance(); |
201 if (shell->desktop_background_mode() == ash::Shell::BACKGROUND_IMAGE) | 202 if (shell->desktop_background_mode() == ash::Shell::BACKGROUND_IMAGE) |
202 shell->SetDesktopBackgroundMode(ash::Shell::BACKGROUND_SOLID_COLOR); | 203 shell->SetDesktopBackgroundSolidColorMode(); |
203 else | 204 else { |
204 shell->SetDesktopBackgroundMode(ash::Shell::BACKGROUND_IMAGE); | 205 shell->SetDesktopBackgroundImageMode(shell-> |
flackr
2012/03/08 01:19:59
This would be a good place for just indenting 4 sp
bshe
2012/03/08 03:19:24
Done.
| |
206 desktop_background_controller()-> | |
207 GetUserWallpaper()); | |
208 } | |
205 return true; | 209 return true; |
206 } | 210 } |
207 | 211 |
208 bool HandleToggleRootWindowFullScreen() { | 212 bool HandleToggleRootWindowFullScreen() { |
209 ash::Shell::GetRootWindow()->ToggleFullScreen(); | 213 ash::Shell::GetRootWindow()->ToggleFullScreen(); |
210 return true; | 214 return true; |
211 } | 215 } |
212 | 216 |
213 bool HandlePrintLayerHierarchy() { | 217 bool HandlePrintLayerHierarchy() { |
214 aura::RootWindow* root_window = ash::Shell::GetRootWindow(); | 218 aura::RootWindow* root_window = ash::Shell::GetRootWindow(); |
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
395 NOTREACHED() << "Unhandled action " << it->second; | 399 NOTREACHED() << "Unhandled action " << it->second; |
396 } | 400 } |
397 return false; | 401 return false; |
398 } | 402 } |
399 | 403 |
400 bool AcceleratorController::CanHandleAccelerators() const { | 404 bool AcceleratorController::CanHandleAccelerators() const { |
401 return true; | 405 return true; |
402 } | 406 } |
403 | 407 |
404 } // namespace ash | 408 } // namespace ash |
OLD | NEW |