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

Unified Diff: Source/platform/CrossThreadCopier.h

Issue 670113002: Oilpan: A thread that is not attached to Oilpan shouldn't create a CrossThreadPersistent Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/modules/webaudio/ScriptProcessorNode.cpp ('k') | Source/platform/audio/HRTFDatabaseLoader.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/CrossThreadCopier.h
diff --git a/Source/platform/CrossThreadCopier.h b/Source/platform/CrossThreadCopier.h
index a1f593e34c48edfa5132b28b7c595b0961e68641..866da405783f57f536381bdc1d240b81186a0208 100644
--- a/Source/platform/CrossThreadCopier.h
+++ b/Source/platform/CrossThreadCopier.h
@@ -41,6 +41,7 @@
#include "wtf/RefPtr.h"
#include "wtf/ThreadSafeRefCounted.h"
#include "wtf/TypeTraits.h"
+#include "wtf/UnretainedPtr.h"
namespace blink {
@@ -152,6 +153,14 @@ namespace blink {
}
};
+ template<typename T> struct CrossThreadCopierBase<false, false, true, UnretainedPtr<T> > {
+ typedef RawPtr<T> Type;
+ static Type copy(const Type& ptr)
+ {
+ return ptr;
+ }
+ };
+
template<typename T> struct CrossThreadCopierBase<false, false, true, Member<T> > {
typedef RawPtr<T> Type;
static Type copy(const Member<T>& ptr)
@@ -174,6 +183,7 @@ namespace blink {
|| WTF::IsSubclassOfTemplate<typename WTF::RemoveTemplate<T, PassRefPtr>::Type, ThreadSafeRefCounted>::value,
WTF::IsSubclassOfTemplate<typename WTF::RemovePointer<T>::Type, GarbageCollected>::value
|| WTF::IsSubclassOfTemplate<typename WTF::RemoveTemplate<T, RawPtr>::Type, GarbageCollected>::value
+ || WTF::IsSubclassOfTemplate<typename WTF::RemoveTemplate<T, UnretainedPtr>::Type, GarbageCollected>::value
|| WTF::IsSubclassOfTemplate<typename WTF::RemoveTemplate<T, Member>::Type, GarbageCollected>::value
|| WTF::IsSubclassOfTemplate<typename WTF::RemoveTemplate<T, WeakMember>::Type, GarbageCollected>::value,
T> {
« no previous file with comments | « Source/modules/webaudio/ScriptProcessorNode.cpp ('k') | Source/platform/audio/HRTFDatabaseLoader.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698