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

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

Issue 2401713003: Turn on render throttling for iframes with pending sheets. (Closed)
Patch Set: ojan@ cr. Created 4 years, 1 month 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/frame/FrameView.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 5187 matching lines...) Expand 10 before | Expand all | Expand 10 after
5198 5198
5199 void Document::elementDataCacheClearTimerFired(TimerBase*) { 5199 void Document::elementDataCacheClearTimerFired(TimerBase*) {
5200 m_elementDataCache.clear(); 5200 m_elementDataCache.clear();
5201 } 5201 }
5202 5202
5203 void Document::beginLifecycleUpdatesIfRenderingReady() { 5203 void Document::beginLifecycleUpdatesIfRenderingReady() {
5204 if (!isActive()) 5204 if (!isActive())
5205 return; 5205 return;
5206 if (!isRenderingReady()) 5206 if (!isRenderingReady())
5207 return; 5207 return;
5208 if (LocalFrame* frame = this->frame()) { 5208 view()->beginLifecycleUpdates();
5209 // Avoid pumping frames for the initially empty document.
5210 if (!frame->loader().stateMachine()->committedFirstRealDocumentLoad())
5211 return;
5212 // The compositor will "defer commits" for the main frame until we
5213 // explicitly request them.
5214 if (frame->isMainFrame())
5215 frame->page()->chromeClient().beginLifecycleUpdates();
5216 if (frame->view())
5217 frame->view()->setupRenderThrottling();
5218 }
5219 } 5209 }
5220 5210
5221 Vector<IconURL> Document::iconURLs(int iconTypesMask) { 5211 Vector<IconURL> Document::iconURLs(int iconTypesMask) {
5222 IconURL firstFavicon; 5212 IconURL firstFavicon;
5223 IconURL firstTouchIcon; 5213 IconURL firstTouchIcon;
5224 IconURL firstTouchPrecomposedIcon; 5214 IconURL firstTouchPrecomposedIcon;
5225 Vector<IconURL> secondaryIcons; 5215 Vector<IconURL> secondaryIcons;
5226 5216
5227 // Start from the last child node so that icons seen later take precedence as 5217 // Start from the last child node so that icons seen later take precedence as
5228 // required by the spec. 5218 // required by the spec.
(...skipping 1235 matching lines...) Expand 10 before | Expand all | Expand 10 after
6464 } 6454 }
6465 6455
6466 void showLiveDocumentInstances() { 6456 void showLiveDocumentInstances() {
6467 WeakDocumentSet& set = liveDocumentSet(); 6457 WeakDocumentSet& set = liveDocumentSet();
6468 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); 6458 fprintf(stderr, "There are %u documents currently alive:\n", set.size());
6469 for (Document* document : set) 6459 for (Document* document : set)
6470 fprintf(stderr, "- Document %p URL: %s\n", document, 6460 fprintf(stderr, "- Document %p URL: %s\n", document,
6471 document->url().getString().utf8().data()); 6461 document->url().getString().utf8().data());
6472 } 6462 }
6473 #endif 6463 #endif
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/frame/FrameView.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698