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

Side by Side Diff: Source/core/paint/DeprecatedPaintLayer.cpp

Issue 1126883002: Change all one-off lifecycle callers to FrameView::updateLayoutAndStyleForPainting (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 7 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/page/EventHandler.cpp ('k') | Source/core/paint/TextPainterTest.cpp » ('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) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved.
3 * 3 *
4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. 4 * Portions are Copyright (C) 1998 Netscape Communications Corporation.
5 * 5 *
6 * Other contributors: 6 * Other contributors:
7 * Robert O'Callahan <roc+@cs.cmu.edu> 7 * Robert O'Callahan <roc+@cs.cmu.edu>
8 * David Baron <dbaron@fas.harvard.edu> 8 * David Baron <dbaron@fas.harvard.edu>
9 * Christian Biesinger <cbiesinger@web.de> 9 * Christian Biesinger <cbiesinger@web.de>
10 * Randall Jesup <rjesup@wgate.com> 10 * Randall Jesup <rjesup@wgate.com>
(...skipping 1658 matching lines...) Expand 10 before | Expand all | Expand 10 after
1669 1669
1670 // LayoutView should make sure to update layout before entering hit testing 1670 // LayoutView should make sure to update layout before entering hit testing
1671 ASSERT(!layoutObject()->frame()->view()->layoutPending()); 1671 ASSERT(!layoutObject()->frame()->view()->layoutPending());
1672 ASSERT(!layoutObject()->document().layoutView()->needsLayout()); 1672 ASSERT(!layoutObject()->document().layoutView()->needsLayout());
1673 1673
1674 // Start with frameVisibleRect to ensure we include the scrollbars. 1674 // Start with frameVisibleRect to ensure we include the scrollbars.
1675 LayoutRect hitTestArea = frameVisibleRect(layoutObject()); 1675 LayoutRect hitTestArea = frameVisibleRect(layoutObject());
1676 if (request.ignoreClipping()) 1676 if (request.ignoreClipping())
1677 hitTestArea.unite(LayoutRect(layoutObject()->view()->documentRect())); 1677 hitTestArea.unite(LayoutRect(layoutObject()->view()->documentRect()));
1678 1678
1679 // Make sure advance document lifecycle to CompositingClean prior to hit tes ting.
1680 compositor()->updateIfNeededRecursive();
1681 DeprecatedPaintLayer* insideLayer = hitTestLayer(this, 0, result, hitTestAre a, hitTestLocation, false); 1679 DeprecatedPaintLayer* insideLayer = hitTestLayer(this, 0, result, hitTestAre a, hitTestLocation, false);
1682 if (!insideLayer) { 1680 if (!insideLayer) {
1683 // We didn't hit any layer. If we are the root layer and the mouse is -- or just was -- down, 1681 // We didn't hit any layer. If we are the root layer and the mouse is -- or just was -- down,
1684 // return ourselves. We do this so mouse events continue getting deliver ed after a drag has 1682 // return ourselves. We do this so mouse events continue getting deliver ed after a drag has
1685 // exited the WebView, and so hit testing over a scrollbar hits the cont ent document. 1683 // exited the WebView, and so hit testing over a scrollbar hits the cont ent document.
1686 // In addtion, it is possible for the mouse to stay in the document but there is no element. 1684 // In addtion, it is possible for the mouse to stay in the document but there is no element.
1687 // At that time, the events of the mouse should be fired. 1685 // At that time, the events of the mouse should be fired.
1688 LayoutPoint hitPoint = hitTestLocation.point(); 1686 LayoutPoint hitPoint = hitTestLocation.point();
1689 if (!request.isChildFrameHitTest() && ((request.active() || request.rele ase()) || (request.move() && hitTestArea.contains(hitPoint.x(), hitPoint.y()))) && isRootLayer()) { 1687 if (!request.isChildFrameHitTest() && ((request.active() || request.rele ase()) || (request.move() && hitTestArea.contains(hitPoint.x(), hitPoint.y()))) && isRootLayer()) {
1690 layoutObject()->updateHitTestResult(result, toLayoutView(layoutObjec t())->flipForWritingMode(hitTestLocation.point())); 1688 layoutObject()->updateHitTestResult(result, toLayoutView(layoutObjec t())->flipForWritingMode(hitTestLocation.point()));
(...skipping 1286 matching lines...) Expand 10 before | Expand all | Expand 10 after
2977 } 2975 }
2978 } 2976 }
2979 2977
2980 void showLayerTree(const blink::LayoutObject* layoutObject) 2978 void showLayerTree(const blink::LayoutObject* layoutObject)
2981 { 2979 {
2982 if (!layoutObject) 2980 if (!layoutObject)
2983 return; 2981 return;
2984 showLayerTree(layoutObject->enclosingLayer()); 2982 showLayerTree(layoutObject->enclosingLayer());
2985 } 2983 }
2986 #endif 2984 #endif
OLDNEW
« no previous file with comments | « Source/core/page/EventHandler.cpp ('k') | Source/core/paint/TextPainterTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698