miscsettings_menu.cpp: epg_read_now, epg_read_now_usermenu implement ShowHintS

This commit is contained in:
2021-10-08 22:36:54 +02:00
parent df182b4b37
commit 14aa145cc1

View File

@@ -163,25 +163,21 @@ int CMiscMenue::exec(CMenuTarget* parent, const std::string &actionKey)
}
else if(actionKey == "epg_read_now" || actionKey == "epg_read_now_usermenu")
{
CHint *hint = new CHint(LOCALE_MISCSETTINGS_EPG_READ);
hint->setDelay(1);
hint->paint();
struct stat my_stat;
if (stat(g_settings.epg_dir.c_str(), &my_stat) == 0)
{
printf("Reading epg cache from %s ...\n", g_settings.epg_dir.c_str());
g_Sectionsd->readSIfromXML(g_settings.epg_dir.c_str());
// g_Sectionsd->readSIfromXML(g_settings.epg_dir.c_str());
ShowHintS(LOCALE_MISCSETTINGS_EPG_READ, sigc::bind(sigc::mem_fun(g_Sectionsd, &CSectionsdClient::readSIfromXML), g_settings.epg_dir.c_str()), 1);
}
for (std::list<std::string>::iterator it = g_settings.xmltv_xml.begin(); it != g_settings.xmltv_xml.end(); ++it)
{
printf("Reading xmltv epg from %s ...\n", (*it).c_str());
g_Sectionsd->readSIfromXMLTV((*it).c_str());
// g_Sectionsd->readSIfromXMLTV((*it).c_str());
ShowHintS(LOCALE_MISCSETTINGS_EPG_READ, sigc::bind(sigc::mem_fun(g_Sectionsd, &CSectionsdClient::readSIfromXMLTV), (*it).c_str()), 1);
}
delete hint;
if (actionKey == "epg_read_now_usermenu")
return menu_return::RETURN_EXIT_ALL;
else