Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Side by Side Diff: third_party/WebKit/Source/core/dom/Document.cpp

Issue 2554813002: Make HTMLParserScheduler inherit from ActiveDOMObject
Patch Set: Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/dom/DocumentParser.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2001 Dirk Mueller (mueller@kde.org) 4 * (C) 2001 Dirk Mueller (mueller@kde.org)
5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org)
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All
7 * rights reserved. 7 * rights reserved.
8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. 8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved.
9 * (http://www.torchmobile.com/) 9 * (http://www.torchmobile.com/)
10 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. 10 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved.
(...skipping 5727 matching lines...) Expand 10 before | Expand all | Expand 10 after
5738 void Document::postTask(TaskType, 5738 void Document::postTask(TaskType,
5739 const WebTraceLocation& location, 5739 const WebTraceLocation& location,
5740 std::unique_ptr<ExecutionContextTask> task, 5740 std::unique_ptr<ExecutionContextTask> task,
5741 const String& taskNameForInstrumentation) { 5741 const String& taskNameForInstrumentation) {
5742 m_taskRunner->postTask(location, std::move(task), taskNameForInstrumentation); 5742 m_taskRunner->postTask(location, std::move(task), taskNameForInstrumentation);
5743 } 5743 }
5744 5744
5745 void Document::tasksWereSuspended() { 5745 void Document::tasksWereSuspended() {
5746 scriptRunner()->suspend(); 5746 scriptRunner()->suspend();
5747 5747
5748 if (m_parser)
5749 m_parser->suspendScheduledTasks();
5750 if (m_scriptedAnimationController) 5748 if (m_scriptedAnimationController)
5751 m_scriptedAnimationController->suspend(); 5749 m_scriptedAnimationController->suspend();
5752 } 5750 }
5753 5751
5754 void Document::tasksWereResumed() { 5752 void Document::tasksWereResumed() {
5755 scriptRunner()->resume(); 5753 scriptRunner()->resume();
5756 5754
5757 if (m_parser)
5758 m_parser->resumeScheduledTasks();
5759 if (m_scriptedAnimationController) 5755 if (m_scriptedAnimationController)
5760 m_scriptedAnimationController->resume(); 5756 m_scriptedAnimationController->resume();
5761 5757
5762 MutationObserver::resumeSuspendedObservers(); 5758 MutationObserver::resumeSuspendedObservers();
5763 if (m_domWindow) 5759 if (m_domWindow)
5764 DOMWindowPerformance::performance(*m_domWindow)->resumeSuspendedObservers(); 5760 DOMWindowPerformance::performance(*m_domWindow)->resumeSuspendedObservers();
5765 } 5761 }
5766 5762
5767 bool Document::tasksNeedSuspension() { 5763 bool Document::tasksNeedSuspension() {
5768 Page* page = this->page(); 5764 Page* page = this->page();
(...skipping 774 matching lines...) Expand 10 before | Expand all | Expand 10 after
6543 } 6539 }
6544 6540
6545 void showLiveDocumentInstances() { 6541 void showLiveDocumentInstances() {
6546 WeakDocumentSet& set = liveDocumentSet(); 6542 WeakDocumentSet& set = liveDocumentSet();
6547 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); 6543 fprintf(stderr, "There are %u documents currently alive:\n", set.size());
6548 for (Document* document : set) 6544 for (Document* document : set)
6549 fprintf(stderr, "- Document %p URL: %s\n", document, 6545 fprintf(stderr, "- Document %p URL: %s\n", document,
6550 document->url().getString().utf8().data()); 6546 document->url().getString().utf8().data());
6551 } 6547 }
6552 #endif 6548 #endif
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/dom/DocumentParser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698