⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 application.py

📁 属性sosuo算法
💻 PY
字号:
import sysimport frontendimport timeimport resourcesimport configimport prefsimport osfrom platformutils import _getLocale as getLocalefrom frontend_implementation import HTMLDisplay################################################################################### Application object                                                    ###################################################################################class Application:    def __init__(self):        print "Application init"    def Run(self):        HTMLDisplay.initTempDir()        lang = getLocale()        if lang:            if not os.path.exists(resources.path(r"..\chrome\locale\%s" % (lang,))):                lang = "en-US"        else:            lang = "en-US"        from xpcom import components        ps_cls = components.classes["@mozilla.org/preferences-service;1"]        ps = ps_cls.getService(components.interfaces.nsIPrefService)        branch = ps.getBranch("general.useragent.")        branch.setCharPref("locale", lang)        import psyco        #psyco.log('\\dtv.psyco')        psyco.profile(.03)        # Start the core.        if frontend.startup.search:            self.onStartup(frontend.startup.search.getFiles())        else:            self.onStartup()        frontend.jsBridge.positionVolumeSlider(config.get(prefs.VOLUME_LEVEL))    def onStartup(self):        # For overriding        pass    def onShutdown(self):        # For overriding        pass    # This is called on OS X when we are handling a click on an RSS feed    # button for Safari. NEEDS: add code here to register as a RSS feed    # reader on Windows too. Just call this function when we're launched    # to handle a click on a feed.    def addAndSelectFeed(self, url):        # For overriding        pass##############################################################################################################################################################

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -