| OLD | NEW |
| 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) 2007 David Smith (catfish.man@gmail.com) | 4 * (C) 2007 David Smith (catfish.man@gmail.com) |
| 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc.
All rights reserved. | 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc.
All rights reserved. |
| 6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
| 7 * | 7 * |
| 8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
| 9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
| 10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
| (...skipping 863 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 874 void LayoutBlock::startDelayUpdateScrollInfo() | 874 void LayoutBlock::startDelayUpdateScrollInfo() |
| 875 { | 875 { |
| 876 if (gDelayUpdateScrollInfo == 0) { | 876 if (gDelayUpdateScrollInfo == 0) { |
| 877 ASSERT(!gDelayedUpdateScrollInfoSet); | 877 ASSERT(!gDelayedUpdateScrollInfoSet); |
| 878 gDelayedUpdateScrollInfoSet = new DelayedUpdateScrollInfoSet; | 878 gDelayedUpdateScrollInfoSet = new DelayedUpdateScrollInfoSet; |
| 879 } | 879 } |
| 880 ASSERT(gDelayedUpdateScrollInfoSet); | 880 ASSERT(gDelayedUpdateScrollInfoSet); |
| 881 ++gDelayUpdateScrollInfo; | 881 ++gDelayUpdateScrollInfo; |
| 882 } | 882 } |
| 883 | 883 |
| 884 void LayoutBlock::finishDelayUpdateScrollInfo() | 884 bool LayoutBlock::finishDelayUpdateScrollInfo(SubtreeLayoutScope* layoutScope) |
| 885 { | 885 { |
| 886 bool childrenMarkedForRelayout = false; |
| 887 |
| 886 --gDelayUpdateScrollInfo; | 888 --gDelayUpdateScrollInfo; |
| 887 ASSERT(gDelayUpdateScrollInfo >= 0); | 889 ASSERT(gDelayUpdateScrollInfo >= 0); |
| 888 if (gDelayUpdateScrollInfo == 0) { | 890 if (gDelayUpdateScrollInfo == 0) { |
| 889 ASSERT(gDelayedUpdateScrollInfoSet); | 891 ASSERT(gDelayedUpdateScrollInfoSet); |
| 890 | 892 |
| 891 OwnPtr<DelayedUpdateScrollInfoSet> infoSet(adoptPtr(gDelayedUpdateScroll
InfoSet)); | 893 OwnPtr<DelayedUpdateScrollInfoSet> infoSet(adoptPtr(gDelayedUpdateScroll
InfoSet)); |
| 892 gDelayedUpdateScrollInfoSet = nullptr; | 894 gDelayedUpdateScrollInfoSet = nullptr; |
| 893 | 895 |
| 894 for (auto* block : *infoSet) { | 896 for (auto* block : *infoSet) { |
| 895 if (block->hasOverflowClip()) { | 897 if (block->hasOverflowClip()) { |
| 896 block->layer()->scrollableArea()->updateAfterLayout(); | 898 childrenMarkedForRelayout |= block->layer()->scrollableArea()->u
pdateAfterLayout(layoutScope); |
| 897 } | 899 } |
| 898 } | 900 } |
| 899 } | 901 } |
| 902 return childrenMarkedForRelayout; |
| 900 } | 903 } |
| 901 | 904 |
| 902 void LayoutBlock::updateScrollInfoAfterLayout() | 905 void LayoutBlock::updateScrollInfoAfterLayout() |
| 903 { | 906 { |
| 904 if (hasOverflowClip()) { | 907 if (hasOverflowClip()) { |
| 905 if (style()->isFlippedBlocksWritingMode()) { | 908 if (style()->isFlippedBlocksWritingMode()) { |
| 906 // FIXME: https://bugs.webkit.org/show_bug.cgi?id=97937 | 909 // FIXME: https://bugs.webkit.org/show_bug.cgi?id=97937 |
| 907 // Workaround for now. We cannot delay the scroll info for overflow | 910 // Workaround for now. We cannot delay the scroll info for overflow |
| 908 // for items with opposite writing directions, as the contents needs | 911 // for items with opposite writing directions, as the contents needs |
| 909 // to overflow in that direction | 912 // to overflow in that direction |
| (...skipping 1996 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2906 void LayoutBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m
arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Layout
Object* obj) const | 2909 void LayoutBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m
arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Layout
Object* obj) const |
| 2907 { | 2910 { |
| 2908 showLayoutObject(); | 2911 showLayoutObject(); |
| 2909 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot
Box()) | 2912 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot
Box()) |
| 2910 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa
bel2, obj, 1); | 2913 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa
bel2, obj, 1); |
| 2911 } | 2914 } |
| 2912 | 2915 |
| 2913 #endif | 2916 #endif |
| 2914 | 2917 |
| 2915 } // namespace blink | 2918 } // namespace blink |
| OLD | NEW |