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

Side by Side Diff: content/browser/renderer_host/render_process_host_impl.cc

Issue 750633003: Implement HasPermission() method in PermissionService. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: include content_common_mojo_bindings.gypi in content.gyp Created 6 years 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 (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 // Represents the browser side of the browser <--> renderer communication 5 // Represents the browser side of the browser <--> renderer communication
6 // channel. There will be one RenderProcessHost per renderer process. 6 // channel. There will be one RenderProcessHost per renderer process.
7 7
8 #include "content/browser/renderer_host/render_process_host_impl.h" 8 #include "content/browser/renderer_host/render_process_host_impl.h"
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 435 matching lines...) Expand 10 before | Expand all | Expand 10 after
446 browser_context_(browser_context), 446 browser_context_(browser_context),
447 storage_partition_impl_(storage_partition_impl), 447 storage_partition_impl_(storage_partition_impl),
448 sudden_termination_allowed_(true), 448 sudden_termination_allowed_(true),
449 ignore_input_events_(false), 449 ignore_input_events_(false),
450 is_isolated_guest_(is_isolated_guest), 450 is_isolated_guest_(is_isolated_guest),
451 gpu_observer_registered_(false), 451 gpu_observer_registered_(false),
452 delayed_cleanup_needed_(false), 452 delayed_cleanup_needed_(false),
453 within_process_died_observer_(false), 453 within_process_died_observer_(false),
454 power_monitor_broadcaster_(this), 454 power_monitor_broadcaster_(this),
455 worker_ref_count_(0), 455 worker_ref_count_(0),
456 permission_service_context_(new PermissionServiceContext(nullptr)), 456 permission_service_context_(new PermissionServiceContext(this)),
457 weak_factory_(this) { 457 weak_factory_(this) {
458 widget_helper_ = new RenderWidgetHelper(); 458 widget_helper_ = new RenderWidgetHelper();
459 459
460 ChildProcessSecurityPolicyImpl::GetInstance()->Add(GetID()); 460 ChildProcessSecurityPolicyImpl::GetInstance()->Add(GetID());
461 461
462 CHECK(!g_exited_main_message_loop); 462 CHECK(!g_exited_main_message_loop);
463 RegisterHost(GetID(), this); 463 RegisterHost(GetID(), this);
464 g_all_hosts.Get().set_check_on_null_data(true); 464 g_all_hosts.Get().set_check_on_null_data(true);
465 // Initialize |child_process_activity_time_| to a reasonable value. 465 // Initialize |child_process_activity_time_| to a reasonable value.
466 mark_child_process_activity_time(); 466 mark_child_process_activity_time();
(...skipping 1803 matching lines...) Expand 10 before | Expand all | Expand 10 after
2270 2270
2271 void RenderProcessHostImpl::DecrementWorkerRefCount() { 2271 void RenderProcessHostImpl::DecrementWorkerRefCount() {
2272 DCHECK_CURRENTLY_ON(BrowserThread::UI); 2272 DCHECK_CURRENTLY_ON(BrowserThread::UI);
2273 DCHECK_GT(worker_ref_count_, 0); 2273 DCHECK_GT(worker_ref_count_, 0);
2274 --worker_ref_count_; 2274 --worker_ref_count_;
2275 if (worker_ref_count_ == 0) 2275 if (worker_ref_count_ == 0)
2276 Cleanup(); 2276 Cleanup();
2277 } 2277 }
2278 2278
2279 } // namespace content 2279 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698