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

Side by Side Diff: ppapi/nacl_irt/manifest_service.h

Issue 1864293002: Convert //ppapi to use std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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
OLDNEW
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 #ifndef PPAPI_NACL_IRT_MANIFEST_SERVICE_H_ 5 #ifndef PPAPI_NACL_IRT_MANIFEST_SERVICE_H_
6 #define PPAPI_NACL_IRT_MANIFEST_SERVICE_H_ 6 #define PPAPI_NACL_IRT_MANIFEST_SERVICE_H_
7 7
8 #include <memory>
9
8 #include "base/macros.h" 10 #include "base/macros.h"
9 #include "base/memory/ref_counted.h" 11 #include "base/memory/ref_counted.h"
10 #include "base/memory/scoped_ptr.h"
11 #include "base/synchronization/lock.h" 12 #include "base/synchronization/lock.h"
12 13
13 namespace base { 14 namespace base {
14 class SingleThreadTaskRunner; 15 class SingleThreadTaskRunner;
15 class WaitableEvent; 16 class WaitableEvent;
16 } // namespace base 17 } // namespace base
17 18
18 namespace IPC { 19 namespace IPC {
19 struct ChannelHandle; 20 struct ChannelHandle;
20 class ChannelProxy; 21 class ChannelProxy;
21 class SyncMessageFilter; 22 class SyncMessageFilter;
22 } // namespace IPC 23 } // namespace IPC
23 24
24 namespace ppapi { 25 namespace ppapi {
25 26
26 class ManifestService { 27 class ManifestService {
27 public: 28 public:
28 ManifestService(const IPC::ChannelHandle& handle, 29 ManifestService(const IPC::ChannelHandle& handle,
29 scoped_refptr<base::SingleThreadTaskRunner> io_task_runner, 30 scoped_refptr<base::SingleThreadTaskRunner> io_task_runner,
30 base::WaitableEvent* shutdown_event); 31 base::WaitableEvent* shutdown_event);
31 ~ManifestService(); 32 ~ManifestService();
32 33
33 void StartupInitializationComplete(); 34 void StartupInitializationComplete();
34 bool OpenResource(const char* file, int* fd); 35 bool OpenResource(const char* file, int* fd);
35 36
36 private: 37 private:
37 scoped_ptr<IPC::ChannelProxy> channel_; 38 std::unique_ptr<IPC::ChannelProxy> channel_;
38 scoped_refptr<IPC::SyncMessageFilter> filter_; 39 scoped_refptr<IPC::SyncMessageFilter> filter_;
39 40
40 base::Lock open_resource_lock_; 41 base::Lock open_resource_lock_;
41 42
42 DISALLOW_COPY_AND_ASSIGN(ManifestService); 43 DISALLOW_COPY_AND_ASSIGN(ManifestService);
43 }; 44 };
44 45
45 } // namespace ppapi 46 } // namespace ppapi
46 47
47 #endif // PPAPI_NACL_IRT_MANIFEST_SERVICE_H_ 48 #endif // PPAPI_NACL_IRT_MANIFEST_SERVICE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698