| 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 819 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 830 void LayoutBlock::startDelayUpdateScrollInfo() | 830 void LayoutBlock::startDelayUpdateScrollInfo() |
| 831 { | 831 { |
| 832 if (gDelayUpdateScrollInfo == 0) { | 832 if (gDelayUpdateScrollInfo == 0) { |
| 833 ASSERT(!gDelayedUpdateScrollInfoSet); | 833 ASSERT(!gDelayedUpdateScrollInfoSet); |
| 834 gDelayedUpdateScrollInfoSet = new DelayedUpdateScrollInfoSet; | 834 gDelayedUpdateScrollInfoSet = new DelayedUpdateScrollInfoSet; |
| 835 } | 835 } |
| 836 ASSERT(gDelayedUpdateScrollInfoSet); | 836 ASSERT(gDelayedUpdateScrollInfoSet); |
| 837 ++gDelayUpdateScrollInfo; | 837 ++gDelayUpdateScrollInfo; |
| 838 } | 838 } |
| 839 | 839 |
| 840 bool LayoutBlock::finishDelayUpdateScrollInfo(SubtreeLayoutScope* layoutScope) | 840 bool LayoutBlock::finishDelayUpdateScrollInfo(SubtreeLayoutScope* layoutScope, S
crollPositionMap* scrollMap) |
| 841 { | 841 { |
| 842 bool childrenMarkedForRelayout = false; | 842 bool childrenMarkedForRelayout = false; |
| 843 | 843 |
| 844 --gDelayUpdateScrollInfo; | 844 --gDelayUpdateScrollInfo; |
| 845 ASSERT(gDelayUpdateScrollInfo >= 0); | 845 ASSERT(gDelayUpdateScrollInfo >= 0); |
| 846 if (gDelayUpdateScrollInfo == 0) { | 846 if (gDelayUpdateScrollInfo == 0) { |
| 847 ASSERT(gDelayedUpdateScrollInfoSet); | 847 ASSERT(gDelayedUpdateScrollInfoSet); |
| 848 | 848 |
| 849 OwnPtr<DelayedUpdateScrollInfoSet> infoSet(adoptPtr(gDelayedUpdateScroll
InfoSet)); | 849 OwnPtr<DelayedUpdateScrollInfoSet> infoSet(adoptPtr(gDelayedUpdateScroll
InfoSet)); |
| 850 gDelayedUpdateScrollInfoSet = nullptr; | 850 gDelayedUpdateScrollInfoSet = nullptr; |
| 851 | 851 |
| 852 for (auto* block : *infoSet) { | 852 for (auto* block : *infoSet) { |
| 853 if (block->hasOverflowClip()) { | 853 if (block->hasOverflowClip()) { |
| 854 childrenMarkedForRelayout |= block->layer()->scrollableArea()->u
pdateAfterLayout(layoutScope); | 854 PaintLayerScrollableArea* scrollableArea = block->layer()->scrol
lableArea(); |
| 855 if (scrollMap) |
| 856 scrollMap->add(scrollableArea, scrollableArea->scrollPositio
nDouble()); |
| 857 childrenMarkedForRelayout |= scrollableArea->updateAfterLayout(l
ayoutScope); |
| 855 } | 858 } |
| 856 } | 859 } |
| 857 } | 860 } |
| 858 return childrenMarkedForRelayout; | 861 return childrenMarkedForRelayout; |
| 859 } | 862 } |
| 860 | 863 |
| 861 void LayoutBlock::updateScrollInfoAfterLayout() | 864 void LayoutBlock::updateScrollInfoAfterLayout() |
| 862 { | 865 { |
| 863 if (hasOverflowClip()) { | 866 if (hasOverflowClip()) { |
| 864 if (style()->isFlippedBlocksWritingMode()) { | 867 if (style()->isFlippedBlocksWritingMode()) { |
| (...skipping 2006 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2871 void LayoutBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m
arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Layout
Object* obj) const | 2874 void LayoutBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m
arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Layout
Object* obj) const |
| 2872 { | 2875 { |
| 2873 showLayoutObject(); | 2876 showLayoutObject(); |
| 2874 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot
Box()) | 2877 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot
Box()) |
| 2875 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa
bel2, obj, 1); | 2878 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa
bel2, obj, 1); |
| 2876 } | 2879 } |
| 2877 | 2880 |
| 2878 #endif | 2881 #endif |
| 2879 | 2882 |
| 2880 } // namespace blink | 2883 } // namespace blink |
| OLD | NEW |