| Index: Source/core/rendering/RenderTextControl.cpp
|
| diff --git a/Source/core/rendering/RenderTextControl.cpp b/Source/core/rendering/RenderTextControl.cpp
|
| index 690a1c43c11763477ca478f40b6409d78f4a3bd6..9b53a77c482dfeba177e36d18d4e1c455e3dacb5 100644
|
| --- a/Source/core/rendering/RenderTextControl.cpp
|
| +++ b/Source/core/rendering/RenderTextControl.cpp
|
| @@ -254,20 +254,21 @@ void RenderTextControl::computePreferredLogicalWidths()
|
|
|
| m_minPreferredLogicalWidth = 0;
|
| m_maxPreferredLogicalWidth = 0;
|
| + RenderStyle* styleToUse = style();
|
|
|
| - if (style()->logicalWidth().isFixed() && style()->logicalWidth().value() >= 0)
|
| - m_minPreferredLogicalWidth = m_maxPreferredLogicalWidth = adjustContentBoxLogicalWidthForBoxSizing(style()->logicalWidth().value());
|
| + if (styleToUse->logicalWidth().isFixed() && styleToUse->logicalWidth().value() >= 0)
|
| + m_minPreferredLogicalWidth = m_maxPreferredLogicalWidth = adjustContentBoxLogicalWidthForBoxSizing(styleToUse->logicalWidth().value());
|
| else
|
| computeIntrinsicLogicalWidths(m_minPreferredLogicalWidth, m_maxPreferredLogicalWidth);
|
|
|
| - if (style()->logicalMinWidth().isFixed() && style()->logicalMinWidth().value() > 0) {
|
| - m_maxPreferredLogicalWidth = max(m_maxPreferredLogicalWidth, adjustContentBoxLogicalWidthForBoxSizing(style()->logicalMinWidth().value()));
|
| - m_minPreferredLogicalWidth = max(m_minPreferredLogicalWidth, adjustContentBoxLogicalWidthForBoxSizing(style()->logicalMinWidth().value()));
|
| + if (styleToUse->logicalMinWidth().isFixed() && styleToUse->logicalMinWidth().value() > 0) {
|
| + m_maxPreferredLogicalWidth = max(m_maxPreferredLogicalWidth, adjustContentBoxLogicalWidthForBoxSizing(styleToUse->logicalMinWidth().value()));
|
| + m_minPreferredLogicalWidth = max(m_minPreferredLogicalWidth, adjustContentBoxLogicalWidthForBoxSizing(styleToUse->logicalMinWidth().value()));
|
| }
|
|
|
| - if (style()->logicalMaxWidth().isFixed()) {
|
| - m_maxPreferredLogicalWidth = min(m_maxPreferredLogicalWidth, adjustContentBoxLogicalWidthForBoxSizing(style()->logicalMaxWidth().value()));
|
| - m_minPreferredLogicalWidth = min(m_minPreferredLogicalWidth, adjustContentBoxLogicalWidthForBoxSizing(style()->logicalMaxWidth().value()));
|
| + if (styleToUse->logicalMaxWidth().isFixed()) {
|
| + m_maxPreferredLogicalWidth = min(m_maxPreferredLogicalWidth, adjustContentBoxLogicalWidthForBoxSizing(styleToUse->logicalMaxWidth().value()));
|
| + m_minPreferredLogicalWidth = min(m_minPreferredLogicalWidth, adjustContentBoxLogicalWidthForBoxSizing(styleToUse->logicalMaxWidth().value()));
|
| }
|
|
|
| LayoutUnit toAdd = borderAndPaddingLogicalWidth();
|
|
|