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_SYSTEM_TRAY_TRAY_VIEWS_H_ | 5 #ifndef ASH_SYSTEM_TRAY_TRAY_VIEWS_H_ |
6 #define ASH_SYSTEM_TRAY_TRAY_VIEWS_H_ | 6 #define ASH_SYSTEM_TRAY_TRAY_VIEWS_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "ui/gfx/font.h" | 9 #include "ui/gfx/font.h" |
10 #include "ui/gfx/size.h" | 10 #include "ui/gfx/size.h" |
11 #include "ui/views/controls/image_view.h" | 11 #include "ui/views/controls/image_view.h" |
12 #include "ui/views/view.h" | 12 #include "ui/views/view.h" |
13 | 13 |
14 class SkBitmap; | 14 class SkBitmap; |
15 | 15 |
| 16 namespace views { |
| 17 class Label; |
| 18 } |
| 19 |
16 namespace ash { | 20 namespace ash { |
17 namespace internal { | 21 namespace internal { |
18 | 22 |
19 // An image view with that always has a fixed width (kTrayPopupDetailsIconWidth) | 23 // An image view with that always has a fixed width (kTrayPopupDetailsIconWidth) |
20 class FixedWidthImageView : public views::ImageView { | 24 class FixedWidthImageView : public views::ImageView { |
21 public: | 25 public: |
22 FixedWidthImageView(); | 26 FixedWidthImageView(); |
23 virtual ~FixedWidthImageView(); | 27 virtual ~FixedWidthImageView(); |
24 | 28 |
25 private: | 29 private: |
(...skipping 28 matching lines...) Expand all Loading... |
54 // Overridden from views::View. | 58 // Overridden from views::View. |
55 virtual bool OnMousePressed(const views::MouseEvent& event) OVERRIDE; | 59 virtual bool OnMousePressed(const views::MouseEvent& event) OVERRIDE; |
56 virtual void OnMouseEntered(const views::MouseEvent& event) OVERRIDE; | 60 virtual void OnMouseEntered(const views::MouseEvent& event) OVERRIDE; |
57 virtual void OnMouseExited(const views::MouseEvent& event) OVERRIDE; | 61 virtual void OnMouseExited(const views::MouseEvent& event) OVERRIDE; |
58 | 62 |
59 ViewClickListener* listener_; | 63 ViewClickListener* listener_; |
60 | 64 |
61 DISALLOW_COPY_AND_ASSIGN(HoverHighlightView); | 65 DISALLOW_COPY_AND_ASSIGN(HoverHighlightView); |
62 }; | 66 }; |
63 | 67 |
| 68 // Sets up a Label properly for the tray (sets color, font etc.). |
| 69 void SetupLabelForTray(views::Label* label); |
| 70 |
64 } // namespace internal | 71 } // namespace internal |
65 } // namespace ash | 72 } // namespace ash |
66 | 73 |
67 #endif // ASH_SYSTEM_TRAY_TRAY_VIEWS_H_ | 74 #endif // ASH_SYSTEM_TRAY_TRAY_VIEWS_H_ |
OLD | NEW |