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/message_loop_proxy_impl.h" | 5 #include "base/message_loop_proxy_impl.h" |
6 | 6 |
7 namespace base { | 7 namespace base { |
8 | 8 |
9 MessageLoopProxyImpl::MessageLoopProxyImpl() | 9 MessageLoopProxyImpl::MessageLoopProxyImpl() |
10 : target_message_loop_(MessageLoop::current()) { | 10 : target_message_loop_(MessageLoop::current()) { |
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
86 } | 86 } |
87 | 87 |
88 // MessageLoop::DestructionObserver implementation | 88 // MessageLoop::DestructionObserver implementation |
89 void MessageLoopProxyImpl::WillDestroyCurrentMessageLoop() { | 89 void MessageLoopProxyImpl::WillDestroyCurrentMessageLoop() { |
90 AutoLock lock(message_loop_lock_); | 90 AutoLock lock(message_loop_lock_); |
91 target_message_loop_ = NULL; | 91 target_message_loop_ = NULL; |
92 } | 92 } |
93 | 93 |
94 scoped_refptr<MessageLoopProxy> | 94 scoped_refptr<MessageLoopProxy> |
95 MessageLoopProxy::CreateForCurrentThread() { | 95 MessageLoopProxy::CreateForCurrentThread() { |
96 scoped_refptr<MessageLoopProxy> ret = new MessageLoopProxyImpl(); | 96 scoped_refptr<MessageLoopProxy> ret(new MessageLoopProxyImpl()); |
97 return ret; | 97 return ret; |
98 } | 98 } |
99 | 99 |
100 } // namespace base | 100 } // namespace base |
101 | 101 |
OLD | NEW |