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

Side by Side Diff: services/service_manager/public/cpp/service_context_ref.cc

Issue 2884763002: Automated IWYU fix for TaskRunner includes. (Closed)
Patch Set: rebase on r472096 Created 3 years, 7 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 | « services/file/file_service.h ('k') | services/ui/gpu/gpu_main.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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #include "services/service_manager/public/cpp/service_context_ref.h" 5 #include "services/service_manager/public/cpp/service_context_ref.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/memory/ptr_util.h" 8 #include "base/memory/ptr_util.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/single_thread_task_runner.h"
10 #include "base/threading/thread_checker.h" 11 #include "base/threading/thread_checker.h"
11 #include "base/threading/thread_task_runner_handle.h" 12 #include "base/threading/thread_task_runner_handle.h"
12 13
13 namespace service_manager { 14 namespace service_manager {
14 15
15 class ServiceContextRefImpl : public ServiceContextRef { 16 class ServiceContextRefImpl : public ServiceContextRef {
16 public: 17 public:
17 ServiceContextRefImpl( 18 ServiceContextRefImpl(
18 base::WeakPtr<ServiceContextRefFactory> factory, 19 base::WeakPtr<ServiceContextRefFactory> factory,
19 scoped_refptr<base::SingleThreadTaskRunner> service_task_runner) 20 scoped_refptr<base::SingleThreadTaskRunner> service_task_runner)
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 void ServiceContextRefFactory::AddRef() { 75 void ServiceContextRefFactory::AddRef() {
75 ++ref_count_; 76 ++ref_count_;
76 } 77 }
77 78
78 void ServiceContextRefFactory::Release() { 79 void ServiceContextRefFactory::Release() {
79 if (!--ref_count_) 80 if (!--ref_count_)
80 quit_closure_.Run(); 81 quit_closure_.Run();
81 } 82 }
82 83
83 } // namespace service_manager 84 } // namespace service_manager
OLDNEW
« no previous file with comments | « services/file/file_service.h ('k') | services/ui/gpu/gpu_main.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698