Пример #1
0
 def init(self):
     self.account = sys.argv[1:][0]
     self.srcpath = sys.argv[1:][1]
     f = open("X:\\mmcomu.xib", "w")
     f.close()
     time.sleep(2)
     self.emailist = []
     lang = Language(TITLE)
     lang.load(self.srcpath + "\\language")
     self.language = lang.string
     xbmc.executebuiltin('XBMC.Notification(XinBox Mini-Mode,Started)')
     time.sleep(5)
     try:
         self.exit = False
         self.loadsettings()
         self.inboxes = self.buildinboxdict()
         if not len(self.inboxes) == 0:self.startmm()
     except:pass
     if exists("X:\\mmcomu.xib"):
         os.remove("X:\\mmcomu.xib")
     if self.exit:
         w = XinBox_MainMenu.GUI("XinBox_MainMenu.xml",self.srcpath,"DefaultSkin",bforeFallback=False,minimode=self.account, minibox=self.inbox, lang=self.language)
         w.doModal()
         del w
     else:
         xbmc.executebuiltin('XBMC.Notification(XinBox Mini-Mode,Closed)')
Пример #2
0
#                                    #
#A pop3 + SMTP email client for XBMC #
#                                    #
######################################
import sys, os, xbmc, time, xbmcgui
from os.path import join, exists
sys.path.append( os.path.join( sys.path[0], 'src', 'lib' ) )

import XinBox_MainMenu
from XinBox_Language import Language
import XinBox_Util
import threading

scriptpath = os.getcwd().replace(";","")+"\\"

lang = Language(XinBox_Util.__scriptname__)
lang.load(scriptpath + "\\src\\language")
_ = lang.string


if __name__ == '__main__':
        if exists("X:\\mmcomu.xib"):
                os.remove("X:\\mmcomu.xib")
                try:
                        w = XinBox_MainMenu.GUI("XinBox_MainMenu.xml",scriptpath+ "src","DefaultSkin",bforeFallback=False,minimode=sys.argv[1:][0],lang=_)
                except:w = XinBox_MainMenu.GUI("XinBox_MainMenu.xml",scriptpath + "src","DefaultSkin",lang=_)
        else:w = XinBox_MainMenu.GUI("XinBox_MainMenu.xml",scriptpath + "src","DefaultSkin",lang=_)
        w.doModal()
        del w