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

Unified Diff: ui/app_list/views/contents_switcher_view.h

Issue 380613002: Experimental app list: Added a current page indicator to the launcher. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed static initializer. Created 6 years, 5 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
« no previous file with comments | « ui/app_list/views/app_list_main_view.cc ('k') | ui/app_list/views/contents_switcher_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/app_list/views/contents_switcher_view.h
diff --git a/ui/app_list/views/contents_switcher_view.h b/ui/app_list/views/contents_switcher_view.h
index 3f1bbf40ea17bdbbf39d4335ba5565ba9e51ab47..38ba280467f8bd0ae04643582744b75cb41b419c 100644
--- a/ui/app_list/views/contents_switcher_view.h
+++ b/ui/app_list/views/contents_switcher_view.h
@@ -6,6 +6,7 @@
#define UI_APP_LIST_VIEWS_CONTENTS_SWITCHER_VIEW_H_
#include "base/basictypes.h"
+#include "ui/app_list/pagination_model_observer.h"
#include "ui/views/controls/button/button.h"
#include "ui/views/view.h"
@@ -15,7 +16,9 @@ class ContentsView;
// A view that contains buttons to switch the displayed view in the given
// ContentsView.
-class ContentsSwitcherView : public views::View, public views::ButtonListener {
+class ContentsSwitcherView : public views::View,
+ public views::ButtonListener,
+ public PaginationModelObserver {
public:
explicit ContentsSwitcherView(ContentsView* contents_view);
virtual ~ContentsSwitcherView();
@@ -36,8 +39,16 @@ class ContentsSwitcherView : public views::View, public views::ButtonListener {
virtual void ButtonPressed(views::Button* sender,
const ui::Event& event) OVERRIDE;
+ // Overridden from PaginationModelObserver:
+ virtual void TotalPagesChanged() OVERRIDE;
+ virtual void SelectedPageChanged(int old_selected, int new_selected) OVERRIDE;
+ virtual void TransitionStarted() OVERRIDE;
+ virtual void TransitionChanged() OVERRIDE;
+
ContentsView* contents_view_; // Owned by views hierarchy.
views::View* buttons_; // Owned by views hierarchy.
+ // Stores Views owned by views hierarchy.
+ std::vector<views::View*> page_active_indicators_;
DISALLOW_COPY_AND_ASSIGN(ContentsSwitcherView);
};
« no previous file with comments | « ui/app_list/views/app_list_main_view.cc ('k') | ui/app_list/views/contents_switcher_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698