| OLD | NEW |
| 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 #include "ash/shelf/shelf_view.h" | 5 #include "ash/shelf/shelf_view.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <utility> | 9 #include <utility> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 1868 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1879 ink_drop_->AnimateToState(ink_drop_state); | 1879 ink_drop_->AnimateToState(ink_drop_state); |
| 1880 } | 1880 } |
| 1881 void SnapToActivated() override { ink_drop_->SnapToActivated(); } | 1881 void SnapToActivated() override { ink_drop_->SnapToActivated(); } |
| 1882 void SetHovered(bool is_hovered) override { | 1882 void SetHovered(bool is_hovered) override { |
| 1883 ink_drop_->SetHovered(is_hovered); | 1883 ink_drop_->SetHovered(is_hovered); |
| 1884 } | 1884 } |
| 1885 void SetFocused(bool is_focused) override { | 1885 void SetFocused(bool is_focused) override { |
| 1886 ink_drop_->SetFocused(is_focused); | 1886 ink_drop_->SetFocused(is_focused); |
| 1887 } | 1887 } |
| 1888 | 1888 |
| 1889 bool IsHighlightFadingInOrVisible() const override { |
| 1890 return ink_drop_->IsHighlightFadingInOrVisible(); |
| 1891 } |
| 1892 |
| 1893 void SetShowHighlightOnHover(bool show_highlight_on_hover) override { |
| 1894 ink_drop_->SetShowHighlightOnHover(show_highlight_on_hover); |
| 1895 } |
| 1896 |
| 1897 void SetShowHighlightOnFocus(bool show_highlight_on_focus) override { |
| 1898 ink_drop_->SetShowHighlightOnFocus(show_highlight_on_focus); |
| 1899 } |
| 1900 |
| 1889 std::unique_ptr<views::InkDrop> ink_drop_; | 1901 std::unique_ptr<views::InkDrop> ink_drop_; |
| 1890 std::vector<views::InkDropState> requested_states_; | 1902 std::vector<views::InkDropState> requested_states_; |
| 1891 | 1903 |
| 1892 private: | 1904 private: |
| 1893 DISALLOW_COPY_AND_ASSIGN(InkDropSpy); | 1905 DISALLOW_COPY_AND_ASSIGN(InkDropSpy); |
| 1894 }; | 1906 }; |
| 1895 | 1907 |
| 1896 // A ShelfItemDelegate that returns a menu for the shelf item. | 1908 // A ShelfItemDelegate that returns a menu for the shelf item. |
| 1897 class ListMenuShelfItemDelegate : public ShelfItemDelegate { | 1909 class ListMenuShelfItemDelegate : public ShelfItemDelegate { |
| 1898 public: | 1910 public: |
| (...skipping 1116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3015 EXPECT_EQ(views::InkDropState::ACTIVATED, | 3027 EXPECT_EQ(views::InkDropState::ACTIVATED, |
| 3016 overflow_button_ink_drop_->GetTargetInkDropState()); | 3028 overflow_button_ink_drop_->GetTargetInkDropState()); |
| 3017 EXPECT_THAT(overflow_button_ink_drop_->GetAndResetRequestedStates(), | 3029 EXPECT_THAT(overflow_button_ink_drop_->GetAndResetRequestedStates(), |
| 3018 IsEmpty()); | 3030 IsEmpty()); |
| 3019 | 3031 |
| 3020 ASSERT_TRUE(test_api_->IsShowingOverflowBubble()); | 3032 ASSERT_TRUE(test_api_->IsShowingOverflowBubble()); |
| 3021 } | 3033 } |
| 3022 | 3034 |
| 3023 } // namespace test | 3035 } // namespace test |
| 3024 } // namespace ash | 3036 } // namespace ash |
| OLD | NEW |