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) 2005 Allan Sandfeld Jensen (kde@carewolf.com) | 4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) |
5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) | 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) |
6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. | 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. |
7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. | 7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. |
8 * | 8 * |
9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
(...skipping 2745 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2756 RenderObject* firstChild = slowFirstChild(); | 2756 RenderObject* firstChild = slowFirstChild(); |
2757 if (!firstChild) | 2757 if (!firstChild) |
2758 return createPositionWithAffinity(node() ? firstPositionInOrBeforeNode(n
ode()) : Position()); | 2758 return createPositionWithAffinity(node() ? firstPositionInOrBeforeNode(n
ode()) : Position()); |
2759 | 2759 |
2760 // Pass off to the closest child. | 2760 // Pass off to the closest child. |
2761 LayoutUnit minDist = LayoutUnit::max(); | 2761 LayoutUnit minDist = LayoutUnit::max(); |
2762 RenderBox* closestRenderer = 0; | 2762 RenderBox* closestRenderer = 0; |
2763 LayoutPoint adjustedPoint = point; | 2763 LayoutPoint adjustedPoint = point; |
2764 | 2764 |
2765 for (RenderObject* renderObject = firstChild; renderObject; renderObject = r
enderObject->nextSibling()) { | 2765 for (RenderObject* renderObject = firstChild; renderObject; renderObject = r
enderObject->nextSibling()) { |
2766 if (!renderObject->slowFirstChild() && !renderObject->isInline() && !ren
derObject->isRenderBlockFlow()) | 2766 if (!renderObject->slowFirstChild() && !renderObject->isInline() && !ren
derObject->isRenderParagraph()) |
2767 continue; | 2767 continue; |
2768 | 2768 |
2769 if (!renderObject->isBox()) | 2769 if (!renderObject->isBox()) |
2770 continue; | 2770 continue; |
2771 | 2771 |
2772 RenderBox* renderer = toRenderBox(renderObject); | 2772 RenderBox* renderer = toRenderBox(renderObject); |
2773 | 2773 |
2774 LayoutUnit top = renderer->borderTop() + renderer->paddingTop() + render
er->y(); | 2774 LayoutUnit top = renderer->borderTop() + renderer->paddingTop() + render
er->y(); |
2775 LayoutUnit bottom = top + renderer->contentHeight(); | 2775 LayoutUnit bottom = top + renderer->contentHeight(); |
2776 LayoutUnit left = renderer->borderLeft() + renderer->paddingLeft() + ren
derer->x(); | 2776 LayoutUnit left = renderer->borderLeft() + renderer->paddingLeft() + ren
derer->x(); |
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3074 | 3074 |
3075 RenderBox::BoxDecorationData::BoxDecorationData(const RenderStyle& style) | 3075 RenderBox::BoxDecorationData::BoxDecorationData(const RenderStyle& style) |
3076 { | 3076 { |
3077 backgroundColor = style.colorIncludingFallback(CSSPropertyBackgroundColor); | 3077 backgroundColor = style.colorIncludingFallback(CSSPropertyBackgroundColor); |
3078 hasBackground = backgroundColor.alpha() || style.hasBackgroundImage(); | 3078 hasBackground = backgroundColor.alpha() || style.hasBackgroundImage(); |
3079 ASSERT(hasBackground == style.hasBackground()); | 3079 ASSERT(hasBackground == style.hasBackground()); |
3080 hasBorder = style.hasBorder(); | 3080 hasBorder = style.hasBorder(); |
3081 } | 3081 } |
3082 | 3082 |
3083 } // namespace blink | 3083 } // namespace blink |
OLD | NEW |