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 258 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
269 #if ENABLE(ASSERT) | 269 #if ENABLE(ASSERT) |
270 void checkPositionedObjectsNeedLayout(); | 270 void checkPositionedObjectsNeedLayout(); |
271 #endif | 271 #endif |
272 #ifndef NDEBUG | 272 #ifndef NDEBUG |
273 void showLineTreeAndMark(const InlineBox* = nullptr, const char* = nullptr, const InlineBox* = nullptr, const char* = nullptr, const LayoutObject* = nullptr ) const; | 273 void showLineTreeAndMark(const InlineBox* = nullptr, const char* = nullptr, const InlineBox* = nullptr, const char* = nullptr, const LayoutObject* = nullptr ) const; |
274 #endif | 274 #endif |
275 | 275 |
276 bool recalcChildOverflowAfterStyleChange(); | 276 bool recalcChildOverflowAfterStyleChange(); |
277 bool recalcOverflowAfterStyleChange(); | 277 bool recalcOverflowAfterStyleChange(); |
278 | 278 |
279 // Obtains the nearest enclosing block (including this block) that contribut es a first-line style to our inline children. | |
mstensho (USE GERRIT)
2015/12/03 12:08:10
"Returns the nearest enclosing block (including th
Xianzhu
2015/12/03 17:38:22
Done.
| |
280 LayoutBlock* firstLineStyleBlock() const; | |
mstensho (USE GERRIT)
2015/12/03 12:08:10
enclosingFirstLineStyleBlock()?
Xianzhu
2015/12/03 17:38:22
Done.
| |
281 // Returns the descendant block containing the actual first line. | |
mstensho (USE GERRIT)
2015/12/03 12:08:10
Shouldn't this also include this block? I see that
Xianzhu
2015/12/03 17:38:22
Yes, it should. Done. Also added a test to cover t
| |
282 LayoutBlockFlow* firstLineContainer() const; | |
mstensho (USE GERRIT)
2015/12/03 12:08:10
Not sure if I'm happy with the block vs. container
Xianzhu
2015/12/03 17:38:22
Your suggestion sounds better. Done.
| |
283 | |
279 protected: | 284 protected: |
280 void willBeDestroyed() override; | 285 void willBeDestroyed() override; |
281 | 286 |
282 void dirtyForLayoutFromPercentageHeightDescendants(SubtreeLayoutScope&); | 287 void dirtyForLayoutFromPercentageHeightDescendants(SubtreeLayoutScope&); |
283 | 288 |
284 void layout() override; | 289 void layout() override; |
285 | 290 |
286 enum PositionedLayoutBehavior { | 291 enum PositionedLayoutBehavior { |
287 DefaultLayout, | 292 DefaultLayout, |
288 LayoutOnlyFixedPositionedObjects, | 293 LayoutOnlyFixedPositionedObjects, |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
389 bool avoidsFloats() const override { return true; } | 394 bool avoidsFloats() const override { return true; } |
390 | 395 |
391 bool hitTestContents(HitTestResult&, const HitTestLocation& locationInContai ner, const LayoutPoint& accumulatedOffset, HitTestAction); | 396 bool hitTestContents(HitTestResult&, const HitTestLocation& locationInContai ner, const LayoutPoint& accumulatedOffset, HitTestAction); |
392 // FIXME-BLOCKFLOW: Remove virtualizaion when all callers have moved to Layo utBlockFlow | 397 // FIXME-BLOCKFLOW: Remove virtualizaion when all callers have moved to Layo utBlockFlow |
393 virtual bool hitTestFloats(HitTestResult&, const HitTestLocation&, const Lay outPoint&) { return false; } | 398 virtual bool hitTestFloats(HitTestResult&, const HitTestLocation&, const Lay outPoint&) { return false; } |
394 | 399 |
395 virtual bool isPointInOverflowControl(HitTestResult&, const LayoutPoint& loc ationInContainer, const LayoutPoint& accumulatedOffset) const; | 400 virtual bool isPointInOverflowControl(HitTestResult&, const LayoutPoint& loc ationInContainer, const LayoutPoint& accumulatedOffset) const; |
396 | 401 |
397 void computeBlockPreferredLogicalWidths(LayoutUnit& minLogicalWidth, LayoutU nit& maxLogicalWidth) const; | 402 void computeBlockPreferredLogicalWidths(LayoutUnit& minLogicalWidth, LayoutU nit& maxLogicalWidth) const; |
398 | 403 |
399 // Obtains the nearest enclosing block (including this block) that contribut es a first-line style to our inline | |
400 // children. | |
401 LayoutBlock* firstLineBlock() const override; | |
402 | |
403 LayoutObject* hoverAncestor() const final; | 404 LayoutObject* hoverAncestor() const final; |
404 void updateDragState(bool dragOn) final; | 405 void updateDragState(bool dragOn) final; |
405 void childBecameNonInline(LayoutObject* child) final; | 406 void childBecameNonInline(LayoutObject* child) final; |
406 | 407 |
407 bool isSelectionRoot() const; | 408 bool isSelectionRoot() const; |
408 | 409 |
409 void absoluteRects(Vector<IntRect>&, const LayoutPoint& accumulatedOffset) c onst override; | 410 void absoluteRects(Vector<IntRect>&, const LayoutPoint& accumulatedOffset) c onst override; |
410 void absoluteQuads(Vector<FloatQuad>&, bool* wasFixed) const override; | 411 void absoluteQuads(Vector<FloatQuad>&, bool* wasFixed) const override; |
411 | 412 |
412 public: | 413 public: |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
489 // FIXME: This is temporary as we move code that accesses block flow | 490 // FIXME: This is temporary as we move code that accesses block flow |
490 // member variables out of LayoutBlock and into LayoutBlockFlow. | 491 // member variables out of LayoutBlock and into LayoutBlockFlow. |
491 friend class LayoutBlockFlow; | 492 friend class LayoutBlockFlow; |
492 }; | 493 }; |
493 | 494 |
494 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutBlock, isLayoutBlock()); | 495 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutBlock, isLayoutBlock()); |
495 | 496 |
496 } // namespace blink | 497 } // namespace blink |
497 | 498 |
498 #endif // LayoutBlock_h | 499 #endif // LayoutBlock_h |
OLD | NEW |