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

Unified Diff: ash/common/system/tray/tray_item_more.h

Issue 2365523002: Materialized the font/icon color for some default rows in the system menu. (Closed)
Patch Set: Applied TrayPopupItemStyle to Network, SMS, Tracing, OS Update. Created 4 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: ash/common/system/tray/tray_item_more.h
diff --git a/ash/common/system/tray/tray_item_more.h b/ash/common/system/tray/tray_item_more.h
index acd9b30a6b729354140f07d94da14388b5ba2347..7bf5c225953da228e6a0a9abc9afc993229d6389 100644
--- a/ash/common/system/tray/tray_item_more.h
+++ b/ash/common/system/tray/tray_item_more.h
@@ -5,6 +5,8 @@
#ifndef ASH_COMMON_SYSTEM_TRAY_TRAY_ITEM_MORE_H_
#define ASH_COMMON_SYSTEM_TRAY_TRAY_ITEM_MORE_H_
+#include <memory>
+
#include "ash/common/system/tray/actionable_view.h"
#include "base/macros.h"
#include "ui/views/view.h"
@@ -17,6 +19,7 @@ class View;
namespace ash {
class SystemTrayItem;
+class TrayPopupItemStyle;
// A view with a chevron ('>') on the right edge. Clicking on the view brings up
// the detailed view of the tray-item that owns it.
@@ -31,11 +34,13 @@ class TrayItemMore : public ActionableView {
void SetImage(const gfx::ImageSkia& image_skia);
void SetAccessibleName(const base::string16& name);
- private:
- // TODO(bruthig): Re-design to inform subclasses when the style changes while
- // avoiding virtual function calls from the constructor.
- void UpdateStyle();
+ protected:
+ virtual std::unique_ptr<TrayPopupItemStyle> CreateStyle() const;
+ // TODO(bruthig) Document me.
tdanderson 2016/09/22 20:44:16 Can you add some documentation (here and perhaps s
bruthig 2016/09/22 21:47:22 Done. WDYT?
+ virtual void UpdateStyle();
+
+ private:
// Overridden from ActionableView.
bool PerformAction(const ui::Event& event) override;

Powered by Google App Engine
This is Rietveld 408576698