OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
115 } else | 115 } else |
116 minLogicalWidth += minPreferredLogicalWidth; | 116 minLogicalWidth += minPreferredLogicalWidth; |
117 } else { | 117 } else { |
118 minLogicalWidth = std::max(minPreferredLogicalWidth, minLogicalWidth
); | 118 minLogicalWidth = std::max(minPreferredLogicalWidth, minLogicalWidth
); |
119 maxLogicalWidth = std::max(maxPreferredLogicalWidth, maxLogicalWidth
); | 119 maxLogicalWidth = std::max(maxPreferredLogicalWidth, maxLogicalWidth
); |
120 } | 120 } |
121 } | 121 } |
122 | 122 |
123 maxLogicalWidth = std::max(minLogicalWidth, maxLogicalWidth); | 123 maxLogicalWidth = std::max(minLogicalWidth, maxLogicalWidth); |
124 | 124 |
125 LayoutUnit scrollbarWidth = instrinsicScrollbarLogicalWidth(); | 125 LayoutUnit scrollbarWidth = intrinsicScrollbarLogicalWidth(); |
126 maxLogicalWidth += scrollbarWidth; | 126 maxLogicalWidth += scrollbarWidth; |
127 minLogicalWidth += scrollbarWidth; | 127 minLogicalWidth += scrollbarWidth; |
128 } | 128 } |
129 | 129 |
130 static int synthesizedBaselineFromContentBox(const RenderBox* box, LineDirection
Mode direction) | 130 static int synthesizedBaselineFromContentBox(const RenderBox* box, LineDirection
Mode direction) |
131 { | 131 { |
132 return direction == HorizontalLine ? box->borderTop() + box->paddingTop() +
box->contentHeight() : box->borderRight() + box->paddingRight() + box->contentWi
dth(); | 132 return direction == HorizontalLine ? box->borderTop() + box->paddingTop() +
box->contentHeight() : box->borderRight() + box->paddingRight() + box->contentWi
dth(); |
133 } | 133 } |
134 | 134 |
135 int RenderFlexibleBox::baselinePosition(FontBaseline, bool, LineDirectionMode di
rection, LinePositionMode mode) const | 135 int RenderFlexibleBox::baselinePosition(FontBaseline, bool, LineDirectionMode di
rection, LinePositionMode mode) const |
(...skipping 1265 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1401 ASSERT(child); | 1401 ASSERT(child); |
1402 LayoutUnit lineCrossAxisExtent = lineContexts[lineNumber].crossAxisE
xtent; | 1402 LayoutUnit lineCrossAxisExtent = lineContexts[lineNumber].crossAxisE
xtent; |
1403 LayoutUnit originalOffset = lineContexts[lineNumber].crossAxisOffset
- crossAxisStartEdge; | 1403 LayoutUnit originalOffset = lineContexts[lineNumber].crossAxisOffset
- crossAxisStartEdge; |
1404 LayoutUnit newOffset = contentExtent - originalOffset - lineCrossAxi
sExtent; | 1404 LayoutUnit newOffset = contentExtent - originalOffset - lineCrossAxi
sExtent; |
1405 adjustAlignmentForChild(child, newOffset - originalOffset); | 1405 adjustAlignmentForChild(child, newOffset - originalOffset); |
1406 } | 1406 } |
1407 } | 1407 } |
1408 } | 1408 } |
1409 | 1409 |
1410 } | 1410 } |
OLD | NEW |