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

Side by Side Diff: third_party/WebKit/Source/core/layout/line/InlineFlowBox.cpp

Issue 1657483003: Add a border radius property to inherit it from a parent in a fallback content (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved.
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 1015 matching lines...) Expand 10 before | Expand all | Expand 10 after
1026 if (culledParent == lineLayoutItem() || (hasSibling && prev && prev- >lineLayoutItem().isDescendantOf(culledParent))) 1026 if (culledParent == lineLayoutItem() || (hasSibling && prev && prev- >lineLayoutItem().isDescendantOf(culledParent)))
1027 break; 1027 break;
1028 1028
1029 if (culledParent.isLayoutInline() && LineLayoutInline(culledParent). hitTestCulledInline(result, locationInContainer, accumulatedOffset)) 1029 if (culledParent.isLayoutInline() && LineLayoutInline(culledParent). hitTestCulledInline(result, locationInContainer, accumulatedOffset))
1030 return true; 1030 return true;
1031 1031
1032 currLayoutItem = culledParent; 1032 currLayoutItem = culledParent;
1033 } 1033 }
1034 } 1034 }
1035 1035
1036 if (lineLayoutItem().style()->hasBorderRadius()) { 1036 if (lineLayoutItem().style()->hasBorderRadius()) {
pdr. 2016/03/07 21:15:51 I agree that the code in InlineBox::nodeAtPoint is
Miyoung Shin(c) 2016/03/09 12:28:07 <img> has a <div> child with inline-block for a fa
pdr. 2016/03/21 05:26:10 I think you're getting stuck on the <img> case whe
Miyoung Shin(c) 2016/03/29 22:49:40 As you suggested, I've looked at how rounded rects
1037 LayoutRect borderRect = logicalFrameRect(); 1037 LayoutRect borderRect;
1038 bool includeLeftEdge = true;
1039 bool includeRightEdge = true;
1040 if (lineLayoutItem().isBox()) {
1041 borderRect = toLayoutBox(lineLayoutItem())->borderBoxRect();
1042 } else {
1043 borderRect = logicalFrameRect();
1044 includeLeftEdge = includeLogicalLeftEdge();
1045 includeRightEdge = includeLogicalRightEdge();
1046 }
1047
1038 borderRect.moveBy(accumulatedOffset); 1048 borderRect.moveBy(accumulatedOffset);
1039 FloatRoundedRect border = lineLayoutItem().style()->getRoundedBorderFor( borderRect, includeLogicalLeftEdge(), includeLogicalRightEdge()); 1049 FloatRoundedRect border = lineLayoutItem().style()->getRoundedBorderFor( borderRect, includeLeftEdge, includeRightEdge);
1040 if (!locationInContainer.intersects(border)) 1050 if (!locationInContainer.intersects(border))
1041 return false; 1051 return false;
1042 } 1052 }
1043 1053
1044 // Now check ourselves. 1054 // Now check ourselves.
1045 LayoutRect rect = InlineFlowBoxPainter(*this).frameRectClampedToLineTopAndBo ttomIfNeeded(); 1055 LayoutRect rect = InlineFlowBoxPainter(*this).frameRectClampedToLineTopAndBo ttomIfNeeded();
1046 1056
1047 flipForWritingMode(rect); 1057 flipForWritingMode(rect);
1048 rect.moveBy(accumulatedOffset); 1058 rect.moveBy(accumulatedOffset);
1049 1059
(...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after
1314 ASSERT(child->prevOnLine() == prev); 1324 ASSERT(child->prevOnLine() == prev);
1315 prev = child; 1325 prev = child;
1316 } 1326 }
1317 ASSERT(prev == m_lastChild); 1327 ASSERT(prev == m_lastChild);
1318 #endif 1328 #endif
1319 } 1329 }
1320 1330
1321 #endif 1331 #endif
1322 1332
1323 } // namespace blink 1333 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698