Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef UI_APP_LIST_VIEWS_EXPAND_ARROW_VIEW_H_ | |
| 6 #define UI_APP_LIST_VIEWS_EXPAND_ARROW_VIEW_H_ | |
| 7 | |
| 8 #include "ui/views/controls/button/button.h" | |
| 9 #include "ui/views/controls/button/custom_button.h" | |
| 10 | |
| 11 namespace views { | |
| 12 class ImageView; | |
| 13 class InkDrop; | |
| 14 class InkDropMask; | |
| 15 class InkDropRipple; | |
| 16 class InkDropHighlight; | |
| 17 } // namespace views | |
| 18 | |
| 19 namespace app_list { | |
| 20 | |
| 21 class AppListView; | |
| 22 class ContentsView; | |
| 23 | |
| 24 // A tile item for the expand arrow on the start page. | |
| 25 class ExpandArrowView : public views::CustomButton, | |
| 26 public views::ButtonListener { | |
| 27 public: | |
| 28 ExpandArrowView(ContentsView* contents_view, AppListView* app_list_view); | |
| 29 | |
|
xiyuan
2017/06/27 19:57:06
nit: get rid of this empty line
weidongg
2017/06/27 20:41:48
Done.
| |
| 30 ~ExpandArrowView() override; | |
| 31 | |
| 32 // Overridden from views::ButtonListener: | |
| 33 void ButtonPressed(views::Button* sender, const ui::Event& event) override; | |
| 34 | |
| 35 // Overridden from views::View: | |
| 36 gfx::Size CalculatePreferredSize() const override; | |
| 37 void Layout() override; | |
| 38 | |
| 39 protected: | |
|
xiyuan
2017/06/27 19:57:06
I am okay to just make those below public.
weidongg
2017/06/27 20:41:50
Done.
| |
| 40 // Overridden from views::InkDropHost: | |
| 41 std::unique_ptr<views::InkDrop> CreateInkDrop() override; | |
| 42 std::unique_ptr<views::InkDropMask> CreateInkDropMask() const override; | |
| 43 std::unique_ptr<views::InkDropRipple> CreateInkDropRipple() const override; | |
| 44 std::unique_ptr<views::InkDropHighlight> CreateInkDropHighlight() | |
| 45 const override; | |
| 46 | |
| 47 private: | |
| 48 ContentsView* contents_view_; | |
|
xiyuan
2017/06/27 19:57:06
nit: This can be a const ptr too.
i.e.
ContentsV
weidongg
2017/06/27 20:41:48
Done.
| |
| 49 AppListView* const app_list_view_; // Owned by the views hierarchy. | |
| 50 | |
| 51 views::ImageView* icon_; | |
| 52 | |
| 53 DISALLOW_COPY_AND_ASSIGN(ExpandArrowView); | |
| 54 }; | |
| 55 | |
| 56 } // namespace app_list | |
| 57 | |
| 58 #endif // UI_APP_LIST_VIEWS_EXPAND_ARROW_VIEW_H_ | |
| OLD | NEW |