diff options
author | deanm@chromium.org <deanm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-09-10 10:54:06 +0000 |
---|---|---|
committer | deanm@chromium.org <deanm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-09-10 10:54:06 +0000 |
commit | f886b7bf801cbdd2d9e4b31a8f74bc7490922cd4 (patch) | |
tree | 1ab6d88512e17de10c913cc163a31a7d5b2369bd /base/message_loop.h | |
parent | 83c7264800194b0d9ffdce49c57a3fdd5cf6a1a0 (diff) | |
download | chromium_src-f886b7bf801cbdd2d9e4b31a8f74bc7490922cd4.zip chromium_src-f886b7bf801cbdd2d9e4b31a8f74bc7490922cd4.tar.gz chromium_src-f886b7bf801cbdd2d9e4b31a8f74bc7490922cd4.tar.bz2 |
Move a bunch of code from the old to new TLS interface.
Review URL: http://codereview.chromium.org/1660
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1982 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/message_loop.h')
-rw-r--r-- | base/message_loop.h | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/base/message_loop.h b/base/message_loop.h index f4511f8..a65a2e8 100644 --- a/base/message_loop.h +++ b/base/message_loop.h @@ -16,7 +16,6 @@ #include "base/ref_counted.h" #include "base/task.h" #include "base/timer.h" -#include "base/thread_local_storage.h" #if defined(OS_WIN) // We need this to declare base::MessagePumpWin::Dispatcher, which we should @@ -201,13 +200,7 @@ class MessageLoop : public base::MessagePump::Delegate { const std::string& thread_name() const { return thread_name_; } // Returns the MessageLoop object for the current thread, or null if none. - static MessageLoop* current() { - MessageLoop* loop = static_cast<MessageLoop*>(tls_index_.Get()); - // TODO(darin): sadly, we cannot enable this yet since people call us even - // when they have no intention of using us. - //DCHECK(loop) << "Ouch, did you forget to initialize me?"; - return loop; - } + static MessageLoop* current(); // Enables or disables the recursive task processing. This happens in the case // of recursive message loops. Some unwanted message loop may occurs when @@ -347,7 +340,6 @@ class MessageLoop : public base::MessagePump::Delegate { // If message_histogram_ is NULL, this is a no-op. void HistogramEvent(int event); - static TLSSlot tls_index_; static const LinearHistogram::DescriptionPair event_descriptions_[]; static bool enable_histogrammer_; |