Closed Bug 347687 Opened 14 years ago Closed 14 years ago
notifications for autocomplete actions
Currently it's not possible to hook into the autocomplete mechanism to see when the textbox value has been completed. autocomplete.xml fires "events", but those are really just calling the corresponding attribute value as a function. They're also too late, in the case of textentered, to get details like which index was selected.
This isn't ideal -- there's clearly some duplication here with the actions executed by autocomplete.xml. However, I believe this is the safest approach for Firefox 2 (which I'm aiming for with this patch) because it doesn't change any event ordering.
Attachment #232481 - Flags: first-review?(brettw)
Attachment #232481 - Flags: first-review?(brettw) → first-review+
Comment on attachment 232481 [details] [diff] [review] ObserverService approach This is actually not the best time to send the text-entered notification. The value has already been filled, so we can't tell how many characters had been typed before filling.
Attachment #232481 - Attachment is obsolete: true
This is a little more flexible and lets observers inspect the state of the input before the value is filled or reverted.
Attachment #232645 - Flags: first-review?(brettw)
Attachment #232645 - Flags: first-review?(brettw) → first-review+
Comment on attachment 232645 [details] [diff] [review] ObserverService approach, v2 Requesting approval to get this in before the freeze... this is extremely low risk and would be a huge help for the metrics extension.
Attachment #232645 - Flags: approval1.8.1?
Comment on attachment 232645 [details] [diff] [review] ObserverService approach, v2 a=drivers. What's the performance impact on this? Any way to test and track that?
Attachment #232645 - Flags: approval1.8.1? → approval1.8.1+
Comment on attachment 232645 [details] [diff] [review] ObserverService approach, v2 It'll be negligable (that's as close as I'll get to "nonexistent"), just a tiny amount of function call overhead when the user clicks or presses enter on a highlighted row in the url or search bar autocomplete popup. To measure it reliably you'd need a scripted UI test that invoked autocomplete.
checked in on trunk and branch
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.