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

Side by Side Diff: base/message_loop.cc

Issue 12088031: Revert 179189 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 7 years, 10 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 | « base/message_loop.h ('k') | base/test/test_support_android.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) 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 #include "base/message_loop.h" 5 #include "base/message_loop.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after
244 // DCHECK(loop) << "Ouch, did you forget to initialize me?"; 244 // DCHECK(loop) << "Ouch, did you forget to initialize me?";
245 return lazy_tls_ptr.Pointer()->Get(); 245 return lazy_tls_ptr.Pointer()->Get();
246 } 246 }
247 247
248 // static 248 // static
249 void MessageLoop::EnableHistogrammer(bool enable) { 249 void MessageLoop::EnableHistogrammer(bool enable) {
250 enable_histogrammer_ = enable; 250 enable_histogrammer_ = enable;
251 } 251 }
252 252
253 // static 253 // static
254 bool MessageLoop::InitMessagePumpForUIFactory(MessagePumpFactory* factory) { 254 void MessageLoop::InitMessagePumpForUIFactory(MessagePumpFactory* factory) {
255 if (message_pump_for_ui_factory_) 255 DCHECK(!message_pump_for_ui_factory_);
256 return false;
257
258 message_pump_for_ui_factory_ = factory; 256 message_pump_for_ui_factory_ = factory;
259 return true;
260 } 257 }
261 258
262 void MessageLoop::AddDestructionObserver( 259 void MessageLoop::AddDestructionObserver(
263 DestructionObserver* destruction_observer) { 260 DestructionObserver* destruction_observer) {
264 DCHECK_EQ(this, current()); 261 DCHECK_EQ(this, current());
265 destruction_observers_.AddObserver(destruction_observer); 262 destruction_observers_.AddObserver(destruction_observer);
266 } 263 }
267 264
268 void MessageLoop::RemoveDestructionObserver( 265 void MessageLoop::RemoveDestructionObserver(
269 DestructionObserver* destruction_observer) { 266 DestructionObserver* destruction_observer) {
(...skipping 536 matching lines...) Expand 10 before | Expand all | Expand 10 after
806 Watcher *delegate) { 803 Watcher *delegate) {
807 return pump_libevent()->WatchFileDescriptor( 804 return pump_libevent()->WatchFileDescriptor(
808 fd, 805 fd,
809 persistent, 806 persistent,
810 mode, 807 mode,
811 controller, 808 controller,
812 delegate); 809 delegate);
813 } 810 }
814 811
815 #endif 812 #endif
OLDNEW
« no previous file with comments | « base/message_loop.h ('k') | base/test/test_support_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698