| 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 | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 45 { | 45 { |
| 46 } | 46 } |
| 47 | 47 |
| 48 WorkerEventQueue::~WorkerEventQueue() | 48 WorkerEventQueue::~WorkerEventQueue() |
| 49 { | 49 { |
| 50 ASSERT(m_eventTaskMap.isEmpty()); | 50 ASSERT(m_eventTaskMap.isEmpty()); |
| 51 } | 51 } |
| 52 | 52 |
| 53 void WorkerEventQueue::trace(Visitor* visitor) | 53 void WorkerEventQueue::trace(Visitor* visitor) |
| 54 { | 54 { |
| 55 #if ENABLE(OILPAN) | |
| 56 visitor->trace(m_executionContext); | 55 visitor->trace(m_executionContext); |
| 57 visitor->trace(m_eventTaskMap); | 56 visitor->trace(m_eventTaskMap); |
| 58 #endif | |
| 59 EventQueue::trace(visitor); | 57 EventQueue::trace(visitor); |
| 60 } | 58 } |
| 61 | 59 |
| 62 class WorkerEventQueue::EventDispatcherTask : public ExecutionContextTask { | 60 class WorkerEventQueue::EventDispatcherTask : public ExecutionContextTask { |
| 63 public: | 61 public: |
| 64 static PassOwnPtr<EventDispatcherTask> create(PassRefPtrWillBeRawPtr<Event>
event, WorkerEventQueue* eventQueue) | 62 static PassOwnPtr<EventDispatcherTask> create(PassRefPtrWillBeRawPtr<Event>
event, WorkerEventQueue* eventQueue) |
| 65 { | 63 { |
| 66 return adoptPtr(new EventDispatcherTask(event, eventQueue)); | 64 return adoptPtr(new EventDispatcherTask(event, eventQueue)); |
| 67 } | 65 } |
| 68 | 66 |
| (...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 139 for (EventTaskMap::iterator it = m_eventTaskMap.begin(); it != m_eventTaskMa
p.end(); ++it) { | 137 for (EventTaskMap::iterator it = m_eventTaskMap.begin(); it != m_eventTaskMa
p.end(); ++it) { |
| 140 Event* event = it->key.get(); | 138 Event* event = it->key.get(); |
| 141 EventDispatcherTask* task = it->value; | 139 EventDispatcherTask* task = it->value; |
| 142 InspectorInstrumentation::didRemoveEvent(event->target(), event); | 140 InspectorInstrumentation::didRemoveEvent(event->target(), event); |
| 143 task->cancel(); | 141 task->cancel(); |
| 144 } | 142 } |
| 145 m_eventTaskMap.clear(); | 143 m_eventTaskMap.clear(); |
| 146 } | 144 } |
| 147 | 145 |
| 148 } | 146 } |
| OLD | NEW |