Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(813)

Side by Side Diff: device/wake_lock/wake_lock_service_context.h

Issue 2608163003: Change single-interface mojo bindings to use SequencedTaskRunner. (Closed)
Patch Set: Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « device/generic_sensor/sensor_provider_impl.cc ('k') | ipc/ipc_mojo_bootstrap.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 #ifndef DEVICE_WAKE_LOCK_WAKE_LOCK_SERVICE_CONTEXT_H_ 5 #ifndef DEVICE_WAKE_LOCK_WAKE_LOCK_SERVICE_CONTEXT_H_
6 #define DEVICE_WAKE_LOCK_WAKE_LOCK_SERVICE_CONTEXT_H_ 6 #define DEVICE_WAKE_LOCK_WAKE_LOCK_SERVICE_CONTEXT_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <set> 9 #include <set>
10 #include <utility> 10 #include <utility>
11 11
12 #include "base/callback.h" 12 #include "base/callback.h"
13 #include "base/macros.h" 13 #include "base/macros.h"
14 #include "base/memory/ref_counted.h" 14 #include "base/memory/ref_counted.h"
15 #include "base/memory/weak_ptr.h" 15 #include "base/memory/weak_ptr.h"
16 #include "base/sequenced_task_runner.h" 16 #include "base/sequenced_task_runner.h"
17 #include "device/wake_lock/wake_lock_service_impl.h" 17 #include "device/wake_lock/wake_lock_service_impl.h"
18 #include "mojo/public/cpp/bindings/interface_request.h" 18 #include "mojo/public/cpp/bindings/interface_request.h"
19 #include "ui/gfx/native_widget_types.h" 19 #include "ui/gfx/native_widget_types.h"
20 20
21 namespace base {
22 class SingleThreadTaskRunner;
23 }
24
21 namespace device { 25 namespace device {
22 26
23 class PowerSaveBlocker; 27 class PowerSaveBlocker;
24 28
25 class WakeLockServiceContext { 29 class WakeLockServiceContext {
26 public: 30 public:
27 WakeLockServiceContext( 31 WakeLockServiceContext(
28 scoped_refptr<base::SingleThreadTaskRunner> file_task_runner, 32 scoped_refptr<base::SingleThreadTaskRunner> file_task_runner,
29 base::Callback<gfx::NativeView()> native_view_getter); 33 base::Callback<gfx::NativeView()> native_view_getter);
30 ~WakeLockServiceContext(); 34 ~WakeLockServiceContext();
(...skipping 25 matching lines...) Expand all
56 base::Callback<gfx::NativeView()> native_view_getter_; 60 base::Callback<gfx::NativeView()> native_view_getter_;
57 61
58 base::WeakPtrFactory<WakeLockServiceContext> weak_factory_; 62 base::WeakPtrFactory<WakeLockServiceContext> weak_factory_;
59 63
60 DISALLOW_COPY_AND_ASSIGN(WakeLockServiceContext); 64 DISALLOW_COPY_AND_ASSIGN(WakeLockServiceContext);
61 }; 65 };
62 66
63 } // namespace device 67 } // namespace device
64 68
65 #endif // DEVICE_WAKE_LOCK_WAKE_LOCK_SERVICE_CONTEXT_H_ 69 #endif // DEVICE_WAKE_LOCK_WAKE_LOCK_SERVICE_CONTEXT_H_
OLDNEW
« no previous file with comments | « device/generic_sensor/sensor_provider_impl.cc ('k') | ipc/ipc_mojo_bootstrap.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698