From 190dc282b875861bfe3867e763eaf0eede7bf76c Mon Sep 17 00:00:00 2001 From: Jacek Jendrzej Date: Tue, 4 Dec 2012 19:57:02 +0100 Subject: [PATCH] src/gui/plugins.cpp: fix sort pluins without index Origin commit data ------------------ Commit: https://github.com/neutrino-images/ni-neutrino/commit/882a7b2e4708d29bbb9c2f69056c4fa986220b42 Author: Jacek Jendrzej Date: 2012-12-04 (Tue, 04 Dec 2012) --- src/gui/plugins.cpp | 4 ++-- src/gui/plugins.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/gui/plugins.cpp b/src/gui/plugins.cpp index 80836e7a1..2698ad2f7 100644 --- a/src/gui/plugins.cpp +++ b/src/gui/plugins.cpp @@ -156,7 +156,7 @@ void CPlugins::loadPlugins() frameBuffer = CFrameBuffer::getInstance(); number_of_plugins = 0; plugin_list.clear(); - + sindex = 100; scanDir(g_settings.plugin_hdd_dir.c_str()); scanDir(PLUGINDIR_USB); scanDir(PLUGINDIR_VAR); @@ -184,7 +184,7 @@ bool CPlugins::parseCfg(plugin *plugin_data) while (linecount < 20 && getline(inFile, line[linecount++])) {}; - plugin_data->index = 0; + plugin_data->index = sindex++; plugin_data->key = 0; //CRCInput::RC_nokey plugin_data->fb = false; plugin_data->rc = false; diff --git a/src/gui/plugins.h b/src/gui/plugins.h index f37cc0704..501e6172c 100644 --- a/src/gui/plugins.h +++ b/src/gui/plugins.h @@ -88,7 +88,7 @@ class CPlugins }; int number_of_plugins; - + int sindex; std::vector plugin_list; std::string plugin_dir; std::string scriptOutput;