+def openAskBouquet(Session, bouquets, cnt):
+ if cnt > 1: # show bouquet list
+ global bouquetSel
+ bouquetSel = Session.openWithCallback(closed, BouquetSelector, bouquets, openBouquetEPG, enableWrapAround=True)
+ dlg_stack.append(bouquetSel)
+ elif cnt == 1:
+ if not openBouquetEPG(bouquets[0][1]):
+ cleanup()
+
+def openSilent(Servicelist, bouquets, cnt):
+ root = Servicelist.getRoot()
+ if cnt > 1: # create bouquet list
+ global bouquetSel
+ current = 0
+ rootstr = root.toCompareString()
+ for bouquet in bouquets:
+ if bouquet[1].toCompareString() == rootstr:
+ break
+ current += 1
+ if current >= cnt:
+ current = 0
+ bouquetSel = SilentBouquetSelector(bouquets, True, current)
+ if cnt >= 1: # open current bouquet
+ if not openBouquetEPG(root):
+ cleanup()
+