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

Side by Side Diff: extensions/renderer/wake_event_page.h

Issue 1899083003: Convert //extensions/renderer from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase 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
« no previous file with comments | « extensions/renderer/v8_schema_registry.cc ('k') | extensions/renderer/wake_event_page.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 EXTENSIONS_RENDERER_WAKE_EVENT_PAGE_H_ 5 #ifndef EXTENSIONS_RENDERER_WAKE_EVENT_PAGE_H_
6 #define EXTENSIONS_RENDERER_WAKE_EVENT_PAGE_H_ 6 #define EXTENSIONS_RENDERER_WAKE_EVENT_PAGE_H_
7 7
8 #include <memory>
8 #include <string> 9 #include <string>
9 10
10 #include "base/callback.h" 11 #include "base/callback.h"
11 #include "base/containers/scoped_ptr_hash_map.h" 12 #include "base/containers/scoped_ptr_hash_map.h"
12 #include "base/macros.h" 13 #include "base/macros.h"
13 #include "base/memory/ref_counted.h" 14 #include "base/memory/ref_counted.h"
14 #include "base/memory/scoped_ptr.h"
15 #include "base/memory/weak_ptr.h" 15 #include "base/memory/weak_ptr.h"
16 #include "base/synchronization/lock.h" 16 #include "base/synchronization/lock.h"
17 #include "content/public/renderer/render_thread_observer.h" 17 #include "content/public/renderer/render_thread_observer.h"
18 #include "ipc/ipc_sync_message_filter.h" 18 #include "ipc/ipc_sync_message_filter.h"
19 #include "v8/include/v8.h" 19 #include "v8/include/v8.h"
20 20
21 namespace content { 21 namespace content {
22 class RenderThread; 22 class RenderThread;
23 } 23 }
24 24
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 bool OnControlMessageReceived(const IPC::Message& message) override; 96 bool OnControlMessageReceived(const IPC::Message& message) override;
97 97
98 // OnControlMessageReceived handlers: 98 // OnControlMessageReceived handlers:
99 void OnWakeEventPageResponse(int request_id, bool success); 99 void OnWakeEventPageResponse(int request_id, bool success);
100 100
101 // IPC sender. Belongs to the render thread, but thread safe. 101 // IPC sender. Belongs to the render thread, but thread safe.
102 scoped_refptr<IPC::SyncMessageFilter> message_filter_; 102 scoped_refptr<IPC::SyncMessageFilter> message_filter_;
103 103
104 // All in-flight requests, keyed by request ID. Used on multiple threads, so 104 // All in-flight requests, keyed by request ID. Used on multiple threads, so
105 // must be guarded by |requests_lock_|. 105 // must be guarded by |requests_lock_|.
106 base::ScopedPtrHashMap<int, scoped_ptr<RequestData>> requests_; 106 base::ScopedPtrHashMap<int, std::unique_ptr<RequestData>> requests_;
107 107
108 // Lock for |requests_|. 108 // Lock for |requests_|.
109 base::Lock requests_lock_; 109 base::Lock requests_lock_;
110 110
111 DISALLOW_COPY_AND_ASSIGN(WakeEventPage); 111 DISALLOW_COPY_AND_ASSIGN(WakeEventPage);
112 }; 112 };
113 113
114 } // namespace extensions 114 } // namespace extensions
115 115
116 #endif // EXTENSIONS_RENDERER_WAKE_EVENT_PAGE_H_ 116 #endif // EXTENSIONS_RENDERER_WAKE_EVENT_PAGE_H_
OLDNEW
« no previous file with comments | « extensions/renderer/v8_schema_registry.cc ('k') | extensions/renderer/wake_event_page.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698