Bug 1355460 Comment 1 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

This should be behind a pref, a boolean browser.places.speculativeConnect.enabled would probably be fine, since it mirrors the browser.urlbar. one.
For testing, I assume here we'll add an helper method to PlacesUIUtils, the test can then use the Sinon library to replace the method with a Spy, and just check it's invoked.
We'd also support this only for views that allow a single selection, so menus and toolbars. The trees are often used to manage and move bookmarks around with D&D, and we don't want those actions to begin connections.
This should be behind a pref, a boolean browser.places.speculativeConnect.enabled would probably be fine, since it mirrors the browser.urlbar. one.
For testing, I assume here we'll add an helper method to PlacesUIUtils, the test can then use the Sinon library to replace the method with a Spy, and just check it's invoked.
We'd also support this only for views that allow a single selection, so menus and toolbars. The trees are often used to manage and move bookmarks around with D&D, and we don't want those actions to begin connections.

This is an example of how the Urlbar implements it: https://searchfox.org/mozilla-central/rev/dc323d0d9a3b722ca8ff0d1b2b752e5bd00dab9b/browser/components/urlbar/UrlbarUtils.jsm#728-730,753-757

Back to Bug 1355460 Comment 1