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 #ifndef ASH_DESKTOP_BACKGROUND_DESKTOP_BACKGROUND_VIEW_H_ | 5 #ifndef ASH_DESKTOP_BACKGROUND_DESKTOP_BACKGROUND_VIEW_H_ |
6 #define ASH_DESKTOP_BACKGROUND_DESKTOP_BACKGROUND_VIEW_H_ | 6 #define ASH_DESKTOP_BACKGROUND_DESKTOP_BACKGROUND_VIEW_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "ash/desktop_background/desktop_background_resources.h" | 9 #include "ash/desktop_background/desktop_background_resources.h" |
10 #include "third_party/skia/include/core/SkBitmap.h" | 10 #include "third_party/skia/include/core/SkBitmap.h" |
11 #include "ui/views/view.h" | 11 #include "ui/views/view.h" |
12 #include "ui/views/widget/widget_delegate.h" | 12 #include "ui/views/widget/widget_delegate.h" |
13 | 13 |
14 namespace ash { | 14 namespace ash { |
15 namespace internal { | 15 namespace internal { |
16 | 16 |
17 class DesktopBackgroundView : public views::WidgetDelegateView { | 17 class DesktopBackgroundView : public views::WidgetDelegateView { |
18 public: | 18 public: |
19 DesktopBackgroundView(const SkBitmap& wallpaper, ImageLayout layout); | 19 DesktopBackgroundView(const SkBitmap& wallpaper, WallpaperLayout layout); |
flackr
2012/05/09 21:26:16
s/layout/wallpaper_layout for consistency.
bshe
2012/05/10 16:10:26
Done.
| |
20 virtual ~DesktopBackgroundView(); | 20 virtual ~DesktopBackgroundView(); |
21 | 21 |
22 private: | 22 private: |
23 // Overridden from views::View: | 23 // Overridden from views::View: |
24 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE; | 24 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE; |
25 virtual bool OnMousePressed(const views::MouseEvent& event) OVERRIDE; | 25 virtual bool OnMousePressed(const views::MouseEvent& event) OVERRIDE; |
26 virtual void OnMouseReleased(const views::MouseEvent& event) OVERRIDE; | 26 virtual void OnMouseReleased(const views::MouseEvent& event) OVERRIDE; |
27 | 27 |
28 SkBitmap wallpaper_; | 28 SkBitmap wallpaper_; |
29 ImageLayout image_layout_; | 29 WallpaperLayout wallpaper_layout_; |
30 | 30 |
31 DISALLOW_COPY_AND_ASSIGN(DesktopBackgroundView); | 31 DISALLOW_COPY_AND_ASSIGN(DesktopBackgroundView); |
32 }; | 32 }; |
33 | 33 |
34 } // namespace internal | 34 } // namespace internal |
35 } // namespace ash | 35 } // namespace ash |
36 | 36 |
37 #endif // ASH_DESKTOP_BACKGROUND_DESKTOP_BACKGROUND_VIEW_H_ | 37 #endif // ASH_DESKTOP_BACKGROUND_DESKTOP_BACKGROUND_VIEW_H_ |
OLD | NEW |