| 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_PROCESS_HOST_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_PROCESS_HOST_IMPL_H_ |
| 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_PROCESS_HOST_IMPL_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_PROCESS_HOST_IMPL_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 63 #endif | 63 #endif |
| 64 class PermissionServiceContext; | 64 class PermissionServiceContext; |
| 65 class PeerConnectionTrackerHost; | 65 class PeerConnectionTrackerHost; |
| 66 class RendererMainThread; | 66 class RendererMainThread; |
| 67 class RenderWidgetHelper; | 67 class RenderWidgetHelper; |
| 68 class RenderWidgetHost; | 68 class RenderWidgetHost; |
| 69 class RenderWidgetHostImpl; | 69 class RenderWidgetHostImpl; |
| 70 class RenderWidgetHostViewFrameSubscriber; | 70 class RenderWidgetHostViewFrameSubscriber; |
| 71 class StoragePartition; | 71 class StoragePartition; |
| 72 class StoragePartitionImpl; | 72 class StoragePartitionImpl; |
| 73 |
| 74 namespace mojom { |
| 73 class StoragePartitionService; | 75 class StoragePartitionService; |
| 76 } |
| 74 | 77 |
| 75 typedef base::Thread* (*RendererMainThreadFactoryFunction)( | 78 typedef base::Thread* (*RendererMainThreadFactoryFunction)( |
| 76 const InProcessChildThreadParams& params); | 79 const InProcessChildThreadParams& params); |
| 77 | 80 |
| 78 // Implements a concrete RenderProcessHost for the browser process for talking | 81 // Implements a concrete RenderProcessHost for the browser process for talking |
| 79 // to actual renderer processes (as opposed to mocks). | 82 // to actual renderer processes (as opposed to mocks). |
| 80 // | 83 // |
| 81 // Represents the browser side of the browser <--> renderer communication | 84 // Represents the browser side of the browser <--> renderer communication |
| 82 // channel. There will be one RenderProcessHost per renderer process. | 85 // channel. There will be one RenderProcessHost per renderer process. |
| 83 // | 86 // |
| (...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 297 scoped_ptr<IPC::ChannelProxy> CreateChannelProxy( | 300 scoped_ptr<IPC::ChannelProxy> CreateChannelProxy( |
| 298 const std::string& channel_id); | 301 const std::string& channel_id); |
| 299 | 302 |
| 300 // Creates and adds the IO thread message filters. | 303 // Creates and adds the IO thread message filters. |
| 301 void CreateMessageFilters(); | 304 void CreateMessageFilters(); |
| 302 | 305 |
| 303 // Registers Mojo services to be exposed to the renderer. | 306 // Registers Mojo services to be exposed to the renderer. |
| 304 void RegisterMojoServices(); | 307 void RegisterMojoServices(); |
| 305 | 308 |
| 306 void CreateStoragePartitionService( | 309 void CreateStoragePartitionService( |
| 307 mojo::InterfaceRequest<StoragePartitionService> request); | 310 mojo::InterfaceRequest<mojom::StoragePartitionService> request); |
| 308 | 311 |
| 309 // Control message handlers. | 312 // Control message handlers. |
| 310 void OnShutdownRequest(); | 313 void OnShutdownRequest(); |
| 311 void SuddenTerminationChanged(bool enabled); | 314 void SuddenTerminationChanged(bool enabled); |
| 312 void OnUserMetricsRecordAction(const std::string& action); | 315 void OnUserMetricsRecordAction(const std::string& action); |
| 313 void OnCloseACK(int old_route_id); | 316 void OnCloseACK(int old_route_id); |
| 314 | 317 |
| 315 // Generates a command line to be used to spawn a renderer and appends the | 318 // Generates a command line to be used to spawn a renderer and appends the |
| 316 // results to |*command_line|. | 319 // results to |*command_line|. |
| 317 void AppendRendererCommandLine(base::CommandLine* command_line) const; | 320 void AppendRendererCommandLine(base::CommandLine* command_line) const; |
| (...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 481 | 484 |
| 482 int worker_ref_count_; | 485 int worker_ref_count_; |
| 483 | 486 |
| 484 // Records the time when the process starts surviving for workers for UMA. | 487 // Records the time when the process starts surviving for workers for UMA. |
| 485 base::TimeTicks survive_for_worker_start_time_; | 488 base::TimeTicks survive_for_worker_start_time_; |
| 486 | 489 |
| 487 // Records the maximum # of workers simultaneously hosted in this process | 490 // Records the maximum # of workers simultaneously hosted in this process |
| 488 // for UMA. | 491 // for UMA. |
| 489 int max_worker_count_; | 492 int max_worker_count_; |
| 490 | 493 |
| 491 // Context shared for each PermissionService instance created for this RPH. | 494 // Context shared for each mojom::PermissionService instance created for this |
| 495 // RPH. |
| 492 scoped_ptr<PermissionServiceContext> permission_service_context_; | 496 scoped_ptr<PermissionServiceContext> permission_service_context_; |
| 493 | 497 |
| 494 // This is a set of all subscription targets valuebuffers in the GPU process | 498 // This is a set of all subscription targets valuebuffers in the GPU process |
| 495 // are currently subscribed too. Used to prevent sending unnecessary | 499 // are currently subscribed too. Used to prevent sending unnecessary |
| 496 // ValueState updates. | 500 // ValueState updates. |
| 497 typedef base::hash_set<unsigned int> SubscriptionSet; | 501 typedef base::hash_set<unsigned int> SubscriptionSet; |
| 498 SubscriptionSet subscription_set_; | 502 SubscriptionSet subscription_set_; |
| 499 | 503 |
| 500 // Maintains ValueStates which are not currently subscribed too so we can | 504 // Maintains ValueStates which are not currently subscribed too so we can |
| 501 // pass them to the GpuService if a Valuebuffer ever subscribes to the | 505 // pass them to the GpuService if a Valuebuffer ever subscribes to the |
| (...skipping 19 matching lines...) Expand all Loading... |
| 521 mojo::ScopedMessagePipeHandle in_process_renderer_handle_; | 525 mojo::ScopedMessagePipeHandle in_process_renderer_handle_; |
| 522 | 526 |
| 523 base::WeakPtrFactory<RenderProcessHostImpl> weak_factory_; | 527 base::WeakPtrFactory<RenderProcessHostImpl> weak_factory_; |
| 524 | 528 |
| 525 DISALLOW_COPY_AND_ASSIGN(RenderProcessHostImpl); | 529 DISALLOW_COPY_AND_ASSIGN(RenderProcessHostImpl); |
| 526 }; | 530 }; |
| 527 | 531 |
| 528 } // namespace content | 532 } // namespace content |
| 529 | 533 |
| 530 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_PROCESS_HOST_IMPL_H_ | 534 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_PROCESS_HOST_IMPL_H_ |
| OLD | NEW |