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

Side by Side Diff: trunk/Source/core/rendering/RenderTable.cpp

Issue 23708015: Revert 157368 "Tables with display:inline rendered as block elem..." (Closed) Base URL: svn://svn.chromium.org/blink/
Patch Set: Created 7 years, 3 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 | « trunk/Source/core/rendering/RenderInline.cpp ('k') | no next file » | 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, 2007, 2008, 2009, 2010 Apple Inc. All r ights reserved. 7 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All r ights 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 1404 matching lines...) Expand 10 before | Expand all | Expand 10 after
1415 updateHitTestResult(result, flipForWritingMode(locationInContainer.point () - toLayoutSize(adjustedLocation))); 1415 updateHitTestResult(result, flipForWritingMode(locationInContainer.point () - toLayoutSize(adjustedLocation)));
1416 if (!result.addNodeToRectBasedTestResult(node(), request, locationInCont ainer, boundsRect)) 1416 if (!result.addNodeToRectBasedTestResult(node(), request, locationInCont ainer, boundsRect))
1417 return true; 1417 return true;
1418 } 1418 }
1419 1419
1420 return false; 1420 return false;
1421 } 1421 }
1422 1422
1423 RenderTable* RenderTable::createAnonymousWithParentRenderer(const RenderObject* parent) 1423 RenderTable* RenderTable::createAnonymousWithParentRenderer(const RenderObject* parent)
1424 { 1424 {
1425 RefPtr<RenderStyle> newStyle; 1425 RefPtr<RenderStyle> newStyle = RenderStyle::createAnonymousStyleWithDisplay( parent->style(), TABLE);
1426 if (parent->isInline() && !parent->isReplaced())
1427 newStyle = RenderStyle::createAnonymousStyleWithDisplay(parent->style(), INLINE_TABLE);
1428 else
1429 newStyle = RenderStyle::createAnonymousStyleWithDisplay(parent->style(), TABLE);
1430 RenderTable* newTable = new RenderTable(0); 1426 RenderTable* newTable = new RenderTable(0);
1431 newTable->setDocumentForAnonymous(&parent->document()); 1427 newTable->setDocumentForAnonymous(&parent->document());
1432 newTable->setStyle(newStyle.release()); 1428 newTable->setStyle(newStyle.release());
1433 return newTable; 1429 return newTable;
1434 } 1430 }
1435 1431
1436 const BorderValue& RenderTable::tableStartBorderAdjoiningCell(const RenderTableC ell* cell) const 1432 const BorderValue& RenderTable::tableStartBorderAdjoiningCell(const RenderTableC ell* cell) const
1437 { 1433 {
1438 ASSERT(cell->isFirstOrLastCellInRow()); 1434 ASSERT(cell->isFirstOrLastCellInRow());
1439 if (hasSameDirectionAs(cell->row())) 1435 if (hasSameDirectionAs(cell->row()))
1440 return style()->borderStart(); 1436 return style()->borderStart();
1441 1437
1442 return style()->borderEnd(); 1438 return style()->borderEnd();
1443 } 1439 }
1444 1440
1445 const BorderValue& RenderTable::tableEndBorderAdjoiningCell(const RenderTableCel l* cell) const 1441 const BorderValue& RenderTable::tableEndBorderAdjoiningCell(const RenderTableCel l* cell) const
1446 { 1442 {
1447 ASSERT(cell->isFirstOrLastCellInRow()); 1443 ASSERT(cell->isFirstOrLastCellInRow());
1448 if (hasSameDirectionAs(cell->row())) 1444 if (hasSameDirectionAs(cell->row()))
1449 return style()->borderEnd(); 1445 return style()->borderEnd();
1450 1446
1451 return style()->borderStart(); 1447 return style()->borderStart();
1452 } 1448 }
1453 1449
1454 } 1450 }
OLDNEW
« no previous file with comments | « trunk/Source/core/rendering/RenderInline.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698