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

Side by Side Diff: Source/core/frame/FrameView.cpp

Issue 898593002: DevTools: use per-LocalFrame instrumenting agents instead of per-Page ones. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: fixed assertion Created 5 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/frame/FrameHost.cpp ('k') | Source/core/frame/LocalFrame.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) 1998, 1999 Torben Weis <weis@kde.org> 2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org>
3 * 1999 Lars Knoll <knoll@kde.org> 3 * 1999 Lars Knoll <knoll@kde.org>
4 * 1999 Antti Koivisto <koivisto@kde.org> 4 * 1999 Antti Koivisto <koivisto@kde.org>
5 * 2000 Dirk Mueller <mueller@kde.org> 5 * 2000 Dirk Mueller <mueller@kde.org>
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved.
7 * (C) 2006 Graham Dennis (graham.dennis@gmail.com) 7 * (C) 2006 Graham Dennis (graham.dennis@gmail.com)
8 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) 8 * (C) 2006 Alexey Proskuryakov (ap@nypop.com)
9 * Copyright (C) 2009 Google Inc. All rights reserved. 9 * Copyright (C) 2009 Google Inc. All rights reserved.
10 * 10 *
(...skipping 1344 matching lines...) Expand 10 before | Expand all | Expand 10 after
1355 setShouldDoFullPaintInvalidationIncludingNonCompositingDescendants(child ); 1355 setShouldDoFullPaintInvalidationIncludingNonCompositingDescendants(child );
1356 } 1356 }
1357 } 1357 }
1358 1358
1359 bool FrameView::scrollContentsFastPath(const IntSize& scrollDelta) 1359 bool FrameView::scrollContentsFastPath(const IntSize& scrollDelta)
1360 { 1360 {
1361 if (!contentsInCompositedLayer() || hasSlowRepaintObjects()) 1361 if (!contentsInCompositedLayer() || hasSlowRepaintObjects())
1362 return false; 1362 return false;
1363 1363
1364 if (!m_viewportConstrainedObjects || m_viewportConstrainedObjects->isEmpty() ) { 1364 if (!m_viewportConstrainedObjects || m_viewportConstrainedObjects->isEmpty() ) {
1365 InspectorInstrumentation::didScroll(page()); 1365 InspectorInstrumentation::didScroll(m_frame.get());
1366 return true; 1366 return true;
1367 } 1367 }
1368 1368
1369 for (const auto& viewportConstrainedObject : *m_viewportConstrainedObjects) { 1369 for (const auto& viewportConstrainedObject : *m_viewportConstrainedObjects) {
1370 RenderObject* renderer = viewportConstrainedObject; 1370 RenderObject* renderer = viewportConstrainedObject;
1371 ASSERT(renderer->style()->hasViewportConstrainedPosition()); 1371 ASSERT(renderer->style()->hasViewportConstrainedPosition());
1372 ASSERT(renderer->hasLayer()); 1372 ASSERT(renderer->hasLayer());
1373 RenderLayer* layer = toRenderBoxModelObject(renderer)->layer(); 1373 RenderLayer* layer = toRenderBoxModelObject(renderer)->layer();
1374 1374
1375 if (layer->isPaintInvalidationContainer()) 1375 if (layer->isPaintInvalidationContainer())
1376 continue; 1376 continue;
1377 1377
1378 if (layer->subtreeIsInvisible()) 1378 if (layer->subtreeIsInvisible())
1379 continue; 1379 continue;
1380 1380
1381 // If the fixed layer has a blur/drop-shadow filter applied on at least one of its parents, we cannot 1381 // If the fixed layer has a blur/drop-shadow filter applied on at least one of its parents, we cannot
1382 // scroll using the fast path, otherwise the outsets of the filter will be moved around the page. 1382 // scroll using the fast path, otherwise the outsets of the filter will be moved around the page.
1383 if (layer->hasAncestorWithFilterOutsets()) 1383 if (layer->hasAncestorWithFilterOutsets())
1384 return false; 1384 return false;
1385 1385
1386 setShouldDoFullPaintInvalidationIncludingNonCompositingDescendants(layer ); 1386 setShouldDoFullPaintInvalidationIncludingNonCompositingDescendants(layer );
1387 } 1387 }
1388 1388
1389 InspectorInstrumentation::didScroll(page()); 1389 InspectorInstrumentation::didScroll(m_frame.get());
1390 return true; 1390 return true;
1391 } 1391 }
1392 1392
1393 void FrameView::scrollContentsSlowPath(const IntRect& updateRect) 1393 void FrameView::scrollContentsSlowPath(const IntRect& updateRect)
1394 { 1394 {
1395 if (contentsInCompositedLayer()) { 1395 if (contentsInCompositedLayer()) {
1396 IntRect updateRect = visibleContentRect(); 1396 IntRect updateRect = visibleContentRect();
1397 ASSERT(renderView()); 1397 ASSERT(renderView());
1398 renderView()->invalidatePaintRectangle(updateRect); 1398 renderView()->invalidatePaintRectangle(updateRect);
1399 } 1399 }
(...skipping 743 matching lines...) Expand 10 before | Expand all | Expand 10 after
2143 2143
2144 if (!wasViewportResized()) 2144 if (!wasViewportResized())
2145 return; 2145 return;
2146 2146
2147 m_lastViewportSize = layoutSize(IncludeScrollbars); 2147 m_lastViewportSize = layoutSize(IncludeScrollbars);
2148 m_lastZoomFactor = renderView->style()->zoom(); 2148 m_lastZoomFactor = renderView->style()->zoom();
2149 2149
2150 m_frame->document()->enqueueResizeEvent(); 2150 m_frame->document()->enqueueResizeEvent();
2151 2151
2152 if (m_frame->isMainFrame()) 2152 if (m_frame->isMainFrame())
2153 InspectorInstrumentation::didResizeMainFrame(m_frame->page()); 2153 InspectorInstrumentation::didResizeMainFrame(m_frame.get());
2154 } 2154 }
2155 2155
2156 void FrameView::postLayoutTimerFired(Timer<FrameView>*) 2156 void FrameView::postLayoutTimerFired(Timer<FrameView>*)
2157 { 2157 {
2158 performPostLayoutTasks(); 2158 performPostLayoutTasks();
2159 } 2159 }
2160 2160
2161 void FrameView::updateCounters() 2161 void FrameView::updateCounters()
2162 { 2162 {
2163 RenderView* view = renderView(); 2163 RenderView* view = renderView();
(...skipping 1878 matching lines...) Expand 10 before | Expand all | Expand 10 after
4042 { 4042 {
4043 Settings* settings = frame().settings(); 4043 Settings* settings = frame().settings();
4044 if (!settings || !settings->rootLayerScrolls()) 4044 if (!settings || !settings->rootLayerScrolls())
4045 return this; 4045 return this;
4046 4046
4047 RenderView* renderView = this->renderView(); 4047 RenderView* renderView = this->renderView();
4048 return renderView ? renderView->scrollableArea() : nullptr; 4048 return renderView ? renderView->scrollableArea() : nullptr;
4049 } 4049 }
4050 4050
4051 } // namespace blink 4051 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/frame/FrameHost.cpp ('k') | Source/core/frame/LocalFrame.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698