| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2010 Apple Inc. All rights reserv
ed. | 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2010 Apple Inc. All rights reserv
ed. |
| 6 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) | 6 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) |
| 7 * Copyright (C) 2007 Samuel Weinig (sam@webkit.org) | 7 * Copyright (C) 2007 Samuel Weinig (sam@webkit.org) |
| 8 * | 8 * |
| 9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
| 10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
| 11 * License as published by the Free Software Foundation; either | 11 * License as published by the Free Software Foundation; either |
| 12 * version 2 of the License, or (at your option) any later version. | 12 * version 2 of the License, or (at your option) any later version. |
| 13 * | 13 * |
| 14 * This library is distributed in the hope that it will be useful, | 14 * This library is distributed in the hope that it will be useful, |
| 15 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 15 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | 16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 17 * Library General Public License for more details. | 17 * Library General Public License for more details. |
| 18 * | 18 * |
| 19 * You should have received a copy of the GNU Library General Public License | 19 * You should have received a copy of the GNU Library General Public License |
| 20 * along with this library; see the file COPYING.LIB. If not, write to | 20 * along with this library; see the file COPYING.LIB. If not, write to |
| 21 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | 21 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
| 22 * Boston, MA 02110-1301, USA. | 22 * Boston, MA 02110-1301, USA. |
| 23 * | 23 * |
| 24 */ | 24 */ |
| 25 | 25 |
| 26 #include "config.h" | 26 #include "config.h" |
| 27 #include "HTMLTextAreaElement.h" | 27 #include "core/html/HTMLTextAreaElement.h" |
| 28 | 28 |
| 29 #include "CSSValueKeywords.h" | 29 #include "CSSValueKeywords.h" |
| 30 #include "FormController.h" | |
| 31 #include "FormDataList.h" | |
| 32 #include "HTMLNames.h" | 30 #include "HTMLNames.h" |
| 33 #include "core/dom/Attribute.h" | 31 #include "core/dom/Attribute.h" |
| 34 #include "core/dom/BeforeTextInsertedEvent.h" | 32 #include "core/dom/BeforeTextInsertedEvent.h" |
| 35 #include "core/dom/Document.h" | 33 #include "core/dom/Document.h" |
| 36 #include "core/dom/ElementShadow.h" | 34 #include "core/dom/ElementShadow.h" |
| 37 #include "core/dom/Event.h" | 35 #include "core/dom/Event.h" |
| 38 #include "core/dom/EventNames.h" | 36 #include "core/dom/EventNames.h" |
| 39 #include "core/dom/ExceptionCode.h" | 37 #include "core/dom/ExceptionCode.h" |
| 40 #include "core/dom/ExceptionCodePlaceholder.h" | 38 #include "core/dom/ExceptionCodePlaceholder.h" |
| 41 #include "core/dom/ShadowRoot.h" | 39 #include "core/dom/ShadowRoot.h" |
| 42 #include "core/dom/Text.h" | 40 #include "core/dom/Text.h" |
| 43 #include "core/editing/Editor.h" | 41 #include "core/editing/Editor.h" |
| 44 #include "core/editing/FrameSelection.h" | 42 #include "core/editing/FrameSelection.h" |
| 45 #include "core/editing/TextIterator.h" | 43 #include "core/editing/TextIterator.h" |
| 44 #include "core/html/FormController.h" |
| 45 #include "core/html/FormDataList.h" |
| 46 #include "core/html/shadow/TextControlInnerElements.h" | 46 #include "core/html/shadow/TextControlInnerElements.h" |
| 47 #include "core/page/EventHandler.h" | 47 #include "core/page/EventHandler.h" |
| 48 #include "core/page/Frame.h" | 48 #include "core/page/Frame.h" |
| 49 #include "core/platform/LocalizedStrings.h" | 49 #include "core/platform/LocalizedStrings.h" |
| 50 #include "core/rendering/RenderTextControlMultiLine.h" | 50 #include "core/rendering/RenderTextControlMultiLine.h" |
| 51 #include <wtf/StdLibExtras.h> | 51 #include <wtf/StdLibExtras.h> |
| 52 #include <wtf/text/StringBuilder.h> | 52 #include <wtf/text/StringBuilder.h> |
| 53 | 53 |
| 54 namespace WebCore { | 54 namespace WebCore { |
| 55 | 55 |
| (...skipping 499 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 555 RefPtr<HTMLDivElement> placeholder = HTMLDivElement::create(document()); | 555 RefPtr<HTMLDivElement> placeholder = HTMLDivElement::create(document()); |
| 556 m_placeholder = placeholder.get(); | 556 m_placeholder = placeholder.get(); |
| 557 m_placeholder->setPseudo(AtomicString("-webkit-input-placeholder", Atomi
cString::ConstructFromLiteral)); | 557 m_placeholder->setPseudo(AtomicString("-webkit-input-placeholder", Atomi
cString::ConstructFromLiteral)); |
| 558 userAgentShadowRoot()->insertBefore(m_placeholder, innerTextElement()->n
extSibling(), ASSERT_NO_EXCEPTION); | 558 userAgentShadowRoot()->insertBefore(m_placeholder, innerTextElement()->n
extSibling(), ASSERT_NO_EXCEPTION); |
| 559 } | 559 } |
| 560 m_placeholder->setInnerText(placeholderText, ASSERT_NO_EXCEPTION); | 560 m_placeholder->setInnerText(placeholderText, ASSERT_NO_EXCEPTION); |
| 561 fixPlaceholderRenderer(m_placeholder, innerTextElement()); | 561 fixPlaceholderRenderer(m_placeholder, innerTextElement()); |
| 562 } | 562 } |
| 563 | 563 |
| 564 } | 564 } |
| OLD | NEW |