| OLD | NEW |
| 1 /** | 1 /** |
| 2 * Copyright (C) 2003, 2006 Apple Computer, Inc. | 2 * Copyright (C) 2003, 2006 Apple Computer, Inc. |
| 3 * | 3 * |
| 4 * This library is free software; you can redistribute it and/or | 4 * This library is free software; you can redistribute it and/or |
| 5 * modify it under the terms of the GNU Library General Public | 5 * modify it under the terms of the GNU Library General Public |
| 6 * License as published by the Free Software Foundation; either | 6 * License as published by the Free Software Foundation; either |
| 7 * version 2 of the License, or (at your option) any later version. | 7 * version 2 of the License, or (at your option) any later version. |
| 8 * | 8 * |
| 9 * This library is distributed in the hope that it will be useful, | 9 * This library is distributed in the hope that it will be useful, |
| 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 93 if (!m_shouldPaintMarkupBox || !m_renderer->isRenderBlock()) | 93 if (!m_shouldPaintMarkupBox || !m_renderer->isRenderBlock()) |
| 94 return 0; | 94 return 0; |
| 95 | 95 |
| 96 RenderBlock* block = toRenderBlock(m_renderer); | 96 RenderBlock* block = toRenderBlock(m_renderer); |
| 97 RootInlineBox* lastLine = block->lineAtIndex(block->lineCount() - 1); | 97 RootInlineBox* lastLine = block->lineAtIndex(block->lineCount() - 1); |
| 98 if (!lastLine) | 98 if (!lastLine) |
| 99 return 0; | 99 return 0; |
| 100 | 100 |
| 101 // If the last line-box on the last line of a block is a link, -webkit-line-
clamp paints that box after the ellipsis. | 101 // If the last line-box on the last line of a block is a link, -webkit-line-
clamp paints that box after the ellipsis. |
| 102 // It does not actually move the link. | 102 // It does not actually move the link. |
| 103 // FIXME: Now that we removed -webkit-line-clamp, can we remove this code...
? |
| 103 InlineBox* anchorBox = lastLine->lastChild(); | 104 InlineBox* anchorBox = lastLine->lastChild(); |
| 104 if (!anchorBox || !anchorBox->renderer()->style()->isLink()) | 105 if (!anchorBox || !anchorBox->renderer()->style()->isLink()) |
| 105 return 0; | 106 return 0; |
| 106 | 107 |
| 107 return anchorBox; | 108 return anchorBox; |
| 108 } | 109 } |
| 109 | 110 |
| 110 void EllipsisBox::paintMarkupBox(PaintInfo& paintInfo, const LayoutPoint& paintO
ffset, LayoutUnit lineTop, LayoutUnit lineBottom, RenderStyle* style) | 111 void EllipsisBox::paintMarkupBox(PaintInfo& paintInfo, const LayoutPoint& paintO
ffset, LayoutUnit lineTop, LayoutUnit lineBottom, RenderStyle* style) |
| 111 { | 112 { |
| 112 InlineBox* markupBox = this->markupBox(); | 113 InlineBox* markupBox = this->markupBox(); |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 168 if (visibleToHitTestRequest(request) && boundsRect.intersects(HitTestLocatio
n::rectForPoint(locationInContainer.point(), 0, 0, 0, 0))) { | 169 if (visibleToHitTestRequest(request) && boundsRect.intersects(HitTestLocatio
n::rectForPoint(locationInContainer.point(), 0, 0, 0, 0))) { |
| 169 renderer()->updateHitTestResult(result, locationInContainer.point() - to
LayoutSize(adjustedLocation)); | 170 renderer()->updateHitTestResult(result, locationInContainer.point() - to
LayoutSize(adjustedLocation)); |
| 170 if (!result.addNodeToRectBasedTestResult(renderer()->node(), request, lo
cationInContainer, boundsRect)) | 171 if (!result.addNodeToRectBasedTestResult(renderer()->node(), request, lo
cationInContainer, boundsRect)) |
| 171 return true; | 172 return true; |
| 172 } | 173 } |
| 173 | 174 |
| 174 return false; | 175 return false; |
| 175 } | 176 } |
| 176 | 177 |
| 177 } // namespace WebCore | 178 } // namespace WebCore |
| OLD | NEW |