| 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 2034 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2045 | 2045 |
| 2046 // ShelfMenuModel: | 2046 // ShelfMenuModel: |
| 2047 bool IsCommandActive(int command_id) const override { return false; } | 2047 bool IsCommandActive(int command_id) const override { return false; } |
| 2048 | 2048 |
| 2049 // ui::SimpleMenuModel::Delegate: | 2049 // ui::SimpleMenuModel::Delegate: |
| 2050 bool IsCommandIdChecked(int command_id) const override { return false; } | 2050 bool IsCommandIdChecked(int command_id) const override { return false; } |
| 2051 bool IsCommandIdEnabled(int command_id) const override { | 2051 bool IsCommandIdEnabled(int command_id) const override { |
| 2052 return command_id != 0; | 2052 return command_id != 0; |
| 2053 } | 2053 } |
| 2054 bool GetAcceleratorForCommandId(int command_id, | 2054 bool GetAcceleratorForCommandId(int command_id, |
| 2055 ui::Accelerator* accelerator) override { | 2055 ui::Accelerator* accelerator) const override { |
| 2056 return false; | 2056 return false; |
| 2057 } | 2057 } |
| 2058 void ExecuteCommand(int command_id, int event_flags) override {} | 2058 void ExecuteCommand(int command_id, int event_flags) override {} |
| 2059 | 2059 |
| 2060 DISALLOW_COPY_AND_ASSIGN(TestShelfMenuModel); | 2060 DISALLOW_COPY_AND_ASSIGN(TestShelfMenuModel); |
| 2061 }; | 2061 }; |
| 2062 | 2062 |
| 2063 // A ShelfItemDelegate that returns a menu for the shelf item. | 2063 // A ShelfItemDelegate that returns a menu for the shelf item. |
| 2064 class ListMenuShelfItemDelegate : public TestShelfItemDelegate { | 2064 class ListMenuShelfItemDelegate : public TestShelfItemDelegate { |
| 2065 public: | 2065 public: |
| (...skipping 525 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2591 test_api_->CloseMenu(); | 2591 test_api_->CloseMenu(); |
| 2592 EXPECT_EQ(views::InkDropState::HIDDEN, | 2592 EXPECT_EQ(views::InkDropState::HIDDEN, |
| 2593 browser_button_ink_drop_->GetTargetInkDropState()); | 2593 browser_button_ink_drop_->GetTargetInkDropState()); |
| 2594 EXPECT_THAT(browser_button_ink_drop_->GetAndResetRequestedStates(), | 2594 EXPECT_THAT(browser_button_ink_drop_->GetAndResetRequestedStates(), |
| 2595 ElementsAre(views::InkDropState::ACTIVATED, | 2595 ElementsAre(views::InkDropState::ACTIVATED, |
| 2596 views::InkDropState::DEACTIVATED)); | 2596 views::InkDropState::DEACTIVATED)); |
| 2597 } | 2597 } |
| 2598 | 2598 |
| 2599 } // namespace test | 2599 } // namespace test |
| 2600 } // namespace ash | 2600 } // namespace ash |
| OLD | NEW |