Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(340)

Side by Side Diff: Source/core/rendering/RenderTableSection.cpp

Issue 143323014: *** DO NOT LAND *** Attempt to understand Regions complexity Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/rendering/RenderTable.cpp ('k') | Source/core/rendering/RenderTreeAsText.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1997 Martin Jones (mjones@kde.org) 2 * Copyright (C) 1997 Martin Jones (mjones@kde.org)
3 * (C) 1997 Torben Weis (weis@kde.org) 3 * (C) 1997 Torben Weis (weis@kde.org)
4 * (C) 1998 Waldo Bastian (bastian@kde.org) 4 * (C) 1998 Waldo Bastian (bastian@kde.org)
5 * (C) 1999 Lars Knoll (knoll@kde.org) 5 * (C) 1999 Lars Knoll (knoll@kde.org)
6 * (C) 1999 Antti Koivisto (koivisto@kde.org) 6 * (C) 1999 Antti Koivisto (koivisto@kde.org)
7 * Copyright (C) 2003, 2004, 2005, 2006, 2008, 2009, 2010 Apple Inc. All rights reserved. 7 * Copyright (C) 2003, 2004, 2005, 2006, 2008, 2009, 2010 Apple Inc. All rights reserved.
8 * Copyright (C) 2006 Alexey Proskuryakov (ap@nypop.com) 8 * Copyright (C) 2006 Alexey Proskuryakov (ap@nypop.com)
9 * 9 *
10 * This library is free software; you can redistribute it and/or 10 * This library is free software; you can redistribute it and/or
(...skipping 1696 matching lines...) Expand 10 before | Expand all | Expand 10 after
1707 bool RenderTableSection::nodeAtPoint(const HitTestRequest& request, HitTestResul t& result, const HitTestLocation& locationInContainer, const LayoutPoint& accumu latedOffset, HitTestAction action) 1707 bool RenderTableSection::nodeAtPoint(const HitTestRequest& request, HitTestResul t& result, const HitTestLocation& locationInContainer, const LayoutPoint& accumu latedOffset, HitTestAction action)
1708 { 1708 {
1709 // If we have no children then we have nothing to do. 1709 // If we have no children then we have nothing to do.
1710 if (!firstChild()) 1710 if (!firstChild())
1711 return false; 1711 return false;
1712 1712
1713 // Table sections cannot ever be hit tested. Effectively they do not exist. 1713 // Table sections cannot ever be hit tested. Effectively they do not exist.
1714 // Just forward to our children always. 1714 // Just forward to our children always.
1715 LayoutPoint adjustedLocation = accumulatedOffset + location(); 1715 LayoutPoint adjustedLocation = accumulatedOffset + location();
1716 1716
1717 if (hasOverflowClip() && !locationInContainer.intersects(overflowClipRect(ad justedLocation, locationInContainer.region()))) 1717 if (hasOverflowClip() && !locationInContainer.intersects(overflowClipRect(ad justedLocation)))
1718 return false; 1718 return false;
1719 1719
1720 if (hasOverflowingCell()) { 1720 if (hasOverflowingCell()) {
1721 for (RenderObject* child = lastChild(); child; child = child->previousSi bling()) { 1721 for (RenderObject* child = lastChild(); child; child = child->previousSi bling()) {
1722 // FIXME: We have to skip over inline flows, since they can show up inside table rows 1722 // FIXME: We have to skip over inline flows, since they can show up inside table rows
1723 // at the moment (a demoted inline <form> for example). If we ever i mplement a 1723 // at the moment (a demoted inline <form> for example). If we ever i mplement a
1724 // table-specific hit-test method (which we should do for performanc e reasons anyway), 1724 // table-specific hit-test method (which we should do for performanc e reasons anyway),
1725 // then we can remove this check. 1725 // then we can remove this check.
1726 if (child->isBox() && !toRenderBox(child)->hasSelfPaintingLayer()) { 1726 if (child->isBox() && !toRenderBox(child)->hasSelfPaintingLayer()) {
1727 LayoutPoint childPoint = flipForWritingModeForChild(toRenderBox( child), adjustedLocation); 1727 LayoutPoint childPoint = flipForWritingModeForChild(toRenderBox( child), adjustedLocation);
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
1814 if (!style()->isLeftToRightDirection()) 1814 if (!style()->isLeftToRightDirection())
1815 cellLocation.setX(table()->columnPositions()[table()->numEffCols()] - ta ble()->columnPositions()[table()->colToEffCol(cell->col() + cell->colSpan())] + horizontalBorderSpacing); 1815 cellLocation.setX(table()->columnPositions()[table()->numEffCols()] - ta ble()->columnPositions()[table()->colToEffCol(cell->col() + cell->colSpan())] + horizontalBorderSpacing);
1816 else 1816 else
1817 cellLocation.setX(table()->columnPositions()[effectiveColumn] + horizont alBorderSpacing); 1817 cellLocation.setX(table()->columnPositions()[effectiveColumn] + horizont alBorderSpacing);
1818 1818
1819 cell->setLogicalLocation(cellLocation); 1819 cell->setLogicalLocation(cellLocation);
1820 view()->addLayoutDelta(oldCellLocation - cell->location()); 1820 view()->addLayoutDelta(oldCellLocation - cell->location());
1821 } 1821 }
1822 1822
1823 } // namespace WebCore 1823 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderTable.cpp ('k') | Source/core/rendering/RenderTreeAsText.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698