OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "components/user_manager/fake_user_manager.h" | 5 #include "components/user_manager/fake_user_manager.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 | 8 |
9 #include "base/callback.h" | 9 #include "base/callback.h" |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
11 #include "base/sys_info.h" | 11 #include "base/sys_info.h" |
12 #include "base/task_runner.h" | 12 #include "base/task_runner.h" |
13 #include "chromeos/chromeos_switches.h" | 13 #include "chromeos/chromeos_switches.h" |
14 #include "components/user_manager/user_names.h" | 14 #include "components/user_manager/user_names.h" |
15 #include "components/user_manager/user_type.h" | 15 #include "components/user_manager/user_type.h" |
16 | 16 |
17 namespace { | 17 namespace { |
18 | 18 |
19 class FakeTaskRunner : public base::TaskRunner { | 19 class FakeTaskRunner : public base::TaskRunner { |
20 public: | 20 public: |
21 bool PostDelayedTask(const tracked_objects::Location& from_here, | 21 bool PostDelayedTask(const tracked_objects::Location& from_here, |
22 const base::Closure& task, | 22 base::Closure task, |
23 base::TimeDelta delay) override { | 23 base::TimeDelta delay) override { |
24 task.Run(); | 24 std::move(task).Run(); |
25 return true; | 25 return true; |
26 } | 26 } |
27 bool RunsTasksOnCurrentThread() const override { return true; } | 27 bool RunsTasksOnCurrentThread() const override { return true; } |
28 | 28 |
29 protected: | 29 protected: |
30 ~FakeTaskRunner() override {} | 30 ~FakeTaskRunner() override {} |
31 }; | 31 }; |
32 | 32 |
33 } // namespace | 33 } // namespace |
34 | 34 |
(...skipping 317 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
352 NOTIMPLEMENTED(); | 352 NOTIMPLEMENTED(); |
353 return; | 353 return; |
354 } | 354 } |
355 | 355 |
356 bool FakeUserManager::IsValidDefaultUserImageId(int image_index) const { | 356 bool FakeUserManager::IsValidDefaultUserImageId(int image_index) const { |
357 NOTIMPLEMENTED(); | 357 NOTIMPLEMENTED(); |
358 return false; | 358 return false; |
359 } | 359 } |
360 | 360 |
361 } // namespace user_manager | 361 } // namespace user_manager |
OLD | NEW |