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 2579 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2590 rects.append(rect); | 2590 rects.append(rect); |
2591 } | 2591 } |
2592 | 2592 |
2593 addOutlineRectsForNormalChildren(rects, additionalOffset); | 2593 addOutlineRectsForNormalChildren(rects, additionalOffset); |
2594 if (TrackedLayoutBoxListHashSet* positionedObjects = this->positionedObj
ects()) { | 2594 if (TrackedLayoutBoxListHashSet* positionedObjects = this->positionedObj
ects()) { |
2595 for (auto* box : *positionedObjects) | 2595 for (auto* box : *positionedObjects) |
2596 addOutlineRectsForDescendant(*box, rects, additionalOffset); | 2596 addOutlineRectsForDescendant(*box, rects, additionalOffset); |
2597 } | 2597 } |
2598 } | 2598 } |
2599 | 2599 |
2600 if (inlineElementContinuation) { | 2600 if (inlineElementContinuation) |
2601 Vector<LayoutRect> inlineOutlineRects; | 2601 inlineElementContinuation->addOutlineRects(rects, additionalOffset + (in
lineElementContinuation->containingBlock()->location() - location())); |
2602 // We need to give the LayoutInline a clean vector to let it add focus r
ing rects of line boxes. | |
2603 inlineElementContinuation->addOutlineRects(inlineOutlineRects, additiona
lOffset + (inlineElementContinuation->containingBlock()->location() - location()
)); | |
2604 rects.appendVector(inlineOutlineRects); | |
2605 } | |
2606 } | 2602 } |
2607 | 2603 |
2608 void LayoutBlock::computeSelfHitTestRects(Vector<LayoutRect>& rects, const Layou
tPoint& layerOffset) const | 2604 void LayoutBlock::computeSelfHitTestRects(Vector<LayoutRect>& rects, const Layou
tPoint& layerOffset) const |
2609 { | 2605 { |
2610 LayoutBox::computeSelfHitTestRects(rects, layerOffset); | 2606 LayoutBox::computeSelfHitTestRects(rects, layerOffset); |
2611 | 2607 |
2612 if (hasHorizontalLayoutOverflow() || hasVerticalLayoutOverflow()) { | 2608 if (hasHorizontalLayoutOverflow() || hasVerticalLayoutOverflow()) { |
2613 for (RootInlineBox* curr = firstRootBox(); curr; curr = curr->nextRootBo
x()) { | 2609 for (RootInlineBox* curr = firstRootBox(); curr; curr = curr->nextRootBo
x()) { |
2614 LayoutUnit top = std::max<LayoutUnit>(curr->lineTop(), curr->top()); | 2610 LayoutUnit top = std::max<LayoutUnit>(curr->lineTop(), curr->top()); |
2615 LayoutUnit bottom = std::min<LayoutUnit>(curr->lineBottom(), curr->t
op() + curr->height()); | 2611 LayoutUnit bottom = std::min<LayoutUnit>(curr->lineBottom(), curr->t
op() + curr->height()); |
(...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2925 void LayoutBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m
arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Layout
Object* obj) const | 2921 void LayoutBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m
arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Layout
Object* obj) const |
2926 { | 2922 { |
2927 showLayoutObject(); | 2923 showLayoutObject(); |
2928 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot
Box()) | 2924 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot
Box()) |
2929 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa
bel2, obj, 1); | 2925 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa
bel2, obj, 1); |
2930 } | 2926 } |
2931 | 2927 |
2932 #endif | 2928 #endif |
2933 | 2929 |
2934 } // namespace blink | 2930 } // namespace blink |
OLD | NEW |