Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(943)

Unified Diff: Source/core/html/shadow/SpinButtonElement.cpp

Issue 128133002: Update of change event for input type number (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: OnChange event for input type number Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/html/forms/TextFieldInputType.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/shadow/SpinButtonElement.cpp
diff --git a/Source/core/html/shadow/SpinButtonElement.cpp b/Source/core/html/shadow/SpinButtonElement.cpp
index e0e30ae17a3cb02deea90ef60495bdf139a18277..881e922c8904635600e84ba3b2ab3fca7938d0ae 100644
--- a/Source/core/html/shadow/SpinButtonElement.cpp
+++ b/Source/core/html/shadow/SpinButtonElement.cpp
@@ -31,6 +31,7 @@
#include "core/events/MouseEvent.h"
#include "core/events/ThreadLocalEventNames.h"
#include "core/events/WheelEvent.h"
+#include "core/html/HTMLInputElement.h"
#include "core/html/shadow/ShadowElementNames.h"
#include "core/page/Chrome.h"
#include "core/page/EventHandler.h"
@@ -111,9 +112,11 @@ void SpinButtonElement::defaultEventHandler(Event* event)
}
event->setDefaultHandled();
}
- } else if (mouseEvent->type() == EventTypeNames::mouseup && mouseEvent->button() == LeftButton)
+ } else if (mouseEvent->type() == EventTypeNames::mouseup && mouseEvent->button() == LeftButton) {
stopRepeatingTimer();
- else if (event->type() == EventTypeNames::mousemove) {
+ HTMLInputElement* input = toHTMLInputElement(shadowHost());
+ input->dispatchFormControlChangeEvent();
tkent 2014/01/15 00:19:44 We need to call it in SpinButtonElement::releaseCa
+ } else if (event->type() == EventTypeNames::mousemove) {
if (box->pixelSnappedBorderBoxRect().contains(local)) {
if (!m_capturing) {
if (Frame* frame = document().frame()) {
« no previous file with comments | « Source/core/html/forms/TextFieldInputType.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698