OLD | NEW |
1 /* | 1 /* |
2 * (C) 1999 Lars Knoll (knoll@kde.org) | 2 * (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 2000 Dirk Mueller (mueller@kde.org) | 3 * (C) 2000 Dirk Mueller (mueller@kde.org) |
4 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. | 4 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. |
5 * All rights reserved. | 5 * All rights 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 393 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
404 } | 404 } |
405 | 405 |
406 bool InlineTextBox::nodeAtPoint(HitTestResult& result, | 406 bool InlineTextBox::nodeAtPoint(HitTestResult& result, |
407 const HitTestLocation& locationInContainer, | 407 const HitTestLocation& locationInContainer, |
408 const LayoutPoint& accumulatedOffset, | 408 const LayoutPoint& accumulatedOffset, |
409 LayoutUnit /* lineTop */, | 409 LayoutUnit /* lineTop */, |
410 LayoutUnit /*lineBottom*/) { | 410 LayoutUnit /*lineBottom*/) { |
411 if (isLineBreak() || m_truncation == cFullTruncation) | 411 if (isLineBreak() || m_truncation == cFullTruncation) |
412 return false; | 412 return false; |
413 | 413 |
414 LayoutPoint boxOrigin = locationIncludingFlipping(); | 414 LayoutPoint boxOrigin = physicalLocation(); |
415 boxOrigin.moveBy(accumulatedOffset); | 415 boxOrigin.moveBy(accumulatedOffset); |
416 LayoutRect rect(boxOrigin, size()); | 416 LayoutRect rect(boxOrigin, size()); |
417 if (visibleToHitTestRequest(result.hitTestRequest()) && | 417 if (visibleToHitTestRequest(result.hitTestRequest()) && |
418 locationInContainer.intersects(rect)) { | 418 locationInContainer.intersects(rect)) { |
419 getLineLayoutItem().updateHitTestResult( | 419 getLineLayoutItem().updateHitTestResult( |
420 result, flipForWritingMode(locationInContainer.point() - | 420 result, flipForWritingMode(locationInContainer.point() - |
421 toLayoutSize(accumulatedOffset))); | 421 toLayoutSize(accumulatedOffset))); |
422 if (result.addNodeToListBasedTestResult(getLineLayoutItem().node(), | 422 if (result.addNodeToListBasedTestResult(getLineLayoutItem().node(), |
423 locationInContainer, | 423 locationInContainer, |
424 rect) == StopHitTesting) | 424 rect) == StopHitTesting) |
(...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
682 const int layoutObjectCharacterOffset = 75; | 682 const int layoutObjectCharacterOffset = 75; |
683 for (; printedCharacters < layoutObjectCharacterOffset; printedCharacters++) | 683 for (; printedCharacters < layoutObjectCharacterOffset; printedCharacters++) |
684 fputc(' ', stderr); | 684 fputc(' ', stderr); |
685 fprintf(stderr, "(%d,%d) \"%s\"\n", start(), start() + len(), | 685 fprintf(stderr, "(%d,%d) \"%s\"\n", start(), start() + len(), |
686 value.utf8().data()); | 686 value.utf8().data()); |
687 } | 687 } |
688 | 688 |
689 #endif | 689 #endif |
690 | 690 |
691 } // namespace blink | 691 } // namespace blink |
OLD | NEW |