| Index: Source/core/html/HTMLTextFormControlElement.cpp
|
| diff --git a/Source/core/html/HTMLTextFormControlElement.cpp b/Source/core/html/HTMLTextFormControlElement.cpp
|
| index c3f751a63f54d4eb643bdb97275b0ecbe1ae555c..bf3597a17159f2e0cad756e6e8be0ffc25b2bc4c 100644
|
| --- a/Source/core/html/HTMLTextFormControlElement.cpp
|
| +++ b/Source/core/html/HTMLTextFormControlElement.cpp
|
| @@ -182,11 +182,17 @@ void HTMLTextFormControlElement::select()
|
| setSelectionRange(0, numeric_limits<int>::max(), SelectionHasNoDirection);
|
| }
|
|
|
| +bool HTMLTextFormControlElement::shouldDispatchFormControlChangeEvent(String& oldValue, String& newValue)
|
| +{
|
| + return !equalIgnoringNullity(oldValue, newValue);
|
| +}
|
| +
|
| void HTMLTextFormControlElement::dispatchFormControlChangeEvent()
|
| {
|
| - if (!equalIgnoringNullity(m_textAsOfLastFormControlChangeEvent, value())) {
|
| + String newValue = value();
|
| + if (shouldDispatchFormControlChangeEvent(m_textAsOfLastFormControlChangeEvent, newValue)) {
|
| dispatchChangeEvent();
|
| - setTextAsOfLastFormControlChangeEvent(value());
|
| + setTextAsOfLastFormControlChangeEvent(newValue);
|
| }
|
| setChangedSinceLastFormControlChangeEvent(false);
|
| }
|
|
|