- if eficas_translator.load("eficas_" + locale, monPath):
- QApplication.installTranslator(eficas_translator)
- else:
- print "Unable to load Eficas translator!"
+ if file != None and debug :
+ print ('chargement de ', file,monPath)
+ print (eficas_translator.load(file,monPath))
+ print (QApplication.installTranslator(eficas_translator))
+ elif eficas_translator.load("eficas_" + locale, monPath):
+ QApplication.installTranslator(eficas_translator)
+ elif debug:
+ print ("Unable to load Eficas translator!")
+
+ global code_translator
+ if translatorFichier != None :
+ if (code_translator.load(translatorFichier)) and debug:
+ print (translatorFichier, ' loaded')
+ elif (code_translator.load(translatorFichier+'_'+locale) and debug):
+ print(translatorFichier+'_'+locale+ ' loaded')
+ elif debug :
+ print ("Unable to load Code translator! No file or No translation" + translatorFichier)
+ if debug : print (QApplication.installTranslator(code_translator))