[iOS] Multiple select appearance doesn't update when selecting or deselecting rows in the picker view
https://bugs.webkit.org/show_bug.cgi?id=184110
<rdar://problem/
38796648>
Reviewed by Tim Horton.
Source/WebCore:
HTMLSelectElement::optionSelectedByUser is invoked upon user interaction with a select menu. This currently
takes two separate codepaths, depending on whether or not the menu list appearance is being used to render the
select. If a menu list appearance is used, we call selectOption(), which updates validity, updates the element
renderer, and then dispatches a `change` event if needed.
However, if updateSelectedState() is used, we only update form validity and then dispatch the `change` event
without updating the renderer, leaving it stale.
Test: fast/forms/ios/ipad/multiple-select-updates-renderer.html
* html/HTMLSelectElement.cpp:
(WebCore::HTMLSelectElement::optionSelectedByUser):
Update the renderer after updating the DOM to reflect the selected option.
LayoutTests:
Adds a new layout test to verify that after tapping on a multiple select and choosing an option, the select's
renderer is updated to reflect its new state.
* fast/forms/ios/ipad/multiple-select-updates-renderer-expected.txt: Added.
* fast/forms/ios/ipad/multiple-select-updates-renderer.html: Added.
* resources/basic-gestures.js:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@230055
268f45cc-cd09-0410-ab3c-
d52691b4dbfc