Number type input cannot be set to empty string if it has an initial value
Created attachment 81158 [details] Patch
Created attachment 84148 [details] Patch 2 Rebased
Comment on attachment 84148 [details] Patch 2 View in context: https://bugs.webkit.org/attachment.cgi?id=84148&action=review > Source/WebCore/dom/InputElement.h:120 > + // represents the emtpy value. Typo here, “empty”. > Source/WebCore/html/NumberInputType.cpp:281 > + return parseToDoubleForNumberType(proposedValue, 0) ? proposedValue : String(""); It’s more efficient to use emptyAtom here instead of String("").
Comment on attachment 84148 [details] Patch 2 View in context: https://bugs.webkit.org/attachment.cgi?id=84148&action=review Thank you for reviewing! Landed as http://trac.webkit.org/changeset/79954 with the following fixes. >> Source/WebCore/dom/InputElement.h:120 >> + // represents the emtpy value. > > Typo here, “empty”. Fixed. >> Source/WebCore/html/NumberInputType.cpp:281 >> + return parseToDoubleForNumberType(proposedValue, 0) ? proposedValue : String(""); > > It’s more efficient to use emptyAtom here instead of String(""). Fixed.