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

Side by Side Diff: ash/wm/resize_shadow.cc

Issue 10365007: ui: Move compositor/ directory out of gfx/, up to ui/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix DEPS Created 8 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « ash/wm/power_button_controller.cc ('k') | ash/wm/root_window_layout_manager.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/wm/resize_shadow.h" 5 #include "ash/wm/resize_shadow.h"
6 6
7 #include "ash/wm/image_grid.h" 7 #include "ash/wm/image_grid.h"
8 #include "base/time.h" 8 #include "base/time.h"
9 #include "grit/ui_resources.h" 9 #include "grit/ui_resources.h"
10 #include "ui/aura/window.h" 10 #include "ui/aura/window.h"
11 #include "ui/base/hit_test.h" 11 #include "ui/base/hit_test.h"
12 #include "ui/base/resource/resource_bundle.h" 12 #include "ui/base/resource/resource_bundle.h"
13 #include "ui/gfx/compositor/layer.h" 13 #include "ui/compositor/layer.h"
14 #include "ui/gfx/compositor/scoped_layer_animation_settings.h" 14 #include "ui/compositor/scoped_layer_animation_settings.h"
15 15
16 namespace { 16 namespace {
17 17
18 // Final opacity for resize effect. 18 // Final opacity for resize effect.
19 const float kShadowTargetOpacity = 0.25f; 19 const float kShadowTargetOpacity = 0.25f;
20 // Animation time for resize effect in milliseconds. 20 // Animation time for resize effect in milliseconds.
21 const int kShadowAnimationDurationMs = 200; 21 const int kShadowAnimationDurationMs = 200;
22 22
23 // Sets up a layer as invisible and fully transparent, without animating. 23 // Sets up a layer as invisible and fully transparent, without animating.
24 void InitLayer(ui::Layer* layer) { 24 void InitLayer(ui::Layer* layer) {
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 ShowForHitTest(HTNOWHERE); 101 ShowForHitTest(HTNOWHERE);
102 } 102 }
103 103
104 void ResizeShadow::Layout(const gfx::Rect& content_bounds) { 104 void ResizeShadow::Layout(const gfx::Rect& content_bounds) {
105 gfx::Rect local_bounds(content_bounds.size()); 105 gfx::Rect local_bounds(content_bounds.size());
106 image_grid_->SetContentBounds(local_bounds); 106 image_grid_->SetContentBounds(local_bounds);
107 } 107 }
108 108
109 } // namespace internal 109 } // namespace internal
110 } // namespace ash 110 } // namespace ash
OLDNEW
« no previous file with comments | « ash/wm/power_button_controller.cc ('k') | ash/wm/root_window_layout_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698