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

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

Issue 2482043002: [ash-md] Updated layout of Brightness and Audio system menu rows to the material design spec. (Closed)
Patch Set: Fixed the volume slider to transition to the detailed view on <return> keypress. Created 4 years, 1 month 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
« no previous file with comments | « ash/common/system/chromeos/brightness/tray_brightness.cc ('k') | ash/common/system/tray/actionable_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/common/system/tray/actionable_view.h
diff --git a/ash/common/system/tray/actionable_view.h b/ash/common/system/tray/actionable_view.h
index 1dd60b4b41b68d3e63f6cf764c9ad286868baf64..8d653c4379563587ff1e11d911caa5a96e385f49 100644
--- a/ash/common/system/tray/actionable_view.h
+++ b/ash/common/system/tray/actionable_view.h
@@ -80,6 +80,22 @@ class ASH_EXPORT ActionableView : public views::ButtonListener,
DISALLOW_COPY_AND_ASSIGN(ActionableView);
};
+// An ActionableView that can be used with a ButtonListener instead of having to
+// extend ActionableView and override PerformAction().
+class ASH_EXPORT ButtonListenerActionableView : public ActionableView {
+ public:
+ ButtonListenerActionableView(SystemTrayItem* owner,
+ views::ButtonListener* listener);
+
+ // ActionableView:
+ bool PerformAction(const ui::Event& event) override;
+
+ private:
+ views::ButtonListener* listener_;
+
+ DISALLOW_COPY_AND_ASSIGN(ButtonListenerActionableView);
+};
+
} // namespace ash
#endif // ASH_COMMON_SYSTEM_TRAY_ACTIONABLE_VIEW_H_
« no previous file with comments | « ash/common/system/chromeos/brightness/tray_brightness.cc ('k') | ash/common/system/tray/actionable_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698