diff options
Diffstat (limited to 'WebCore/rendering/RenderTextControlSingleLine.cpp')
-rw-r--r-- | WebCore/rendering/RenderTextControlSingleLine.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/WebCore/rendering/RenderTextControlSingleLine.cpp b/WebCore/rendering/RenderTextControlSingleLine.cpp index 37d44c4..f454c63 100644 --- a/WebCore/rendering/RenderTextControlSingleLine.cpp +++ b/WebCore/rendering/RenderTextControlSingleLine.cpp @@ -569,8 +569,10 @@ void RenderTextControlSingleLine::updateFromElement() updateCancelButtonVisibility(); if (m_placeholderVisible) { + // node() must be an HTMLInputElement. WMLInputElement doesn't support placeholder. + ASSERT(node()->isHTMLElement()); ExceptionCode ec = 0; - innerTextElement()->setInnerText(static_cast<Element*>(node())->getAttribute(placeholderAttr), ec); + innerTextElement()->setInnerText(static_cast<HTMLInputElement*>(node())->strippedPlaceholder(), ec); ASSERT(!ec); } else { if (!inputElement()->suggestedValue().isNull()) |