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

Side by Side Diff: base/message_loop.cc

Issue 552004: Style cleanup in preparation for auto-linting base/. (Closed)
Patch Set: Created 10 years, 11 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 | « base/md5.cc ('k') | base/message_pump_glib_unittest.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) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 } 65 }
66 66
67 #endif // defined(OS_WIN) 67 #endif // defined(OS_WIN)
68 68
69 //------------------------------------------------------------------------------ 69 //------------------------------------------------------------------------------
70 70
71 // static 71 // static
72 MessageLoop* MessageLoop::current() { 72 MessageLoop* MessageLoop::current() {
73 // TODO(darin): sadly, we cannot enable this yet since people call us even 73 // TODO(darin): sadly, we cannot enable this yet since people call us even
74 // when they have no intention of using us. 74 // when they have no intention of using us.
75 //DCHECK(loop) << "Ouch, did you forget to initialize me?"; 75 // DCHECK(loop) << "Ouch, did you forget to initialize me?";
76 return lazy_tls_ptr.Pointer()->Get(); 76 return lazy_tls_ptr.Pointer()->Get();
77 } 77 }
78 78
79 MessageLoop::MessageLoop(Type type) 79 MessageLoop::MessageLoop(Type type)
80 : type_(type), 80 : type_(type),
81 nestable_tasks_allowed_(true), 81 nestable_tasks_allowed_(true),
82 exception_restoration_(false), 82 exception_restoration_(false),
83 state_(NULL), 83 state_(NULL),
84 next_sequence_num_(0) { 84 next_sequence_num_(0) {
85 DCHECK(!current()) << "should only have one message loop per thread"; 85 DCHECK(!current()) << "should only have one message loop per thread";
(...skipping 540 matching lines...) Expand 10 before | Expand all | Expand 10 after
626 Watcher *delegate) { 626 Watcher *delegate) {
627 return pump_libevent()->WatchFileDescriptor( 627 return pump_libevent()->WatchFileDescriptor(
628 fd, 628 fd,
629 persistent, 629 persistent,
630 static_cast<base::MessagePumpLibevent::Mode>(mode), 630 static_cast<base::MessagePumpLibevent::Mode>(mode),
631 controller, 631 controller,
632 delegate); 632 delegate);
633 } 633 }
634 634
635 #endif 635 #endif
OLDNEW
« no previous file with comments | « base/md5.cc ('k') | base/message_pump_glib_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698