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

Side by Side Diff: ash/common/system/tray/tray_image_item.h

Issue 2558043006: ash: Use system tray mojo interface to show system update tray icon (Closed)
Patch Set: fix gcc Created 4 years 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
« no previous file with comments | « ash/common/system/tray/system_tray_notifier.cc ('k') | ash/common/system/update/tray_update.h » ('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 #ifndef ASH_COMMON_SYSTEM_TRAY_TRAY_IMAGE_ITEM_H_ 5 #ifndef ASH_COMMON_SYSTEM_TRAY_TRAY_IMAGE_ITEM_H_
6 #define ASH_COMMON_SYSTEM_TRAY_TRAY_IMAGE_ITEM_H_ 6 #define ASH_COMMON_SYSTEM_TRAY_TRAY_IMAGE_ITEM_H_
7 7
8 #include "ash/ash_export.h" 8 #include "ash/ash_export.h"
9 #include "ash/common/system/tray/system_tray_item.h" 9 #include "ash/common/system/tray/system_tray_item.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "third_party/skia/include/core/SkColor.h" 11 #include "third_party/skia/include/core/SkColor.h"
12 12
13 namespace views { 13 namespace views {
14 class ImageView; 14 class ImageView;
15 } 15 }
16 16
17 namespace ash { 17 namespace ash {
18 class TrayItemView; 18 class TrayItemView;
19 19
20 // A system tray item that uses an image as its "tray view" in the status area.
20 class ASH_EXPORT TrayImageItem : public SystemTrayItem { 21 class ASH_EXPORT TrayImageItem : public SystemTrayItem {
21 public: 22 public:
22 TrayImageItem(SystemTray* system_tray, int resource_id, UmaType uma_type); 23 TrayImageItem(SystemTray* system_tray, int resource_id, UmaType uma_type);
23 ~TrayImageItem() override; 24 ~TrayImageItem() override;
24 25
25 views::View* tray_view(); 26 views::View* tray_view();
26 27
27 protected: 28 protected:
28 virtual bool GetInitialVisibility() = 0; 29 virtual bool GetInitialVisibility() = 0;
29 30
(...skipping 20 matching lines...) Expand all
50 void UpdateImageOnImageView(); 51 void UpdateImageOnImageView();
51 52
52 // The resource ID for the non-material design icon in the tray. 53 // The resource ID for the non-material design icon in the tray.
53 // TODO(tdanderson): This is only used for non-material design, so remove it 54 // TODO(tdanderson): This is only used for non-material design, so remove it
54 // when material design is the default. See crbug.com/625692. 55 // when material design is the default. See crbug.com/625692.
55 int resource_id_; 56 int resource_id_;
56 57
57 // The color of the material design icon in the tray. 58 // The color of the material design icon in the tray.
58 SkColor icon_color_; 59 SkColor icon_color_;
59 60
61 // The image view in the tray.
60 TrayItemView* tray_view_; 62 TrayItemView* tray_view_;
61 63
62 DISALLOW_COPY_AND_ASSIGN(TrayImageItem); 64 DISALLOW_COPY_AND_ASSIGN(TrayImageItem);
63 }; 65 };
64 66
65 } // namespace ash 67 } // namespace ash
66 68
67 #endif // ASH_COMMON_SYSTEM_TRAY_TRAY_IMAGE_ITEM_H_ 69 #endif // ASH_COMMON_SYSTEM_TRAY_TRAY_IMAGE_ITEM_H_
OLDNEW
« no previous file with comments | « ash/common/system/tray/system_tray_notifier.cc ('k') | ash/common/system/update/tray_update.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698