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

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

Issue 2535483002: Plumb site engagement to the renderer process. (Closed)
Patch Set: Rebase Created 3 years, 12 months 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
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 474 matching lines...) Expand 10 before | Expand all | Expand 10 after
485 m_templateDocumentHost(nullptr), 485 m_templateDocumentHost(nullptr),
486 m_didAssociateFormControlsTimer( 486 m_didAssociateFormControlsTimer(
487 TaskRunnerHelper::get(TaskType::Internal, this), 487 TaskRunnerHelper::get(TaskType::Internal, this),
488 this, 488 this,
489 &Document::didAssociateFormControlsTimerFired), 489 &Document::didAssociateFormControlsTimerFired),
490 m_timers(TaskRunnerHelper::get(TaskType::Timer, this)->clone()), 490 m_timers(TaskRunnerHelper::get(TaskType::Timer, this)->clone()),
491 m_hasViewportUnits(false), 491 m_hasViewportUnits(false),
492 m_parserSyncPolicy(AllowAsynchronousParsing), 492 m_parserSyncPolicy(AllowAsynchronousParsing),
493 m_nodeCount(0), 493 m_nodeCount(0),
494 m_wouldLoadReason(Created), 494 m_wouldLoadReason(Created),
495 m_passwordCount(0) { 495 m_passwordCount(0),
496 m_engagementLevel(mojom::blink::EngagementLevel::NONE) {
496 if (m_frame) { 497 if (m_frame) {
497 DCHECK(m_frame->page()); 498 DCHECK(m_frame->page());
498 provideContextFeaturesToDocumentFrom(*this, *m_frame->page()); 499 provideContextFeaturesToDocumentFrom(*this, *m_frame->page());
499 500
500 m_fetcher = m_frame->loader().documentLoader()->fetcher(); 501 m_fetcher = m_frame->loader().documentLoader()->fetcher();
501 FrameFetchContext::provideDocumentToContext(m_fetcher->context(), this); 502 FrameFetchContext::provideDocumentToContext(m_fetcher->context(), this);
502 503
503 // TODO(dcheng): Why does this need to check that DOMWindow is non-null? 504 // TODO(dcheng): Why does this need to check that DOMWindow is non-null?
504 CustomElementRegistry* registry = 505 CustomElementRegistry* registry =
505 m_frame->domWindow() ? m_frame->domWindow()->maybeCustomElements() 506 m_frame->domWindow() ? m_frame->domWindow()->maybeCustomElements()
(...skipping 6078 matching lines...) Expand 10 before | Expand all | Expand 10 after
6584 } 6585 }
6585 6586
6586 void showLiveDocumentInstances() { 6587 void showLiveDocumentInstances() {
6587 WeakDocumentSet& set = liveDocumentSet(); 6588 WeakDocumentSet& set = liveDocumentSet();
6588 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); 6589 fprintf(stderr, "There are %u documents currently alive:\n", set.size());
6589 for (Document* document : set) 6590 for (Document* document : set)
6590 fprintf(stderr, "- Document %p URL: %s\n", document, 6591 fprintf(stderr, "- Document %p URL: %s\n", document,
6591 document->url().getString().utf8().data()); 6592 document->url().getString().utf8().data());
6592 } 6593 }
6593 #endif 6594 #endif
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/dom/Document.h ('k') | third_party/WebKit/Source/web/WebLocalFrameImpl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698