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

Side by Side Diff: third_party/WebKit/Source/core/layout/LayoutView.cpp

Issue 2604073002: Apply offset from the correct graphics layer; simplify code for link highlights. (Closed)
Patch Set: Created 3 years, 11 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 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc.
4 * All rights reserved. 4 * All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 513 matching lines...) Expand 10 before | Expand all | Expand 10 after
524 524
525 return roundedLayoutSize(adjustment); 525 return roundedLayoutSize(adjustment);
526 } 526 }
527 527
528 void LayoutView::absoluteRects(Vector<IntRect>& rects, 528 void LayoutView::absoluteRects(Vector<IntRect>& rects,
529 const LayoutPoint& accumulatedOffset) const { 529 const LayoutPoint& accumulatedOffset) const {
530 rects.append( 530 rects.append(
531 pixelSnappedIntRect(accumulatedOffset, LayoutSize(layer()->size()))); 531 pixelSnappedIntRect(accumulatedOffset, LayoutSize(layer()->size())));
532 } 532 }
533 533
534 void LayoutView::absoluteQuads(Vector<FloatQuad>& quads) const { 534 void LayoutView::absoluteQuads(Vector<FloatQuad>& quads,
535 quads.append(FloatRect(FloatPoint(), FloatSize(layer()->size()))); 535 MapCoordinatesFlags mode) const {
536 quads.append(localToAbsoluteQuad(
537 FloatRect(FloatPoint(), FloatSize(layer()->size())), mode));
536 } 538 }
537 539
538 static LayoutObject* layoutObjectAfterPosition(LayoutObject* object, 540 static LayoutObject* layoutObjectAfterPosition(LayoutObject* object,
539 unsigned offset) { 541 unsigned offset) {
540 if (!object) 542 if (!object)
541 return nullptr; 543 return nullptr;
542 544
543 LayoutObject* child = object->childAt(offset); 545 LayoutObject* child = object->childAt(offset);
544 return child ? child : object->nextInPreOrderAfterChildren(); 546 return child ? child : object->nextInPreOrderAfterChildren();
545 } 547 }
(...skipping 487 matching lines...) Expand 10 before | Expand all | Expand 10 after
1033 bool LayoutView::paintedOutputOfObjectHasNoEffectRegardlessOfSize() const { 1035 bool LayoutView::paintedOutputOfObjectHasNoEffectRegardlessOfSize() const {
1034 // Frame scroll corner is painted using LayoutView as the display item client. 1036 // Frame scroll corner is painted using LayoutView as the display item client.
1035 if (!RuntimeEnabledFeatures::rootLayerScrollingEnabled() && 1037 if (!RuntimeEnabledFeatures::rootLayerScrollingEnabled() &&
1036 (frameView()->horizontalScrollbar() || frameView()->verticalScrollbar())) 1038 (frameView()->horizontalScrollbar() || frameView()->verticalScrollbar()))
1037 return false; 1039 return false;
1038 1040
1039 return LayoutBlockFlow::paintedOutputOfObjectHasNoEffectRegardlessOfSize(); 1041 return LayoutBlockFlow::paintedOutputOfObjectHasNoEffectRegardlessOfSize();
1040 } 1042 }
1041 1043
1042 } // namespace blink 1044 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698