Exemplo n.º 1
0
    def ShowList(self):
        """ Shows the discover results """
        # create the popup
        oContent         = GridLayout(cols=1, spacing='5dp')
        oScrollview      = ScrollView( do_scroll_x=False)
        self.oScrollContent   = StackLayout(size_hint=(None, None))
        self.oPopup   = oPopup = Popup(content=oContent, title=ReplaceVars('$lvar(5028)'), size_hint=(0.9, 0.9),  auto_dismiss=False)

        #we need to open the popup first to get the metrics
        oPopup.open()
        #Add some space on top
        oContent.add_widget(Widget(size_hint_y=None, height=dp(2)))
        aDiscoverScripts=Globals.oScripts.GetScriptListForScriptType("DEVICE_DISCOVER")
        aScrollContent=[]
        for uDiscoverScriptName in aDiscoverScripts:
            oScrollContentSingle   = GridLayout(size_hint=(None, None),size=(oPopup.width, dp(10)))
            aScrollContent.append(oScrollContentSingle)
            oScrollContentSingle.bind(minimum_height=oScrollContentSingle.setter('height'))
            Globals.oScripts.RunScript(uDiscoverScriptName,**{'createlist':1,'oGrid':oScrollContentSingle})
            self.oScrollContent.add_widget(cLabel(text=Globals.oScripts.dScripts[uDiscoverScriptName].uSubType, background_color=[0.2, 0.2, 0.2, 1.0], color=[0.2, 0.9, 0.9, 1.0], size=(oPopup.width, dp(30)),size_hint=(None, None), halign='center'))
            self.oScrollContent.add_widget(oScrollContentSingle)
            self.oScrollContent.add_widget(SettingSpacer())

        # finally, add a cancel button to return on the previous panel
        oScrollview.add_widget(self.oScrollContent)
        oContent.add_widget(oScrollview)
        oContent.add_widget(SettingSpacer())

        oBtn = Button(text=ReplaceVars('$lvar(5000)'), size=(oPopup.width, dp(50)),size_hint=(1, None))
        oBtn.bind(on_release=self.On_Cancel)
        oContent.add_widget(oBtn)

        #resize the Scrollcontent to fit to all Childs. Needs to be done, after the popup has been shown
        Clock.schedule_once(self.SetScrollSize, 0)
Exemplo n.º 2
0
    def __init__(self, **kwargs):
        kwargs['orientation'] = 'vertical'
        super(cITachToKeene,
              self).__init__(**RemoveNoClassArgs(kwargs, BoxLayout))
        self.uCodesetFileName = ''

        self.oLayoutHeaders = BoxLayout(size_hint_y=None, height=30)
        self.oLayoutButtons = BoxLayout(size_hint_y=None, height=30)
        self.oLayoutPanels = BoxLayout()
        self.add_widget(self.oLayoutHeaders)
        self.add_widget(SettingSpacer())
        self.add_widget(self.oLayoutPanels)
        self.add_widget(SettingSpacer())
        self.add_widget(self.oLayoutButtons)

        self.oTextInput = TextInput()
        self.oTextInput2 = TextInput()
        self.oLayoutPanels.add_widget(self.oTextInput)
        self.oLayoutPanels.add_widget(self.oTextInput2)

        self.oButtonLoad = Button(text=ReplaceVars('$lvar(563)'))
        self.oButtonSave = Button(text=ReplaceVars('$lvar(5025)'))
        self.oButtonLoad.bind(on_release=self.show_load)
        self.oButtonSave.bind(on_release=self.show_save)
        self.oLayoutButtons.add_widget(self.oButtonLoad)
        self.oLayoutButtons.add_widget(self.oButtonSave)

        self.oLabelITach = Label(text="ITach", halign='center')
        self.oLabelKeene = Label(text="Keene Kira", halign='center')
        self.oLayoutHeaders.add_widget(self.oLabelITach)
        self.oLayoutHeaders.add_widget(self.oLabelKeene)
Exemplo n.º 3
0
    def __init__(self, **kwargs):
        kwargs['orientation'] = 'vertical'
        super(cITachToKeene, self).__init__(
            **RemoveNoClassArgs(dInArgs=kwargs, oObject=BoxLayout))
        self.uCodesetFileName: str = ''
        self.oLayoutHeaders: BoxLayout = BoxLayout(size_hint_y=None, height=30)
        self.oLayoutButtons: BoxLayout = BoxLayout(size_hint_y=None, height=30)
        self.oLayoutPanels: BoxLayout = BoxLayout()
        self.add_widget(self.oLayoutHeaders)
        self.add_widget(SettingSpacer())
        self.add_widget(self.oLayoutPanels)
        self.add_widget(SettingSpacer())
        self.add_widget(self.oLayoutButtons)

        self.oTextInput: TextInput = TextInput()
        self.oTextInput2: TextInput = TextInput()
        self.oLayoutPanels.add_widget(self.oTextInput)
        self.oLayoutPanels.add_widget(self.oTextInput2)

        self.oButtonLoad: Button = Button(text=ReplaceVars('$lvar(563)'))
        self.oButtonSave: Button = Button(text=ReplaceVars('$lvar(5025)'))
        self.oButtonLoad.bind(on_release=self.show_load)
        self.oButtonSave.bind(on_release=self.show_save)
        self.oLayoutButtons.add_widget(self.oButtonLoad)
        self.oLayoutButtons.add_widget(self.oButtonSave)

        self.oLabelITach: Label = Label(text="ITach", halign='center')
        self.oLabelKeene: Label = Label(text="Keene Kira", halign='center')
        self.oLayoutHeaders.add_widget(self.oLabelITach)
        self.oLayoutHeaders.add_widget(self.oLabelKeene)

        self.oContent: Union[FileBrowser, None] = None
        self._popup: Union[Popup, None] = None
        self.oXMLCodeset: Union[Element, None] = None
Exemplo n.º 4
0
    def Show(self,*,uTitle:str,uMessage:str,iMax:int) -> Popup:
        """ Shows the Popup """
        self.iMax           = iMax
        self.bCancel        = False
        oContent:BoxLayout  = BoxLayout(orientation='vertical', spacing='5dp')
        iHeight:int         = int(Globals.iAppHeight*0.5)
        if Globals.uDeviceOrientation=="landscape":
            iHeight=int(Globals.iAppHeight*0.9)
        self.oPopup         = Popup(title=ReplaceVars(uTitle),content=oContent, size=(Globals.iAppWidth*0.9,iHeight),size_hint=(None, None),auto_dismiss=False)
        self.oLabel         = Label(text=ReplaceVars(uMessage), text_size=(Globals.iAppWidth*0.86, None), shorten=True, valign='top',halign='left')
        self.oProgressText  = Label(valign='top',halign='center',text_size=(Globals.iAppWidth*0.86, None), shorten=True)
        oContent.add_widget(Widget())
        oContent.add_widget(self.oLabel)
        oContent.add_widget(Widget())
        self.oProgressText.text=""

        self.oProgressBar = ProgressBar(size_hint_y=None, height='50dp', max=iMax)
        oContent.add_widget(self.oProgressBar)
        oContent.add_widget(self.oProgressText)
        oContent.add_widget(SettingSpacer())
        oBtn:Button = Button(size_hint_y=None, height='50dp',text=ReplaceVars('$lvar(5009)'))
        oBtn.bind(on_release=self.OnCancel)
        oContent.add_widget(oBtn)
        self.oPopup.open()
        return self.oPopup
Exemplo n.º 5
0
    def Start(self):
        """ create the popup """
        oContent = BoxLayout(spacing='5dp', orientation='vertical')
        self.oPopup = popup = Popup(content=oContent,
                                    title=ReplaceVars('$lvar(666)'),
                                    size_hint=(0.95, 0.95),
                                    auto_dismiss=False)

        #we need to open the popup first to get the metrics
        popup.open()
        #todo: check sXML reference
        #self.oXMLText=TextInput(text=oDBSelector.sXML)
        oContent.add_widget(self.oXMLText)
        oContent.add_widget(SettingSpacer())

        # 2 buttons are created for save or cancel the current file
        oBtnlayout = BoxLayout(size_hint_y=None, height='50dp', spacing='5dp')
        oBtn = Button(text=ReplaceVars('$lvar(5025)'))
        oBtn.bind(on_release=self.On_Save)
        oBtnlayout.add_widget(oBtn)
        oBtn = Button(text=ReplaceVars('$lvar(5009)'))
        oBtn.bind(on_release=self.oPopup.dismiss)
        oBtnlayout.add_widget(oBtn)
        oContent.add_widget(oBtnlayout)
        self.oXMLText.cursor = (0, 0)
Exemplo n.º 6
0
    def UpdateResults(self, *args):
        oDiscoverScriptStatus:cDiscoverScriptStatus
        tColor:Tuple=[]
        bFinished:bool = True
        try:
            self.oDiscoverListWaitLock.acquire()
            self.oScrollContent.clear_widgets()
            for oDiscoverScriptStatus in self.dScripts.values():
                oDiscoverScriptStatus.oGrid.clear_widgets()
                if oDiscoverScriptStatus.uScriptStatus=="$lvar(6039)":
                    tColor=[0.2, 0.9, 0.9, 1.0]
                    bFinished = False
                else:
                    tColor=[0.9, 0.9, 0.9, 1.0]

                self.oScrollContent.add_widget(cLabel(text="%s [%s]" % (oDiscoverScriptStatus.uScriptTitle, ReplaceVars(oDiscoverScriptStatus.uScriptStatus)), background_color=[0.2, 0.2, 0.2, 1.0], color=tColor, size=(self.oPopup.width, dp(30)),size_hint=(None, None), halign='center'))
                self.oScrollContent.add_widget(oDiscoverScriptStatus.oGrid)
                self.oScrollContent.add_widget(SettingSpacer())
                if len(oDiscoverScriptStatus.aScriptContentLineText)>0:
                    oDiscoverScriptStatus.oScript.AddHeaders()
                    for i in range(len(oDiscoverScriptStatus.aScriptContentLineText)):
                        oDiscoverScriptStatus.oScript.AddLine(aLine=oDiscoverScriptStatus.aScriptContentLineText[i],dDevice=oDiscoverScriptStatus.aScriptContentLineDevice[i])

            Clock.schedule_once(self.SetScrollSize, 0)
            self.oDiscoverListWaitLock.release()
            if bFinished:
                Clock.unschedule(self.oTimerUpdate)

        except Exception as e:
            LogError(uMsg="Error on update message handler",oException=e)
        return
Exemplo n.º 7
0
    def RaiseQuestion(self,
                      *,
                      uTitle: str = '',
                      uMessage: str = '',
                      fktYes: Union[Callable, None] = None,
                      fktNo: Union[Callable, None] = None,
                      uStringYes: str = '',
                      uStringNo: str = '',
                      uStringDetails: str = '') -> Popup:
        """ Shows the question """
        oContent: BoxLayout = BoxLayout(orientation='vertical', spacing='5dp')
        self.uMessage = uMessage
        self.oPopup = Popup(title=ReplaceVars(uTitle),
                            content=oContent,
                            size=(Globals.iAppWidth * 0.9,
                                  Globals.iAppHeight * 0.9),
                            size_hint=(None, None),
                            auto_dismiss=False)
        self.oLabel = cScrollableLabelLarge(
            text=ReplaceVars(uMessage),
            size_hint=(1, None),
            size=(Globals.iAppWidth * 0.86, Globals.iAppHeight * 0.4),
            markup=True,
            noxscroll=True,
        )

        oContent.add_widget(Widget())
        oContent.add_widget(self.oLabel)
        oContent.add_widget(Widget())
        oContent.add_widget(SettingSpacer())
        self.fktYes = fktYes
        self.fktNo = fktNo

        # 2 buttons are created for accept or cancel the current value
        self.oBtnlayout = BoxLayout(size_hint_y=None,
                                    height='50dp',
                                    spacing='5dp')
        if uStringYes != '':
            self.oBtn1 = Button(text=ReplaceVars(uStringYes))
            self.oBtn1.bind(on_release=self.fktYES)
            self.oBtnlayout.add_widget(self.oBtn1)

        if uStringDetails != '':
            self.uStringDetails = uStringDetails
            self.oBtnDetails = Button(text=ReplaceVars('$lvar(452)'))
            self.oBtnDetails.bind(on_release=self.fktDetails)
            self.oBtnlayout.add_widget(self.oBtnDetails)

        if uStringNo != '':
            self.oBtn2 = Button(text=ReplaceVars(uStringNo))
            self.oBtn2.bind(on_release=self.fktNO)
            self.oBtnlayout.add_widget(self.oBtn2)

        oContent.add_widget(self.oBtnlayout)

        self.oPopup.open()
        return self.oPopup
Exemplo n.º 8
0
    def ShowKeyBoard(self, *, uDestVar: str, oFktNotify: Union[Callable, None],
                     uTitle: str):
        """ create popup layout """
        uText: str
        oBtn: cMultiLineButton
        self.oFktNotify = oFktNotify
        self.uDestVar = uDestVar

        oContent: BoxLayout = BoxLayout(orientation='vertical', spacing='5dp')
        self.oPopup = Popup(title=uTitle,
                            content=oContent,
                            size_hint=(None, None),
                            size=(Globals.iAppWidth * 0.9,
                                  Globals.iAppHeight * 0.35),
                            auto_dismiss=False,
                            pos_hint={
                                'x': .05,
                                'top': 1
                            })
        uText = GetVar(uVarName=self.uDestVar)
        if uText is None:
            uText = u''
        Logger.debug("InputKeyboard: Preassigning Value [%s]" % uText)
        self.oTextInput = TextInput(text=uText,
                                    multiline=False,
                                    size_hint_y=None,
                                    height='30dp')
        self.oTextInput.bind(on_text_validate=self.On_Enter)

        # construct the content, widget are used as a spacer
        oContent.add_widget(Widget())
        oContent.add_widget(self.oTextInput)
        oContent.add_widget(Widget())
        oContent.add_widget(SettingSpacer())

        # 2 buttons are created for accept or cancel the current value
        oBtnlayout: BoxLayout = BoxLayout(size_hint_y=None,
                                          height='50dp',
                                          spacing='5dp')
        oBtn = cMultiLineButton(text=ReplaceVars('$lvar(5008)'),
                                halign='center',
                                valign='middle')
        oBtn.bind(on_release=self.On_Enter)
        oBtnlayout.add_widget(oBtn)
        self.oButtonCancel = cMultiLineButton(text=ReplaceVars('$lvar(5009)'),
                                              halign='center',
                                              valign='middle')
        self.oButtonCancel.bind(on_release=self.On_Cancel)
        oBtnlayout.add_widget(self.oButtonCancel)
        oContent.add_widget(oBtnlayout)

        #if we do setup the focus before the popup is shown, no vkeyboard is shown
        self.oPopup.bind(on_open=self.ScheduledSetFocus)
        self.oPopup.open()
Exemplo n.º 9
0
    def ShowList(self):
        """ Shows the discover results """
        try:
            # create the popup
            oScrollContentSingle:GridLayout
            oContent:GridLayout
            oScrollview:ScrollView
            uDiscoverScriptName:str
            aDiscoverScripts:List[str]
            uDiscoverScriptName:str
            oThread:cThread_Discover

            self.iHashStarted   = Globals.oNotifications.RegisterNotification(uNotification="DISCOVER_SCRIPTSTARTED",   fNotifyFunction=self.NotificationHandler_ScriptStarted,   uDescription="Notification list discovery started")
            self.iHashEnded     = Globals.oNotifications.RegisterNotification(uNotification="DISCOVER_SCRIPTENDED",     fNotifyFunction=self.NotificationHandler_ScriptEnded,     uDescription="Notification list discovery ended")
            self.iHashFound     = Globals.oNotifications.RegisterNotification(uNotification="DISCOVER_SCRIPTFOUND",     fNotifyFunction=self.NotificationHandler_ScriptFoundItem, uDescription="Notification list discovery found item")

            oContent               = GridLayout(cols=1, spacing='5dp')
            oScrollview            = ScrollView( do_scroll_x=False)
            self.oPopup:Popup      = Popup(content=oContent, title=ReplaceVars('$lvar(5028)'), size_hint=(0.9, 0.9),  auto_dismiss=False)

            #we need to open the popup first to get the metrics
            self.oPopup.open()
            #Add some space on top
            oContent.add_widget(Widget(size_hint_y=None, height=dp(2)))
            aDiscoverScripts = Globals.oScripts.GetScriptListForScriptType("DEVICE_DISCOVER")
            for uDiscoverScriptName in aDiscoverScripts:
                # if uDiscoverScriptName == u"discover_eiscp" or uDiscoverScriptName == u"discover_kira" or uDiscoverScriptName == u"discover_elvmax" or uDiscoverScriptName == u"discover_enigma" or uDiscoverScriptName==u"discover_upnp":
                #if uDiscoverScriptName == u"discover_kira":
                if True:
                    oScrollContentSingle= GridLayout(size_hint=(None, None),size=(self.oPopup.width, dp(10)))
                    oScrollContentSingle.bind(minimum_height=oScrollContentSingle.setter('height'))
                    oThread = cThread_Discover(uScriptName=uDiscoverScriptName,dParKwArgs={'createlist':1,'oGrid':oScrollContentSingle})
                    self.aThreads.append(oThread)
                    self.aThreads[-1].start()

            # finally, add a cancel button to return on the previous panel
            oScrollview.add_widget(self.oScrollContent)
            oContent.add_widget(oScrollview)
            oContent.add_widget(SettingSpacer())

            oBtn: Button = Button(text=ReplaceVars('$lvar(5000)'), size=(self.oPopup.width, dp(50)),size_hint=(1, None))
            oBtn.bind(on_release=self.On_Cancel)
            oContent.add_widget(oBtn)

            #resize the Scrollcontent to fit to all childs. Needs to be done, after the popup has been shown
            Clock.schedule_once(self.SetScrollSize, 0)
            self.oTimerUpdate = Clock.schedule_interval(self.UpdateResults, 2)
        except Exception as e:
            LogError(uMsg="Critical error string discover scripts",oException=e)
Exemplo n.º 10
0
    def Start(self, uTitle: str, aOptions: List, fktCallBack: Callable):
        """ starts selection """

        self.fktCallBack = fktCallBack
        oButton: Button
        uName: str
        # create the popup
        oContent: GridLayout = GridLayout(cols=1, spacing='5dp')
        oScrollview: ScrollView = ScrollView(do_scroll_x=False,
                                             bar_width='10dp',
                                             scroll_type=['bars', 'content'])
        oScrollcontent: GridLayout = GridLayout(cols=1,
                                                spacing='5dp',
                                                size_hint=(None, None))
        oScrollcontent.bind(minimum_height=oScrollcontent.setter('height'))
        self.oPopup = Popup(content=oContent,
                            title=ReplaceVars(uTitle),
                            size_hint=(0.5, 0.9),
                            auto_dismiss=False)

        #we need to open the popup first to get the metrics
        self.oPopup.open()
        #Add some space on top
        oContent.add_widget(Widget(size_hint_y=None, height=dp(2)))
        # add all the options
        for option in aOptions:
            if hasattr(option, "uName"):
                uName = option.uName
            else:
                uName = option.uType
            oButton = Button(text=uName,
                             size=(self.oPopup.width, dp(30)),
                             size_hint=(None, None))
            oButton.bind(on_release=self.On_Value)
            oButton.oDBRef = option
            oScrollcontent.add_widget(oButton)

        # finally, add a cancel button
        oScrollview.add_widget(oScrollcontent)
        oContent.add_widget(oScrollview)
        oContent.add_widget(SettingSpacer())
        oButton = Button(text=ReplaceVars('$lvar(5009)'),
                         size=(self.oPopup.width, dp(50)),
                         size_hint=(0.9, None))
        oButton.bind(on_release=self.oPopup.dismiss)
        oContent.add_widget(oButton)
Exemplo n.º 11
0
    def Start(self, uTitle, aOptions, fktCallBack):
        """ starts selection """
        self.fktCallBack = fktCallBack
        # create the popup
        content = GridLayout(cols=1, spacing='5dp')
        scrollview = ScrollView(do_scroll_x=False,
                                bar_width='10dp',
                                scroll_type=['bars', 'content'])
        scrollcontent = GridLayout(cols=1,
                                   spacing='5dp',
                                   size_hint=(None, None))
        scrollcontent.bind(minimum_height=scrollcontent.setter('height'))
        self.oPopup = popup = Popup(content=content,
                                    title=ReplaceVars(uTitle),
                                    size_hint=(0.5, 0.9),
                                    auto_dismiss=False)

        #we need to open the popup first to get the metrics
        popup.open()
        #Add some space on top
        content.add_widget(Widget(size_hint_y=None, height=dp(2)))
        # add all the options
        for option in aOptions:
            if hasattr(option, "Name"):
                name = option.Name
            else:
                name = option.Type
            btn = Button(text=name,
                         size=(popup.width, dp(30)),
                         size_hint=(None, None))
            btn.bind(on_release=self.On_Value)
            btn.oDBRef = option
            scrollcontent.add_widget(btn)

        # finally, add a cancel button
        scrollview.add_widget(scrollcontent)
        content.add_widget(scrollview)
        content.add_widget(SettingSpacer())
        btn = Button(text=ReplaceVars('$lvar(5009)'),
                     size=(popup.width, dp(50)),
                     size_hint=(0.9, None))
        btn.bind(on_release=popup.dismiss)
        content.add_widget(btn)
Exemplo n.º 12
0
    def Start(self, uHost: str, uUser: str, uPassword: str) -> None:
        """ starts the selection of an IRDB item """
        self.uPassword = uPassword
        self.uUser = uUser
        self.uHost = uHost

        oContent = BoxLayout(orientation='vertical', spacing='5dp')
        self.oPopup = Popup(
            title=ReplaceVars('$lvar(SCRIPT_TOOLS_IRDBITACH_4)'),
            content=oContent,
            size_hint=(0.9, 0.9),
            auto_dismiss=False)

        self.oBtnBrands = Button(
            text=ReplaceVars('$lvar(SCRIPT_TOOLS_IRDBITACH_6)'))
        self.oBtnTypes = Button(
            text=ReplaceVars('$lvar(SCRIPT_TOOLS_IRDBITACH_7)'))
        self.oBtnModels = Button(
            text=ReplaceVars('$lvar(SCRIPT_TOOLS_IRDBITACH_8)'))
        self.oTextBrands = Label()
        self.oTextTypes = Label()
        self.oTextModels = Label()
        self.oProgressBar = cProgressBar()

        self.oBtnBrands.bind(on_release=self.On_BtnBrands)
        self.oBtnTypes.bind(on_release=self.On_BtnTypes)
        self.oBtnModels.bind(on_release=self.On_BtnModels)

        # construct the content, widget are used as a spacer
        #Gridlayout is working properly after adding into a box layout
        oContent.add_widget(Widget(height='2dp', size_hint_y=None))
        oContentBrands = BoxLayout(orientation='horizontal',
                                   spacing='5dp',
                                   height='40dp',
                                   size_hint_y=None)
        oContentBrands.add_widget(self.oBtnBrands)
        oContentBrands.add_widget(self.oTextBrands)
        oContentTypes = BoxLayout(orientation='horizontal',
                                  spacing='5dp',
                                  height='40dp',
                                  size_hint_y=None)
        oContentTypes.add_widget(self.oBtnTypes)
        oContentTypes.add_widget(self.oTextTypes)
        oContentModels = BoxLayout(orientation='horizontal',
                                   spacing='5dp',
                                   height='40dp',
                                   size_hint_y=None)
        oContentModels.add_widget(self.oBtnModels)
        oContentModels.add_widget(self.oTextModels)
        oContent.add_widget(oContentBrands)
        oContent.add_widget(oContentTypes)
        oContent.add_widget(oContentModels)

        if self.uUser == u'' or self.uPassword == u'':
            oContent.add_widget(SettingSpacer())
            oContent.add_widget(
                Label(text=ReplaceVars("$lvar(SCRIPT_TOOLS_IRDBITACH_5)"),
                      height='20dp',
                      size_hint_y=None))

        oContent.add_widget(SettingSpacer())
        self.oCodesetName = TextInput(height='20dp')
        oContent.add_widget(self.oCodesetName)
        oContent.add_widget(SettingSpacer())

        oContentWriteCCF = BoxLayout(orientation='horizontal',
                                     spacing='5dp',
                                     height='20dp',
                                     size_hint_y=None)
        self.oOptionWriteCCF = CheckBox(active=True)
        oContentWriteCCF.add_widget(
            Label(text=ReplaceVars("$lvar(SCRIPT_TOOLS_IRDBITACH_9)"),
                  height='20dp',
                  size_hint_y=None,
                  halign='left'))
        oContentWriteCCF.add_widget(self.oOptionWriteCCF)
        oContent.add_widget(oContentWriteCCF)

        oContentWriteITach = BoxLayout(orientation='horizontal',
                                       spacing='5dp',
                                       height='20dp',
                                       size_hint_y=None)
        self.oOptionWriteITach = CheckBox()
        oContentWriteITach.add_widget(
            Label(text=ReplaceVars("$lvar(SCRIPT_TOOLS_IRDBITACH_10)"),
                  height='20dp',
                  size_hint_y=None,
                  halign='left'))
        oContentWriteITach.add_widget(self.oOptionWriteITach)
        oContent.add_widget(oContentWriteITach)

        oContentOptimizeChannelSelect = BoxLayout(orientation='horizontal',
                                                  spacing='5dp',
                                                  height='20dp',
                                                  size_hint_y=None)
        self.oOptionOptimizeChannelSelect = CheckBox()
        oContentOptimizeChannelSelect.add_widget(
            Label(text=ReplaceVars("$lvar(SCRIPT_TOOLS_IRDBITACH_11)"),
                  height='20dp',
                  size_hint_y=None,
                  halign='left'))
        oContentOptimizeChannelSelect.add_widget(
            self.oOptionOptimizeChannelSelect)
        oContent.add_widget(oContentOptimizeChannelSelect)
        oContent.add_widget(SettingSpacer())

        # 2 buttons are created for accept or cancel the current value
        oBtnButtons = BoxLayout(size_hint_y=None, height='50dp', spacing='5dp')
        oBtn = Button(text=ReplaceVars('$lvar(5008)'))
        oBtn.bind(on_release=self.On_BtnLoad)
        oBtnButtons.add_widget(oBtn)
        oBtn = Button(text=ReplaceVars('$lvar(5009)'))
        oBtn.bind(on_release=self.oPopup.dismiss)
        oBtnButtons.add_widget(oBtn)
        oContent.add_widget(oBtnButtons)
        self.oPopup.open()
        self.CreateCodesetFileName()