OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #ifndef UI_AURA_SHELL_SHADOW_H_ | 5 #ifndef UI_AURA_SHELL_SHADOW_H_ |
6 #define UI_AURA_SHELL_SHADOW_H_ | 6 #define UI_AURA_SHELL_SHADOW_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| 11 #include "ui/aura_shell/aura_shell_export.h" |
11 #include "ui/gfx/rect.h" | 12 #include "ui/gfx/rect.h" |
12 | 13 |
13 namespace ui { | 14 namespace ui { |
14 class Layer; | 15 class Layer; |
15 } // namespace ui | 16 } // namespace ui |
16 | 17 |
17 namespace aura_shell { | 18 namespace aura_shell { |
18 namespace internal { | 19 namespace internal { |
19 | 20 |
20 class ImageGrid; | 21 class ImageGrid; |
21 | 22 |
22 // Simple class that draws a drop shadow around content at given bounds. | 23 // Simple class that draws a drop shadow around content at given bounds. |
23 class Shadow { | 24 class AURA_SHELL_EXPORT Shadow { |
24 public: | 25 public: |
25 Shadow(); | 26 Shadow(); |
26 ~Shadow(); | 27 ~Shadow(); |
27 | 28 |
28 // Returns |image_grid_|'s ui::Layer. This is exposed so it can be added to | 29 // Returns |image_grid_|'s ui::Layer. This is exposed so it can be added to |
29 // the same layer as the content and stacked below it. SetContentBounds() | 30 // the same layer as the content and stacked below it. SetContentBounds() |
30 // should be used to adjust the shadow's size and position (rather than | 31 // should be used to adjust the shadow's size and position (rather than |
31 // applying transformations to this layer). | 32 // applying transformations to this layer). |
32 ui::Layer* layer() const; | 33 ui::Layer* layer() const; |
33 | 34 |
(...skipping 10 matching lines...) Expand all Loading... |
44 // Bounds of the content that the shadow encloses. | 45 // Bounds of the content that the shadow encloses. |
45 gfx::Rect content_bounds_; | 46 gfx::Rect content_bounds_; |
46 | 47 |
47 DISALLOW_COPY_AND_ASSIGN(Shadow); | 48 DISALLOW_COPY_AND_ASSIGN(Shadow); |
48 }; | 49 }; |
49 | 50 |
50 } // namespace internal | 51 } // namespace internal |
51 } // namespace aura_shell | 52 } // namespace aura_shell |
52 | 53 |
53 #endif // UI_AURA_SHELL_SHADOW_H_ | 54 #endif // UI_AURA_SHELL_SHADOW_H_ |
OLD | NEW |