| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 Google Inc. All rights reserved. |
| 3 * Copyright (C) 2013 Samsung Electronics. All rights reserved. | 3 * Copyright (C) 2013 Samsung Electronics. All rights reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
| 7 * met: | 7 * met: |
| 8 * | 8 * |
| 9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 29 matching lines...) Expand all Loading... |
| 40 #include "modules/filesystem/EntryCallback.h" | 40 #include "modules/filesystem/EntryCallback.h" |
| 41 #include "modules/filesystem/EntrySync.h" | 41 #include "modules/filesystem/EntrySync.h" |
| 42 #include "modules/filesystem/ErrorCallback.h" | 42 #include "modules/filesystem/ErrorCallback.h" |
| 43 #include "modules/filesystem/FileEntry.h" | 43 #include "modules/filesystem/FileEntry.h" |
| 44 #include "modules/filesystem/FileSystemCallback.h" | 44 #include "modules/filesystem/FileSystemCallback.h" |
| 45 #include "modules/filesystem/MetadataCallback.h" | 45 #include "modules/filesystem/MetadataCallback.h" |
| 46 #include "platform/heap/Handle.h" | 46 #include "platform/heap/Handle.h" |
| 47 #include "wtf/PassRefPtr.h" | 47 #include "wtf/PassRefPtr.h" |
| 48 #include "wtf/RefCounted.h" | 48 #include "wtf/RefCounted.h" |
| 49 | 49 |
| 50 namespace WebCore { | 50 namespace blink { |
| 51 | 51 |
| 52 template <typename ResultType, typename CallbackArg> | 52 template <typename ResultType, typename CallbackArg> |
| 53 struct HelperResultType { | 53 struct HelperResultType { |
| 54 DISALLOW_ALLOCATION(); | 54 DISALLOW_ALLOCATION(); |
| 55 public: | 55 public: |
| 56 typedef ResultType* ReturnType; | 56 typedef ResultType* ReturnType; |
| 57 typedef Persistent<ResultType> StorageType; | 57 typedef Persistent<ResultType> StorageType; |
| 58 | 58 |
| 59 static ReturnType createFromCallbackArg(CallbackArg argument) | 59 static ReturnType createFromCallbackArg(CallbackArg argument) |
| 60 { | 60 { |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 164 } | 164 } |
| 165 | 165 |
| 166 void trace(Visitor*) { } | 166 void trace(Visitor*) { } |
| 167 }; | 167 }; |
| 168 | 168 |
| 169 typedef SyncCallbackHelper<EntryCallback, Entry*, EntrySync> EntrySyncCallbackHe
lper; | 169 typedef SyncCallbackHelper<EntryCallback, Entry*, EntrySync> EntrySyncCallbackHe
lper; |
| 170 typedef SyncCallbackHelper<MetadataCallback, Metadata*, Metadata> MetadataSyncCa
llbackHelper; | 170 typedef SyncCallbackHelper<MetadataCallback, Metadata*, Metadata> MetadataSyncCa
llbackHelper; |
| 171 typedef SyncCallbackHelper<VoidCallback, EmptyType*, EmptyType> VoidSyncCallback
Helper; | 171 typedef SyncCallbackHelper<VoidCallback, EmptyType*, EmptyType> VoidSyncCallback
Helper; |
| 172 typedef SyncCallbackHelper<FileSystemCallback, DOMFileSystem*, DOMFileSystemSync
> FileSystemSyncCallbackHelper; | 172 typedef SyncCallbackHelper<FileSystemCallback, DOMFileSystem*, DOMFileSystemSync
> FileSystemSyncCallbackHelper; |
| 173 | 173 |
| 174 } // namespace WebCore | 174 } // namespace blink |
| 175 | 175 |
| 176 #endif // SyncCallbackHelper_h | 176 #endif // SyncCallbackHelper_h |
| OLD | NEW |