| 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 Apple Inc. All r
ights reserved. | 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All r
ights reserved. |
| 6 * | 6 * |
| 7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
| 8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
| 9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
| 10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
| (...skipping 325 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 336 // This function disables the 'overflow' check in inlineBlockBaseline. | 336 // This function disables the 'overflow' check in inlineBlockBaseline. |
| 337 // For 'inline-block', CSS says that the baseline is the bottom margin edge | 337 // For 'inline-block', CSS says that the baseline is the bottom margin edge |
| 338 // if 'overflow' is not visible. But some descendant classes want to ignore | 338 // if 'overflow' is not visible. But some descendant classes want to ignore |
| 339 // this condition. | 339 // this condition. |
| 340 virtual bool shouldIgnoreOverflowPropertyForInlineBlockBaseline() const { re
turn false; } | 340 virtual bool shouldIgnoreOverflowPropertyForInlineBlockBaseline() const { re
turn false; } |
| 341 | 341 |
| 342 bool hitTestOverflowControl(HitTestResult&, const HitTestLocation&, const La
youtPoint& adjustedLocation) override; | 342 bool hitTestOverflowControl(HitTestResult&, const HitTestLocation&, const La
youtPoint& adjustedLocation) override; |
| 343 bool hitTestChildren(HitTestResult&, const HitTestLocation& locationInContai
ner, const LayoutPoint& accumulatedOffset, HitTestAction) override; | 343 bool hitTestChildren(HitTestResult&, const HitTestLocation& locationInContai
ner, const LayoutPoint& accumulatedOffset, HitTestAction) override; |
| 344 void updateHitTestResult(HitTestResult&, const LayoutPoint&) override; | 344 void updateHitTestResult(HitTestResult&, const LayoutPoint&) override; |
| 345 | 345 |
| 346 // Delay update scrollbar until finishDelayUpdateScrollInfo() will be | |
| 347 // called. This function is used when a flexbox is laying out its | |
| 348 // descendant. If multiple calls are made to startDelayUpdateScrollInfo(), | |
| 349 // finishDelayUpdateScrollInfo() will do nothing until finishDelayUpdateScro
llInfo() | |
| 350 // is called the same number of times. | |
| 351 // finishDelayUpdateScrollInfo returns true when it marked something for lay
out. | |
| 352 // It will also return a map of saved scroll positions that the caller shoul
d restore | |
| 353 // on the given scrollable areas after performing the layout. | |
| 354 // This can be necessary because Flexbox's multi-pass layout can lose the sc
roll position. | |
| 355 // TODO(cbiesinger): This is a temporary hack. The right solution is to dela
y the scroll | |
| 356 // clamping that currently happens in PaintLayerScrollableArea::updateAfterL
ayout to only | |
| 357 // happen after all layout is done, i.e. during updateLayerPositionsAfterLay
out. However, | |
| 358 // that currently fails a layout test. To fix this bug in time for M50, we u
se this temporary | |
| 359 // hack. The real fix is tracked in crbug.com/600036 | |
| 360 typedef PersistentHeapHashMap<Member<PaintLayerScrollableArea>, DoublePoint>
ScrollPositionMap; | |
| 361 static void startDelayUpdateScrollInfo(); | |
| 362 static bool finishDelayUpdateScrollInfo(SubtreeLayoutScope*, ScrollPositionM
ap*); | |
| 363 | |
| 364 void updateAfterLayout(); | 346 void updateAfterLayout(); |
| 365 | 347 |
| 366 void styleWillChange(StyleDifference, const ComputedStyle& newStyle) overrid
e; | 348 void styleWillChange(StyleDifference, const ComputedStyle& newStyle) overrid
e; |
| 367 void styleDidChange(StyleDifference, const ComputedStyle* oldStyle) override
; | 349 void styleDidChange(StyleDifference, const ComputedStyle* oldStyle) override
; |
| 368 void updateFromStyle() override; | 350 void updateFromStyle() override; |
| 369 | 351 |
| 370 // Returns true if non-visible overflow should be respected. Otherwise hasOv
erflowClip() will be | 352 // Returns true if non-visible overflow should be respected. Otherwise hasOv
erflowClip() will be |
| 371 // false and we won't create scrollable area for this object even if overflo
w is non-visible. | 353 // false and we won't create scrollable area for this object even if overflo
w is non-visible. |
| 372 virtual bool allowsOverflowClip() const; | 354 virtual bool allowsOverflowClip() const; |
| 373 | 355 |
| (...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 497 // FIXME: This is temporary as we move code that accesses block flow | 479 // FIXME: This is temporary as we move code that accesses block flow |
| 498 // member variables out of LayoutBlock and into LayoutBlockFlow. | 480 // member variables out of LayoutBlock and into LayoutBlockFlow. |
| 499 friend class LayoutBlockFlow; | 481 friend class LayoutBlockFlow; |
| 500 }; | 482 }; |
| 501 | 483 |
| 502 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutBlock, isLayoutBlock()); | 484 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutBlock, isLayoutBlock()); |
| 503 | 485 |
| 504 } // namespace blink | 486 } // namespace blink |
| 505 | 487 |
| 506 #endif // LayoutBlock_h | 488 #endif // LayoutBlock_h |
| OLD | NEW |