OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
211 ASSERT(executionContext->isContextThread()); | 211 ASSERT(executionContext->isContextThread()); |
212 if (callback) | 212 if (callback) |
213 executionContext->postTask(adoptPtr(new DispatchCallbackPtrArgTask<CB, C
BArg>(callback, arg))); | 213 executionContext->postTask(adoptPtr(new DispatchCallbackPtrArgTask<CB, C
BArg>(callback, arg))); |
214 } | 214 } |
215 | 215 |
216 template <typename CB, typename CBArg> | 216 template <typename CB, typename CBArg> |
217 void DOMFileSystem::scheduleCallback(ExecutionContext* executionContext, CB* cal
lback, const HeapVector<CBArg>& arg) | 217 void DOMFileSystem::scheduleCallback(ExecutionContext* executionContext, CB* cal
lback, const HeapVector<CBArg>& arg) |
218 { | 218 { |
219 ASSERT(executionContext->isContextThread()); | 219 ASSERT(executionContext->isContextThread()); |
220 if (callback) | 220 if (callback) |
221 executionContext->postTask(adoptPtr(new DispatchCallbackNonPtrArgTask<CB
, PersistentHeapVector<CBArg> >(callback, arg))); | 221 executionContext->postTask(adoptPtr(new DispatchCallbackNonPtrArgTask<CB
, PersistentHeapVector<CBArg>>(callback, arg))); |
222 } | 222 } |
223 | 223 |
224 template <typename CB, typename CBArg> | 224 template <typename CB, typename CBArg> |
225 void DOMFileSystem::scheduleCallback(ExecutionContext* executionContext, CB* cal
lback, const CBArg& arg) | 225 void DOMFileSystem::scheduleCallback(ExecutionContext* executionContext, CB* cal
lback, const CBArg& arg) |
226 { | 226 { |
227 ASSERT(executionContext->isContextThread()); | 227 ASSERT(executionContext->isContextThread()); |
228 if (callback) | 228 if (callback) |
229 executionContext->postTask(adoptPtr(new DispatchCallbackNonPtrArgTask<CB
, CBArg>(callback, arg))); | 229 executionContext->postTask(adoptPtr(new DispatchCallbackNonPtrArgTask<CB
, CBArg>(callback, arg))); |
230 } | 230 } |
231 | 231 |
232 template <typename CB, typename CBArg> | 232 template <typename CB, typename CBArg> |
233 void DOMFileSystem::scheduleCallback(ExecutionContext* executionContext, CB* cal
lback, const Member<CBArg>& arg) | 233 void DOMFileSystem::scheduleCallback(ExecutionContext* executionContext, CB* cal
lback, const Member<CBArg>& arg) |
234 { | 234 { |
235 ASSERT(executionContext->isContextThread()); | 235 ASSERT(executionContext->isContextThread()); |
236 if (callback) | 236 if (callback) |
237 executionContext->postTask(adoptPtr(new DispatchCallbackNonPtrArgTask<CB
, Persistent<CBArg> >(callback, arg))); | 237 executionContext->postTask(adoptPtr(new DispatchCallbackNonPtrArgTask<CB
, Persistent<CBArg>>(callback, arg))); |
238 } | 238 } |
239 | 239 |
240 template <typename CB> | 240 template <typename CB> |
241 void DOMFileSystem::scheduleCallback(ExecutionContext* executionContext, CB* cal
lback) | 241 void DOMFileSystem::scheduleCallback(ExecutionContext* executionContext, CB* cal
lback) |
242 { | 242 { |
243 ASSERT(executionContext->isContextThread()); | 243 ASSERT(executionContext->isContextThread()); |
244 if (callback) | 244 if (callback) |
245 executionContext->postTask(adoptPtr(new DispatchCallbackNoArgTask<CB>(ca
llback))); | 245 executionContext->postTask(adoptPtr(new DispatchCallbackNoArgTask<CB>(ca
llback))); |
246 } | 246 } |
247 | 247 |
248 } // namespace blink | 248 } // namespace blink |
249 | 249 |
250 #endif // DOMFileSystem_h | 250 #endif // DOMFileSystem_h |
OLD | NEW |