search: Rename search_providers to open-search-providers
We will allow applications to hook into shell's search by registering a service which implements a well-known DBus interface. "search-providers" is a reasonable directory name for applications to drop their registration files, but it conflicts with "search_providers" used by open search providers - rename the latter to avoid confusion. https://bugzilla.gnome.org/show_bug.cgi?id=663125
This commit is contained in:
parent
e2c66ce48a
commit
89fe43f70c
@ -12,10 +12,10 @@ desktop_DATA = gnome-shell.desktop gnome-shell-extension-prefs.desktop
|
|||||||
%.desktop:%.desktop.in
|
%.desktop:%.desktop.in
|
||||||
$(AM_V_GEN) sed s/^_// < $< > $@ || rm $@
|
$(AM_V_GEN) sed s/^_// < $< > $@ || rm $@
|
||||||
|
|
||||||
searchprovidersdir = $(pkgdatadir)/search_providers
|
searchprovidersdir = $(pkgdatadir)/open-search-providers
|
||||||
dist_searchproviders_DATA = \
|
dist_searchproviders_DATA = \
|
||||||
search_providers/google.xml \
|
open-search-providers/google.xml \
|
||||||
search_providers/wikipedia.xml
|
open-search-providers/wikipedia.xml
|
||||||
|
|
||||||
themedir = $(pkgdatadir)/theme
|
themedir = $(pkgdatadir)/theme
|
||||||
dist_theme_DATA = \
|
dist_theme_DATA = \
|
||||||
|
@ -310,7 +310,7 @@ const OpenSearchSystem = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
_addProvider: function(fileName) {
|
_addProvider: function(fileName) {
|
||||||
let path = global.datadir + '/search_providers/' + fileName;
|
let path = global.datadir + '/open-search-providers/' + fileName;
|
||||||
let source = Shell.get_file_contents_utf8_sync(path);
|
let source = Shell.get_file_contents_utf8_sync(path);
|
||||||
let [success, name, url, langs, icon_uri] = Shell.parse_search_provider(source);
|
let [success, name, url, langs, icon_uri] = Shell.parse_search_provider(source);
|
||||||
let provider ={ name: name,
|
let provider ={ name: name,
|
||||||
@ -327,7 +327,7 @@ const OpenSearchSystem = new Lang.Class({
|
|||||||
_refresh: function() {
|
_refresh: function() {
|
||||||
this._providers = [];
|
this._providers = [];
|
||||||
let names = global.settings.get_strv(DISABLED_OPEN_SEARCH_PROVIDERS_KEY);
|
let names = global.settings.get_strv(DISABLED_OPEN_SEARCH_PROVIDERS_KEY);
|
||||||
let file = Gio.file_new_for_path(global.datadir + '/search_providers');
|
let file = Gio.file_new_for_path(global.datadir + '/open-search-providers');
|
||||||
FileUtils.listDirAsync(file, Lang.bind(this, function(files) {
|
FileUtils.listDirAsync(file, Lang.bind(this, function(files) {
|
||||||
for (let i = 0; i < files.length; i++) {
|
for (let i = 0; i < files.length; i++) {
|
||||||
let enabled = true;
|
let enabled = true;
|
||||||
|
Loading…
Reference in New Issue
Block a user