GNOME Bugzilla – Bug 658113
Seach provider can no longer be registered by extensions
Last modified: 2011-09-04 11:35:28 UTC
Since this commit: commit 80a9d2e7c9f1ebc3bed6ae6356ff1675a7c9ef62 Author: Ray Strode <rstrode@redhat.com> Date: Sun Aug 28 09:29:51 2011 -0400 overview: Make viewSelector private It's only used internally by the overview itself, and by some performance testing code, so don't expose it as a public object. https://bugzilla.gnome.org/show_bug.cgi?id=657082 It was actually useful to have the viewSelector public...
Created attachment 195559 [details] [review] overview: make viewSelector public again It's useful to have it public so that extensions (for example) can easily add Search Providers.
Given that public/private are mere conventions, saying that extensions cannot register search providers is a bit of a stretch ...
Review of attachment 195559 [details] [review]: If we want to revert Ray's commit, it should be done as an actual revert. However, as the viewSelector is likely to be killed when implementing "mode-less overview" [0], adding a public overview.addSearchProvider() method (which for now just calls this._viewSelector.addSearchProvider()) will hopefully be less disruptive for extensions. [0] http://jimmac.musichall.cz/log/?p=1181
Created attachment 195562 [details] [review] overview: addSearchProvider API New API to ease addition of Search Providers, especially for extensions.
I'll update bug 657548 as well, thanks for the feedback Florian.
Review of attachment 195562 [details] [review]: Code looks good to me, but the commit message needs a bit of improvement - neither subject nor body are valid sentences: Something like overview: Add addSearchProvider API Add a public API to add new search providers, so extensions don't have to access the view selector directly, which is now a private property of the overview. (If you don't like the "Add add" repetition in the subject line, feel free to come up with something less awkward ...)
Thank you Florian, can you please push the patch?
Comment on attachment 195562 [details] [review] overview: addSearchProvider API Pushed as 8b796e745 - overview: Add public API to add search providers