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

Side by Side Diff: net/proxy/polling_proxy_config_service.cc

Issue 10066045: RefCounted types should not have public destructors, net/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Deprecated cookiestore fix Created 8 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 | Annotate | Revision Log
« no previous file with comments | « net/proxy/multi_threaded_proxy_resolver.cc ('k') | net/proxy/proxy_config_service_mac.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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "net/proxy/polling_proxy_config_service.h" 5 #include "net/proxy/polling_proxy_config_service.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/location.h" 8 #include "base/location.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/message_loop_proxy.h" 10 #include "base/message_loop_proxy.h"
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 last_poll_time_ = base::TimeTicks::Now(); 90 last_poll_time_ = base::TimeTicks::Now();
91 poll_task_outstanding_ = true; 91 poll_task_outstanding_ = true;
92 poll_task_queued_ = false; 92 poll_task_queued_ = false;
93 base::WorkerPool::PostTask( 93 base::WorkerPool::PostTask(
94 FROM_HERE, 94 FROM_HERE,
95 base::Bind(&Core::PollOnWorkerThread, this, get_config_func_), 95 base::Bind(&Core::PollOnWorkerThread, this, get_config_func_),
96 true); 96 true);
97 } 97 }
98 98
99 private: 99 private:
100 friend class base::RefCountedThreadSafe<Core>;
101 ~Core() {}
102
100 void PollOnWorkerThread(GetConfigFunction func) { 103 void PollOnWorkerThread(GetConfigFunction func) {
101 ProxyConfig config; 104 ProxyConfig config;
102 func(&config); 105 func(&config);
103 106
104 base::AutoLock l(lock_); 107 base::AutoLock l(lock_);
105 if (origin_loop_proxy_) { 108 if (origin_loop_proxy_) {
106 origin_loop_proxy_->PostTask( 109 origin_loop_proxy_->PostTask(
107 FROM_HERE, 110 FROM_HERE,
108 base::Bind(&Core::GetConfigCompleted, this, config)); 111 base::Bind(&Core::GetConfigCompleted, this, config));
109 } 112 }
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
183 186
184 PollingProxyConfigService::~PollingProxyConfigService() { 187 PollingProxyConfigService::~PollingProxyConfigService() {
185 core_->Orphan(); 188 core_->Orphan();
186 } 189 }
187 190
188 void PollingProxyConfigService::CheckForChangesNow() { 191 void PollingProxyConfigService::CheckForChangesNow() {
189 core_->CheckForChangesNow(); 192 core_->CheckForChangesNow();
190 } 193 }
191 194
192 } // namespace net 195 } // namespace net
OLDNEW
« no previous file with comments | « net/proxy/multi_threaded_proxy_resolver.cc ('k') | net/proxy/proxy_config_service_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698