OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CONTENT_BROWSER_RENDERER_HOST_RENDER_MESSAGE_FILTER_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_MESSAGE_FILTER_H_ |
6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_MESSAGE_FILTER_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_MESSAGE_FILTER_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 #if defined(OS_MACOSX) | 42 #if defined(OS_MACOSX) |
43 #include "content/common/mac/font_loader.h" | 43 #include "content/common/mac/font_loader.h" |
44 #endif | 44 #endif |
45 | 45 |
46 #if defined(OS_ANDROID) | 46 #if defined(OS_ANDROID) |
47 #include "base/threading/worker_pool.h" | 47 #include "base/threading/worker_pool.h" |
48 #endif | 48 #endif |
49 | 49 |
50 class GURL; | 50 class GURL; |
51 struct FontDescriptor; | 51 struct FontDescriptor; |
52 struct ViewHostMsg_CreateWindow_Params; | |
53 struct ViewHostMsg_CreateWindow_Reply; | |
54 | 52 |
55 namespace base { | 53 namespace base { |
56 class ProcessMetrics; | 54 class ProcessMetrics; |
57 class SharedMemory; | 55 class SharedMemory; |
58 class TaskRunner; | 56 class TaskRunner; |
59 } | 57 } |
60 | 58 |
61 namespace gfx { | 59 namespace gfx { |
62 struct GpuMemoryBufferHandle; | 60 struct GpuMemoryBufferHandle; |
63 } | 61 } |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
116 int render_process_id() const { return render_process_id_; } | 114 int render_process_id() const { return render_process_id_; } |
117 | 115 |
118 protected: | 116 protected: |
119 ~RenderMessageFilter() override; | 117 ~RenderMessageFilter() override; |
120 | 118 |
121 private: | 119 private: |
122 friend class BrowserThread; | 120 friend class BrowserThread; |
123 friend class base::DeleteHelper<RenderMessageFilter>; | 121 friend class base::DeleteHelper<RenderMessageFilter>; |
124 | 122 |
125 void OnGetProcessMemorySizes(size_t* private_bytes, size_t* shared_bytes); | 123 void OnGetProcessMemorySizes(size_t* private_bytes, size_t* shared_bytes); |
126 void OnCreateWindow(const ViewHostMsg_CreateWindow_Params& params, | |
127 ViewHostMsg_CreateWindow_Reply* reply); | |
128 void OnCreateWidget(int opener_id, | 124 void OnCreateWidget(int opener_id, |
129 blink::WebPopupType popup_type, | 125 blink::WebPopupType popup_type, |
130 int* route_id); | 126 int* route_id); |
131 void OnCreateFullscreenWidget(int opener_id, int* route_id); | 127 void OnCreateFullscreenWidget(int opener_id, int* route_id); |
132 | 128 |
133 #if defined(OS_MACOSX) | 129 #if defined(OS_MACOSX) |
134 // Messages for OOP font loading. | 130 // Messages for OOP font loading. |
135 void OnLoadFont(const FontDescriptor& font, IPC::Message* reply_msg); | 131 void OnLoadFont(const FontDescriptor& font, IPC::Message* reply_msg); |
136 void SendLoadFontReply(IPC::Message* reply, FontLoader::Result* result); | 132 void SendLoadFontReply(IPC::Message* reply, FontLoader::Result* result); |
137 #endif | 133 #endif |
138 | 134 |
139 // mojom::RenderMessageFilter: | 135 // mojom::RenderMessageFilter: |
140 void GenerateRoutingID(const GenerateRoutingIDCallback& routing_id) override; | 136 void GenerateRoutingID(const GenerateRoutingIDCallback& routing_id) override; |
| 137 void CreateNewWindow(mojom::CreateNewWindowParamsPtr params, |
| 138 const CreateNewWindowCallback& callback) override; |
141 | 139 |
142 // Message handlers called on the browser IO thread: | 140 // Message handlers called on the browser IO thread: |
143 void OnEstablishGpuChannel(IPC::Message* reply); | 141 void OnEstablishGpuChannel(IPC::Message* reply); |
144 void OnHasGpuProcess(IPC::Message* reply); | 142 void OnHasGpuProcess(IPC::Message* reply); |
145 // Helper callbacks for the message handlers. | 143 // Helper callbacks for the message handlers. |
146 void EstablishChannelCallback(std::unique_ptr<IPC::Message> reply, | 144 void EstablishChannelCallback(std::unique_ptr<IPC::Message> reply, |
147 const IPC::ChannelHandle& channel, | 145 const IPC::ChannelHandle& channel, |
148 const gpu::GPUInfo& gpu_info); | 146 const gpu::GPUInfo& gpu_info); |
149 void GetGpuProcessHandlesCallback( | 147 void GetGpuProcessHandlesCallback( |
150 std::unique_ptr<IPC::Message> reply, | 148 std::unique_ptr<IPC::Message> reply, |
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
252 CacheStorageContextImpl* cache_storage_context_; | 250 CacheStorageContextImpl* cache_storage_context_; |
253 | 251 |
254 base::WeakPtrFactory<RenderMessageFilter> weak_ptr_factory_; | 252 base::WeakPtrFactory<RenderMessageFilter> weak_ptr_factory_; |
255 | 253 |
256 DISALLOW_COPY_AND_ASSIGN(RenderMessageFilter); | 254 DISALLOW_COPY_AND_ASSIGN(RenderMessageFilter); |
257 }; | 255 }; |
258 | 256 |
259 } // namespace content | 257 } // namespace content |
260 | 258 |
261 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_MESSAGE_FILTER_H_ | 259 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_MESSAGE_FILTER_H_ |
OLD | NEW |