OLD | NEW |
---|---|
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/threading/simple_thread.h" | 5 #include "base/threading/simple_thread.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 #include "base/strings/string_number_conversions.h" | 8 #include "base/strings/string_number_conversions.h" |
9 #include "base/threading/platform_thread.h" | 9 #include "base/threading/platform_thread.h" |
10 #include "base/threading/thread_id_name_manager.h" | |
jar (doing other things)
2013/05/25 00:25:09
nit: Do you still need this include?
dsinclair
2013/05/27 18:50:59
Nope. Done.
| |
10 #include "base/threading/thread_restrictions.h" | 11 #include "base/threading/thread_restrictions.h" |
11 | 12 |
12 namespace base { | 13 namespace base { |
13 | 14 |
14 SimpleThread::SimpleThread(const std::string& name_prefix) | 15 SimpleThread::SimpleThread(const std::string& name_prefix) |
15 : name_prefix_(name_prefix), name_(name_prefix), | 16 : name_prefix_(name_prefix), name_(name_prefix), |
16 thread_(), event_(true, false), tid_(0), joined_(false) { | 17 thread_(), event_(true, false), tid_(0), joined_(false) { |
17 } | 18 } |
18 | 19 |
19 SimpleThread::SimpleThread(const std::string& name_prefix, | 20 SimpleThread::SimpleThread(const std::string& name_prefix, |
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
150 | 151 |
151 // A NULL delegate pointer signals us to quit. | 152 // A NULL delegate pointer signals us to quit. |
152 if (!work) | 153 if (!work) |
153 break; | 154 break; |
154 | 155 |
155 work->Run(); | 156 work->Run(); |
156 } | 157 } |
157 } | 158 } |
158 | 159 |
159 } // namespace base | 160 } // namespace base |
OLD | NEW |