mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-29 16:31:11 +02:00
channel list: restrict adding channels to favorits only,
show empty bouquets only in channel add mode
This commit is contained in:
@@ -87,6 +87,7 @@ extern CBouquetList * RADIObouquetList;
|
||||
extern CBouquetList * RADIOsatList;
|
||||
extern CBouquetList * RADIOfavList;
|
||||
extern CBouquetList * RADIOallList;
|
||||
extern CBouquetList * AllFavBouquetList;
|
||||
|
||||
extern bool autoshift;
|
||||
|
||||
@@ -423,6 +424,7 @@ int CChannelList::doChannelMenu(void)
|
||||
|
||||
break;
|
||||
case 2: // add to
|
||||
#if 0
|
||||
/* default to favorites list, it makes no sense to add to autogenerated bouquets */
|
||||
if (CNeutrinoApp::getInstance()->GetChannelMode() != LIST_MODE_FAV)
|
||||
CNeutrinoApp::getInstance()->SetChannelMode(LIST_MODE_FAV);
|
||||
@@ -430,6 +432,7 @@ int CChannelList::doChannelMenu(void)
|
||||
do {
|
||||
bouquet_id = bouquetList->exec(false);
|
||||
} while(bouquet_id == -3);
|
||||
bouquet_id = bouquetList->exec(false);
|
||||
hide();
|
||||
if(bouquet_id < 0)
|
||||
return 0;
|
||||
@@ -438,6 +441,16 @@ int CChannelList::doChannelMenu(void)
|
||||
bouquet_id = g_bouquetManager->existsUBouquet(g_Locale->getText(LOCALE_FAVORITES_BOUQUETNAME), true);
|
||||
else
|
||||
bouquet_id = g_bouquetManager->existsBouquet(bouquetList->Bouquets[bouquet_id]->channelList->getName());
|
||||
#endif
|
||||
bouquet_id = AllFavBouquetList->exec(false);
|
||||
hide();
|
||||
if(bouquet_id < 0)
|
||||
return 0;
|
||||
|
||||
if(!strcmp(AllFavBouquetList->Bouquets[bouquet_id]->channelList->getName(), g_Locale->getText(LOCALE_FAVORITES_BOUQUETNAME)))
|
||||
bouquet_id = g_bouquetManager->existsUBouquet(g_Locale->getText(LOCALE_FAVORITES_BOUQUETNAME), true);
|
||||
else
|
||||
bouquet_id = g_bouquetManager->existsUBouquet(AllFavBouquetList->Bouquets[bouquet_id]->channelList->getName());
|
||||
|
||||
if (bouquet_id == -1)
|
||||
return 0;
|
||||
|
Reference in New Issue
Block a user