Chromium Code Reviews| Index: Source/core/dom/custom/CustomElementSyncMicrotaskQueue.cpp |
| diff --git a/Source/core/dom/custom/CustomElementAsyncImportMicrotaskQueue.cpp b/Source/core/dom/custom/CustomElementSyncMicrotaskQueue.cpp |
| similarity index 77% |
| copy from Source/core/dom/custom/CustomElementAsyncImportMicrotaskQueue.cpp |
| copy to Source/core/dom/custom/CustomElementSyncMicrotaskQueue.cpp |
| index 3fcf748a7fb9fddb89e041f7df2cd196ff95dade..d17695385b0215cfa5502152772e4ed102fed200 100644 |
| --- a/Source/core/dom/custom/CustomElementAsyncImportMicrotaskQueue.cpp |
| +++ b/Source/core/dom/custom/CustomElementSyncMicrotaskQueue.cpp |
| @@ -29,27 +29,25 @@ |
| */ |
| #include "config.h" |
| -#include "core/dom/custom/CustomElementAsyncImportMicrotaskQueue.h" |
| - |
| -#include "core/dom/custom/CustomElementMicrotaskImportStep.h" |
| +#include "core/dom/custom/CustomElementSyncMicrotaskQueue.h" |
| namespace WebCore { |
| -void CustomElementAsyncImportMicrotaskQueue::enqueue(PassOwnPtrWillBeRawPtr<CustomElementMicrotaskImportStep> step) |
| +void CustomElementSyncMicrotaskQueue::enqueue(PassOwnPtrWillBeRawPtr<CustomElementMicrotaskStep> step) |
| { |
| m_queue.append(step); |
| } |
| -void CustomElementAsyncImportMicrotaskQueue::doDispatch() |
| +void CustomElementSyncMicrotaskQueue::doDispatch() |
| { |
| - WillBeHeapVector<OwnPtrWillBeMember<CustomElementMicrotaskStep> > remaining; |
| + unsigned i; |
| - for (unsigned i = 0; i < m_queue.size(); ++i) { |
| + for (i = 0; i < m_queue.size(); ++i) { |
| if (CustomElementMicrotaskStep::Processing == m_queue[i]->process()) |
| - remaining.append(m_queue[i].release()); |
| + break; |
| } |
| - m_queue.swap(remaining); |
| + m_queue.remove(0, i); |
|
dominicc (has gone to gerrit)
2014/06/17 00:29:23
Doesn't queue have a clear or something?
|
| } |
| } // namespace WebCore |