1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "content/shell/renderer/test_runner/WebTask.h"
8 #include "third_party/WebKit/public/web/WebKit.h"
12 WebTask::WebTask(WebTaskList* list)
15 m_taskList->registerTask(this);
21 m_taskList->unregisterTask(this);
24 WebTaskList::WebTaskList()
28 WebTaskList::~WebTaskList()
33 void WebTaskList::registerTask(WebTask* task)
35 m_tasks.push_back(task);
38 void WebTaskList::unregisterTask(WebTask* task)
40 std::vector<WebTask*>::iterator iter = std::find(m_tasks.begin(), m_tasks.end(), task);
41 if (iter != m_tasks.end())
45 void WebTaskList::revokeAll()
47 while (!m_tasks.empty())
51 } // namespace content