| OLD | NEW |
| 1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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 #ifndef CCScopedThreadProxy_h | 5 #ifndef CCScopedThreadProxy_h |
| 6 #define CCScopedThreadProxy_h | 6 #define CCScopedThreadProxy_h |
| 7 | 7 |
| 8 #include "CCThreadTask.h" | 8 #include "cc/thread_task.h" |
| 9 #include "base/threading/platform_thread.h" | 9 #include "base/threading/platform_thread.h" |
| 10 #include <wtf/OwnPtr.h> | 10 #include <wtf/OwnPtr.h> |
| 11 #include <wtf/PassOwnPtr.h> | 11 #include <wtf/PassOwnPtr.h> |
| 12 #include <wtf/ThreadSafeRefCounted.h> | 12 #include <wtf/ThreadSafeRefCounted.h> |
| 13 | 13 |
| 14 namespace cc { | 14 namespace cc { |
| 15 | 15 |
| 16 // This class is a proxy used to post tasks to an target thread from any other t
hread. The proxy may be shut down at | 16 // This class is a proxy used to post tasks to an target thread from any other t
hread. The proxy may be shut down at |
| 17 // any point from the target thread after which no more tasks posted to the prox
y will run. In other words, all | 17 // any point from the target thread after which no more tasks posted to the prox
y will run. In other words, all |
| 18 // tasks posted via a proxy are scoped to the lifecycle of the proxy. Use this w
hen posting tasks to an object that | 18 // tasks posted via a proxy are scoped to the lifecycle of the proxy. Use this w
hen posting tasks to an object that |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 deref(); | 65 deref(); |
| 66 } | 66 } |
| 67 | 67 |
| 68 CCThread* m_targetThread; | 68 CCThread* m_targetThread; |
| 69 bool m_shutdown; // Only accessed on the target thread | 69 bool m_shutdown; // Only accessed on the target thread |
| 70 }; | 70 }; |
| 71 | 71 |
| 72 } | 72 } |
| 73 | 73 |
| 74 #endif | 74 #endif |
| OLD | NEW |