[Webkit-unassigned] [Bug 60010] [Chromium]Add clear_autofill flag to hide autofill popup without clear field.
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue May 3 01:30:16 PDT 2011
https://bugs.webkit.org/show_bug.cgi?id=60010
--- Comment #6 from Ilya Sherman <isherman at chromium.org> 2011-05-03 01:30:16 PST ---
(In reply to comment #4)
> If you say "Accept" means choosing item in autofill popup with keyboard, for example, the following function is called.
>
> 1061 void PopupListBox::acceptIndex(int index)
> 1062 {
> 1063 // Clear m_acceptedIndexOnAbandon once user accepts the selected index.
> 1064 if (m_acceptedIndexOnAbandon >= 0)
> 1065 m_acceptedIndexOnAbandon = -1;
> 1066
> 1067 if (index >= numItems())
> 1068 return;
> 1069
> 1070 if (index < 0) {
> 1071 if (m_popupClient) {
> 1072 // Enter pressed with no selection, just close the popup.
> 1073 hidePopup();
> 1074 }
> 1075 return;
> 1076 }
> 1077
> 1078 if (isSelectableItem(index)) {
> 1079 RefPtr<PopupListBox> keepAlive(this);
> 1080
> 1081 // Hide ourselves first since valueChanged may have numerous side-effects.
> 1082 hidePopup();
> 1083
> 1084 // Tell the <select> PopupMenuClient what index was selected.
> 1085 m_popupClient->valueChanged(index);
> 1086 }
> 1087 }
>
> But, as you know, hidePopup() is the same function which I try to call from startDragging and then the function calls m_popupClient->valueChanged(index); here.
>
> Actually valueChange() calls didAcceptAutoFillSuggestion() internally, if we follow the same way as this, we have to call didAcceptAutoFillSuggestion().
>
> But didAcceptAutoFillSuggestion() needs webnode information which is difficult to access outside of m_popupClient.
>
> Maybe we can make a special function to accept current index, but it it very long path to access from WebView...
This (accepting the current index when a drag is initiated) is probably the right solution -- at least in terms of the functionality it implies. I'm not sure if there is perhaps an easier way to write the code.
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list