Update settingsManager.py
This commit is contained in:
parent
ff64be3459
commit
ec588522b0
@ -108,7 +108,7 @@ class settingsManager():
|
|||||||
def isValidKey(self, key):
|
def isValidKey(self, key):
|
||||||
return key in inputData.keyNames
|
return key in inputData.keyNames
|
||||||
|
|
||||||
def loadDicts(self, dictConfigPath=os.path.dirname(os.path.realpath(fenrirVersion.__file__)) + '/../../config/punctuation/default.conf'):
|
def loadDicts(self, dictConfigPath=fenrirPath + '/../../config/punctuation/default.conf'):
|
||||||
dictConfig = open(dictConfigPath,"r")
|
dictConfig = open(dictConfigPath,"r")
|
||||||
currDictName = ''
|
currDictName = ''
|
||||||
while(True):
|
while(True):
|
||||||
@ -206,7 +206,7 @@ class settingsManager():
|
|||||||
if self.env['runtime'][driverType] != None:
|
if self.env['runtime'][driverType] != None:
|
||||||
self.env['runtime'][driverType].shutdown(self.env)
|
self.env['runtime'][driverType].shutdown(self.env)
|
||||||
driver_mod = module_utils.importModule(driverName,
|
driver_mod = module_utils.importModule(driverName,
|
||||||
os.path.dirname(os.path.realpath(fenrirVersion.__file__)) + "/" + driverType + '/' + driverName + '.py')
|
fenrirPath + "/" + driverType + '/' + driverName + '.py')
|
||||||
self.env['runtime'][driverType] = driver_mod.driver()
|
self.env['runtime'][driverType] = driver_mod.driver()
|
||||||
self.env['runtime'][driverType].initialize(self.env)
|
self.env['runtime'][driverType].initialize(self.env)
|
||||||
self.env['runtime']['debug'].writeDebugOut('Loading Driver ' + driverType + ' (' + driverName +") OK",debug.debugLevel.INFO, onAnyLevel=True)
|
self.env['runtime']['debug'].writeDebugOut('Loading Driver ' + driverType + ' (' + driverName +") OK",debug.debugLevel.INFO, onAnyLevel=True)
|
||||||
@ -259,8 +259,8 @@ class settingsManager():
|
|||||||
environment['runtime']['debug'].initialize(environment)
|
environment['runtime']['debug'].initialize(environment)
|
||||||
# get fenrir settings root
|
# get fenrir settings root
|
||||||
if not os.path.exists(settingsRoot):
|
if not os.path.exists(settingsRoot):
|
||||||
if os.path.exists(os.path.dirname(os.path.realpath(fenrirVersion.__file__)) +'/../../config/'):
|
if os.path.exists(fenrirPath) +'/../../config/'):
|
||||||
settingsRoot = os.path.dirname(os.path.realpath(fenrirVersion.__file__)) +'/../../config/'
|
settingsRoot = fenrirPath +'/../../config/'
|
||||||
else:
|
else:
|
||||||
return None
|
return None
|
||||||
# get settings file
|
# get settings file
|
||||||
@ -271,8 +271,8 @@ class settingsManager():
|
|||||||
return None
|
return None
|
||||||
# get sound themes root
|
# get sound themes root
|
||||||
if not os.path.exists(soundRoot):
|
if not os.path.exists(soundRoot):
|
||||||
if os.path.exists(os.path.dirname(os.path.realpath(fenrirVersion.__file__)) +'/../../config/sound/'):
|
if os.path.exists(fenrirPath) +' /../../config/sound/'):
|
||||||
soundRoot = os.path.dirname(os.path.realpath(fenrirVersion.__file__)) +'/../../config/sound/'
|
soundRoot = fenrirPath + '/../../config/sound/'
|
||||||
|
|
||||||
environment['runtime']['settingsManager'] = self
|
environment['runtime']['settingsManager'] = self
|
||||||
environment['runtime']['settingsManager'].initialize(environment)
|
environment['runtime']['settingsManager'].initialize(environment)
|
||||||
|
Loading…
Reference in New Issue
Block a user