[webkit-changes] cvs commit: WebCore/khtml/rendering
render_form.cpp render_replaced.cpp
Timothy
thatcher at opensource.apple.com
Fri Nov 11 10:21:07 PST 2005
thatcher 05/11/11 10:21:07
Modified: . Tag: Safari-2-0-branch ChangeLog
khtml/rendering Tag: Safari-2-0-branch render_form.cpp
render_replaced.cpp
Log:
Merged fix from TOT to Safari-2-0-branch
2005-11-11 Beth Dakin <bdakin at apple.com>
Reviewed by Hyatt.
Fix for <rdar://problem/3952698> Function buttons do not display
properly with Telia Webmail (3488).
Replaced elements with a percentage width used to be given a minimum
width of 0. This caused buttons etc with width:100% to overlap when
they shouldn't. Textareas and text boxes are still given a minimum
width of 0 because they need slightly different behavior to match
WinIE. I filed <rdar://problem/4339518> to track this remaining problem.
* khtml/rendering/render_form.cpp:
(RenderLineEdit::calcMinMaxWidth): Still give text fields a m_minWidth of 0.
(RenderTextArea::calcMinMaxWidth): And textareas.
* khtml/rendering/render_replaced.cpp:
(RenderReplaced::calcMinMaxWidth): Remove the check for width().isPercent()
when making m_minWidth 0.
Revision Changes Path
No revision
No revision
1.1.2.54 +24 -0 WebCore/ChangeLog
Index: ChangeLog
===================================================================
RCS file: /cvs/root/WebCore/ChangeLog,v
retrieving revision 1.1.2.53
retrieving revision 1.1.2.54
diff -u -r1.1.2.53 -r1.1.2.54
--- ChangeLog 11 Nov 2005 06:39:20 -0000 1.1.2.53
+++ ChangeLog 11 Nov 2005 18:21:01 -0000 1.1.2.54
@@ -1,3 +1,27 @@
+2005-11-11 Timothy Hatcher <timothy at apple.com>
+
+ Merged fix from TOT to Safari-2-0-branch
+
+ 2005-11-11 Beth Dakin <bdakin at apple.com>
+
+ Reviewed by Hyatt.
+
+ Fix for <rdar://problem/3952698> Function buttons do not display
+ properly with Telia Webmail (3488).
+
+ Replaced elements with a percentage width used to be given a minimum
+ width of 0. This caused buttons etc with width:100% to overlap when
+ they shouldn't. Textareas and text boxes are still given a minimum
+ width of 0 because they need slightly different behavior to match
+ WinIE. I filed <rdar://problem/4339518> to track this remaining problem.
+
+ * khtml/rendering/render_form.cpp:
+ (RenderLineEdit::calcMinMaxWidth): Still give text fields a m_minWidth of 0.
+ (RenderTextArea::calcMinMaxWidth): And textareas.
+ * khtml/rendering/render_replaced.cpp:
+ (RenderReplaced::calcMinMaxWidth): Remove the check for width().isPercent()
+ when making m_minWidth 0.
+
2005-11-10 Timothy Hatcher <timothy at apple.com>
Merged fix from TOT to Safari-2-0-branch
No revision
No revision
1.102.8.7 +14 -0 WebCore/khtml/rendering/render_form.cpp
Index: render_form.cpp
===================================================================
RCS file: /cvs/root/WebCore/khtml/rendering/render_form.cpp,v
retrieving revision 1.102.8.6
retrieving revision 1.102.8.7
diff -u -r1.102.8.6 -r1.102.8.7
--- render_form.cpp 11 Nov 2005 06:39:32 -0000 1.102.8.6
+++ render_form.cpp 11 Nov 2005 18:21:05 -0000 1.102.8.7
@@ -624,6 +624,13 @@
setIntrinsicHeight( s.height() );
RenderFormElement::calcMinMaxWidth();
+
+ // FIXME: m_minWidth should not really be set to 0. If textfields
+ // have value text in them to begin with, then to match WinIE the
+ // field should only be as wide as the text. Setting m_minWidth to
+ // 0 also makes textfields with width:100% overlap.
+ if (style()->width().isPercent())
+ m_minWidth = 0;
}
void RenderLineEdit::setStyle(RenderStyle *s)
@@ -1570,6 +1577,13 @@
setIntrinsicHeight( size.height() );
RenderFormElement::calcMinMaxWidth();
+
+ // FIXME: m_minWidth should not really be set to 0. If textareas
+ // have value text in them to begin with, then to match WinIE the
+ // textarea should only be as wide as the text. Setting m_minWidth
+ // to 0 also makes textareas with width:100% overlap.
+ if (style()->width().isPercent())
+ m_minWidth = 0;
}
void RenderTextArea::setStyle(RenderStyle *s)
1.75.8.3 +2 -3 WebCore/khtml/rendering/render_replaced.cpp
Index: render_replaced.cpp
===================================================================
RCS file: /cvs/root/WebCore/khtml/rendering/render_replaced.cpp,v
retrieving revision 1.75.8.2
retrieving revision 1.75.8.3
diff -u -r1.75.8.2 -r1.75.8.3
--- render_replaced.cpp 9 Aug 2005 23:52:16 -0000 1.75.8.2
+++ render_replaced.cpp 11 Nov 2005 18:21:06 -0000 1.75.8.3
@@ -98,11 +98,10 @@
#endif
int width = calcReplacedWidth() + paddingLeft() + paddingRight() + borderLeft() + borderRight();
- if (style()->width().isPercent() || (style()->width().isVariable() && style()->height().isPercent())) {
+ if (style()->width().isAuto() && style()->height().isPercent()) {
m_minWidth = 0;
m_maxWidth = width;
- }
- else
+ } else
m_minWidth = m_maxWidth = width;
setMinMaxKnown();
More information about the webkit-changes
mailing list