| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 <memory> | 5 #include <memory> |
| 6 | 6 |
| 7 #include "base/macros.h" | 7 #include "base/macros.h" |
| 8 #include "base/memory/ptr_util.h" | 8 #include "base/memory/ptr_util.h" |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
| (...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 139 int button_index) override { | 139 int button_index) override { |
| 140 // For this test, this method should not be invoked. | 140 // For this test, this method should not be invoked. |
| 141 NOTREACHED(); | 141 NOTREACHED(); |
| 142 } | 142 } |
| 143 | 143 |
| 144 void ClickOnSettingsButton(const std::string& notification_id) override { | 144 void ClickOnSettingsButton(const std::string& notification_id) override { |
| 145 // For this test, this method should not be invoked. | 145 // For this test, this method should not be invoked. |
| 146 NOTREACHED(); | 146 NOTREACHED(); |
| 147 } | 147 } |
| 148 | 148 |
| 149 void UpdateNotificationSize(const std::string& notification_id) override { |
| 150 // For this test, this method should not be invoked. |
| 151 NOTREACHED(); |
| 152 } |
| 153 |
| 149 bool IsRemoved(const std::string& notification_id) const { | 154 bool IsRemoved(const std::string& notification_id) const { |
| 150 return (removed_ids_.find(notification_id) != removed_ids_.end()); | 155 return (removed_ids_.find(notification_id) != removed_ids_.end()); |
| 151 } | 156 } |
| 152 | 157 |
| 153 private: | 158 private: |
| 154 std::set<std::string> removed_ids_; | 159 std::set<std::string> removed_ids_; |
| 155 | 160 |
| 156 DISALLOW_COPY_AND_ASSIGN(TestMessageCenterController); | 161 DISALLOW_COPY_AND_ASSIGN(TestMessageCenterController); |
| 157 }; | 162 }; |
| 158 | 163 |
| (...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 363 text_input_client.set_text_input_type(ui::TEXT_INPUT_TYPE_TEXT); | 368 text_input_client.set_text_input_type(ui::TEXT_INPUT_TYPE_TEXT); |
| 364 | 369 |
| 365 EXPECT_FALSE(controller()->IsRemoved(notification_id)); | 370 EXPECT_FALSE(controller()->IsRemoved(notification_id)); |
| 366 PerformKeyEvents(ui::VKEY_BACK); | 371 PerformKeyEvents(ui::VKEY_BACK); |
| 367 EXPECT_FALSE(controller()->IsRemoved(notification_id)); | 372 EXPECT_FALSE(controller()->IsRemoved(notification_id)); |
| 368 | 373 |
| 369 input_method->SetFocusedTextInputClient(nullptr); | 374 input_method->SetFocusedTextInputClient(nullptr); |
| 370 } | 375 } |
| 371 | 376 |
| 372 } // namespace message_center | 377 } // namespace message_center |
| OLD | NEW |