From dcfbbb079942b45cf3b3007fcd0c7e0fce4bb2cc Mon Sep 17 00:00:00 2001 From: Hannes Janetzek Date: Thu, 13 May 2010 05:31:06 +0000 Subject: [PATCH] sort non-toplevel plugins in aggregator correctly SVN revision: 48804 --- src/modules/everything-files/e_mod_main.c | 7 +++++-- src/modules/everything/evry_plug_aggregator.c | 16 +++++++++++----- 2 files changed, 16 insertions(+), 7 deletions(-) diff --git a/src/modules/everything-files/e_mod_main.c b/src/modules/everything-files/e_mod_main.c index 769feb8a4..2e555b63b 100644 --- a/src/modules/everything-files/e_mod_main.c +++ b/src/modules/everything-files/e_mod_main.c @@ -1305,8 +1305,11 @@ _plugins_init(const Evry_API *api) _recentf_begin, _finish, _recentf_fetch); p->browse = &_recentf_browse; if (evry->plugin_register(p, EVRY_PLUGIN_SUBJECT, 3)) - p->config->min_query = 3; - + { + p->config->top_level = EINA_FALSE; + p->config->min_query = 3; + } + PLUGIN_NEW(N_("Recent Files"), _module_icon, _recentf_begin, _finish, _recentf_fetch); p->browse = &_recentf_browse; diff --git a/src/modules/everything/evry_plug_aggregator.c b/src/modules/everything/evry_plug_aggregator.c index ffcc0f68d..eb268a997 100644 --- a/src/modules/everything/evry_plug_aggregator.c +++ b/src/modules/everything/evry_plug_aggregator.c @@ -102,11 +102,17 @@ _fetch(Evry_Plugin *plugin, const char *input) if (!pp->items) continue; - it->fuzzy_match = evry_fuzzy_match(it->label, input); - it->hi = NULL; - evry_history_item_usage_set(it, NULL, NULL); - + it->usage = 0; + it->fuzzy_match = 0; + + if (input) + { + evry_history_item_usage_set(it, NULL, NULL); + it->usage /= 2.0; + it->fuzzy_match = 5; + } + snprintf(buf, sizeof(buf), "%d %s", eina_list_count(pp->items), _("Items")); if (it->detail) eina_stringshare_del(it->detail); @@ -253,7 +259,7 @@ evry_plug_aggregator_new(Evry_Selector *sel, int type) Evry_Plugin *p; p = EVRY_PLUGIN_NEW(Plugin, N_("All"), NULL, 0, NULL, _finish, _fetch, _free); - p->history = EINA_FALSE; + if (evry_plugin_register(p, type, -1)) { p->config->view_mode = VIEW_MODE_THUMB;