mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-09-01 01:41:23 +02:00
- controlapi: reformat CControlAPI::xmltvm3uCGI() function; no other changes
Signed-off-by: Thilo Graf <dbt@novatux.de>
This commit is contained in:
@@ -3296,10 +3296,10 @@ void CControlAPI::xmltvm3uCGI(CyhookHandler *hh)
|
|||||||
int mode = NeutrinoAPI->Zapit->getMode();
|
int mode = NeutrinoAPI->Zapit->getMode();
|
||||||
// build url
|
// build url
|
||||||
std::string url = "";
|
std::string url = "";
|
||||||
if(!hh->ParamList["host"].empty())
|
if (!hh->ParamList["host"].empty())
|
||||||
url = "http://"+hh->ParamList["host"];
|
url = "http://" + hh->ParamList["host"];
|
||||||
else
|
else
|
||||||
url = "http://"+hh->HeaderList["Host"];
|
url = "http://" + hh->HeaderList["Host"];
|
||||||
|
|
||||||
std::string lurl = url;
|
std::string lurl = url;
|
||||||
/* strip off optional custom port */
|
/* strip off optional custom port */
|
||||||
@@ -3317,15 +3317,15 @@ void CControlAPI::xmltvm3uCGI(CyhookHandler *hh)
|
|||||||
g_bouquetManager->Bouquets[i]->getRadioChannels(chanlist);
|
g_bouquetManager->Bouquets[i]->getRadioChannels(chanlist);
|
||||||
else
|
else
|
||||||
g_bouquetManager->Bouquets[i]->getTvChannels(chanlist);
|
g_bouquetManager->Bouquets[i]->getTvChannels(chanlist);
|
||||||
if(!chanlist.empty() && !g_bouquetManager->Bouquets[i]->bHidden && g_bouquetManager->Bouquets[i]->bUser)
|
if (!chanlist.empty() && !g_bouquetManager->Bouquets[i]->bHidden && g_bouquetManager->Bouquets[i]->bUser)
|
||||||
{
|
{
|
||||||
for(int j = 0; j < (int) chanlist.size(); j++)
|
for (int j = 0; j < (int) chanlist.size(); j++)
|
||||||
{
|
{
|
||||||
CZapitChannel * channel = chanlist[j];
|
CZapitChannel *channel = chanlist[j];
|
||||||
std::string bouq_name = g_bouquetManager->Bouquets[i]->bName;
|
std::string bouq_name = g_bouquetManager->Bouquets[i]->bName;
|
||||||
std::string chan_id_short = string_printf(PRINTF_CHANNEL_ID_TYPE_NO_LEADING_ZEROS, channel->getChannelID() & 0xFFFFFFFFFFFFULL);
|
std::string chan_id_short = string_printf(PRINTF_CHANNEL_ID_TYPE_NO_LEADING_ZEROS, channel->getChannelID() & 0xFFFFFFFFFFFFULL);
|
||||||
result += "#EXTINF:-1 tvg-id=\""+chan_id_short+"\" tvg-logo=\""+lurl+NeutrinoAPI->getLogoFile(channel->getChannelID())+"\" group-title=\""+bouq_name+"\","+channel->getName()+"\n";
|
result += "#EXTINF:-1 tvg-id=\"" + chan_id_short + "\" tvg-logo=\"" + lurl + NeutrinoAPI->getLogoFile(channel->getChannelID()) + "\" group-title=\"" + bouq_name + "\"," + channel->getName() + "\n";
|
||||||
result += url+string_printf(PRINTF_CHANNEL_ID_TYPE_NO_LEADING_ZEROS, channel->getChannelID())+"\n";
|
result += url + string_printf(PRINTF_CHANNEL_ID_TYPE_NO_LEADING_ZEROS, channel->getChannelID()) + "\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user