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/rendering/RenderBox.cpp

Issue 180803012: Disable some compositing state asserts seen on Mac builds (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 9 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
« no previous file with comments | « no previous file | Source/core/rendering/RenderLayerScrollableArea.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) 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) 2005 Allan Sandfeld Jensen (kde@carewolf.com) 4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com)
5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com)
6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv ed. 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv ed.
7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. 7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved.
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 456 matching lines...) Expand 10 before | Expand all | Expand 10 after
467 // Forbid autoscrolls when scrollbars are off, but permits other programmati c scrolls, 467 // Forbid autoscrolls when scrollbars are off, but permits other programmati c scrolls,
468 // like navigation to an anchor. 468 // like navigation to an anchor.
469 Page* page = frameView->frame().page(); 469 Page* page = frameView->frame().page();
470 if (!page) 470 if (!page)
471 return false; 471 return false;
472 return !page->autoscrollController().autoscrollInProgress(); 472 return !page->autoscrollController().autoscrollInProgress();
473 } 473 }
474 474
475 void RenderBox::scrollRectToVisible(const LayoutRect& rect, const ScrollAlignmen t& alignX, const ScrollAlignment& alignY) 475 void RenderBox::scrollRectToVisible(const LayoutRect& rect, const ScrollAlignmen t& alignX, const ScrollAlignment& alignY)
476 { 476 {
477 // Presumably the same issue as in setScrollTop. See crbug.com/343132.
478 DisableCompositingQueryAsserts disabler;
479
477 RenderBox* parentBox = 0; 480 RenderBox* parentBox = 0;
478 LayoutRect newRect = rect; 481 LayoutRect newRect = rect;
479 482
480 bool restrictedByLineClamp = false; 483 bool restrictedByLineClamp = false;
481 if (parent()) { 484 if (parent()) {
482 parentBox = parent()->enclosingBox(); 485 parentBox = parent()->enclosingBox();
483 restrictedByLineClamp = !parent()->style()->lineClamp().isNone(); 486 restrictedByLineClamp = !parent()->style()->lineClamp().isNone();
484 } 487 }
485 488
486 if (hasOverflowClip() && !restrictedByLineClamp) { 489 if (hasOverflowClip() && !restrictedByLineClamp) {
(...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after
731 if (!isHorizontalWritingMode() && style()->overflowX() == OSCROLL) { 734 if (!isHorizontalWritingMode() && style()->overflowX() == OSCROLL) {
732 ASSERT(layer()->scrollableArea() && layer()->scrollableArea()->hasHorizo ntalScrollbar()); 735 ASSERT(layer()->scrollableArea() && layer()->scrollableArea()->hasHorizo ntalScrollbar());
733 return horizontalScrollbarHeight(); 736 return horizontalScrollbarHeight();
734 } 737 }
735 738
736 return 0; 739 return 0;
737 } 740 }
738 741
739 bool RenderBox::scroll(ScrollDirection direction, ScrollGranularity granularity, float delta) 742 bool RenderBox::scroll(ScrollDirection direction, ScrollGranularity granularity, float delta)
740 { 743 {
744 // Presumably the same issue as in setScrollTop. See crbug.com/343132.
745 DisableCompositingQueryAsserts disabler;
746
741 // Logical scroll is a higher level concept, all directions by here must be physical 747 // Logical scroll is a higher level concept, all directions by here must be physical
742 ASSERT(!isLogical(direction)); 748 ASSERT(!isLogical(direction));
743 749
744 if (!layer() || !layer()->scrollableArea()) 750 if (!layer() || !layer()->scrollableArea())
745 return false; 751 return false;
746 752
747 return layer()->scrollableArea()->scroll(direction, granularity, delta); 753 return layer()->scrollableArea()->scroll(direction, granularity, delta);
748 } 754 }
749 755
750 bool RenderBox::canBeScrolledAndHasScrollableArea() const 756 bool RenderBox::canBeScrolledAndHasScrollableArea() const
(...skipping 3941 matching lines...) Expand 10 before | Expand all | Expand 10 after
4692 return 0; 4698 return 0;
4693 4699
4694 if (!layoutState && !flowThreadContainingBlock()) 4700 if (!layoutState && !flowThreadContainingBlock())
4695 return 0; 4701 return 0;
4696 4702
4697 RenderBlock* containerBlock = containingBlock(); 4703 RenderBlock* containerBlock = containingBlock();
4698 return containerBlock->offsetFromLogicalTopOfFirstPage() + logicalTop(); 4704 return containerBlock->offsetFromLogicalTopOfFirstPage() + logicalTop();
4699 } 4705 }
4700 4706
4701 } // namespace WebCore 4707 } // namespace WebCore
OLDNEW
« no previous file with comments | « no previous file | Source/core/rendering/RenderLayerScrollableArea.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698