diff options
author | oshima <oshima@chromium.org> | 2015-10-21 18:08:08 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-10-22 01:09:51 +0000 |
commit | cefa50b01ed3d5d592f66ab56b5b3934b5ad9070 (patch) | |
tree | 82ae51cbe6a1343145a4ccd34dbbd7a9ed95fb3d /ash/root_window_controller.cc | |
parent | 1effc29d7e15f64791405c5d0af30b24040fc1d7 (diff) | |
download | chromium_src-cefa50b01ed3d5d592f66ab56b5b3934b5ad9070.zip chromium_src-cefa50b01ed3d5d592f66ab56b5b3934b5ad9070.tar.gz chromium_src-cefa50b01ed3d5d592f66ab56b5b3934b5ad9070.tar.bz2 |
Refactor screen_dimmer to share code and shrink Shell interface.
DimWindow : a window that implement dimming. You can just add it to container and let it handle its state.
ScreenDimmer : an object that keeps the state consistent across multiple root windows. It's owned by the primary container and gets destroyed when the container is destroyed.
* Added wm::SetWindowVisiblityChangesAnimated to ui/wm/core/visibility_controller.h, to animate individual window's visibility change. The dim layer can be added to root (or any other container), and we probably don't want to enable animation for all children in such case.
* Use solid color layer for modal background. it's more efficient.
BUG=478438
TEST=updated existing screen_dimmer_unittest, VisibilityControllerTest.SetWindowVisibilityChangesAnimated
Review URL: https://codereview.chromium.org/1415033002
Cr-Commit-Position: refs/heads/master@{#355468}
Diffstat (limited to 'ash/root_window_controller.cc')
-rw-r--r-- | ash/root_window_controller.cc | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/ash/root_window_controller.cc b/ash/root_window_controller.cc index 97fd09e..c693858 100644 --- a/ash/root_window_controller.cc +++ b/ash/root_window_controller.cc @@ -39,7 +39,6 @@ #include "ash/wm/panels/panel_layout_manager.h" #include "ash/wm/panels/panel_window_event_handler.h" #include "ash/wm/root_window_layout_manager.h" -#include "ash/wm/screen_dimmer.h" #include "ash/wm/stacking_controller.h" #include "ash/wm/status_area_layout_manager.h" #include "ash/wm/system_background_controller.h" @@ -367,7 +366,6 @@ void RootWindowController::Shutdown() { CloseChildWindows(); GetRootWindowSettings(root_window)->controller = NULL; - screen_dimmer_.reset(); workspace_controller_.reset(); // Forget with the display ID so that display lookup // ends up with invalid display. @@ -694,7 +692,6 @@ RootWindowController::RootWindowController(AshWindowTreeHost* ash_host) touch_hud_projection_(NULL) { aura::Window* root_window = GetRootWindow(); GetRootWindowSettings(root_window)->controller = this; - screen_dimmer_.reset(new ScreenDimmer(root_window)); stacking_controller_.reset(new StackingController); aura::client::SetWindowTreeClient(root_window, stacking_controller_.get()); |