begin clean up after fixing badcrasher

This commit is contained in:
chrys
2016-09-02 18:08:44 +02:00
parent f7be3871a6
commit 1998ca15e8
4 changed files with 7 additions and 14 deletions

View File

@ -27,7 +27,6 @@ class inputManager():
if self.isFenrirKey(environment, event):
environment['input']['consumeKey'] = not environment['input']['keyForeward'] and not environment['generalInformation']['suspend']
if self.isConsumeKeypress(environment):
environment['runtime']['debug'].writeDebugOut(environment, str(event)+' consume'+str(time.time()),debug.debugLevel.ERROR)
self.writeUInput(self.uDevices[fd], event,environment)
keyString = ''
if self.isFenrirKey(environment, event):
@ -43,6 +42,7 @@ class inputManager():
except:
pass
except Exception as e:
environment['runtime']['debug'].writeDebugOut(environment,"Error while inputHandling",debug.debugLevel.ERROR)
environment['runtime']['debug'].writeDebugOut(environment,str(e),debug.debugLevel.ERROR)
self.freeDevices()
time.sleep(0.01)
@ -64,11 +64,11 @@ class inputManager():
def writeUInput(self, uDevice, event,environment):
try:
environment['runtime']['debug'].writeDebugOut(environment, str(event)+' write event '+str(time.time()),debug.debugLevel.ERROR)
uDevice.write_event(event)
uDevice.syn()
except Exception as a:
environment['runtime']['debug'].writeDebugOut(environment, str(e)+' error exception '+str(time.time()),debug.debugLevel.ERROR)
except Exception as e:
environment['runtime']['debug'].writeDebugOut(environment,"Error while writeUInput",debug.debugLevel.ERROR)
environment['runtime']['debug'].writeDebugOut(environment, str(e),debug.debugLevel.ERROR)
def getShortcutString(self, environment):
if environment['input']['currShortcut'] == {}:

View File

@ -7,7 +7,7 @@ class outputManager():
def presentText(self, environment, text, interrupt=True, soundIcon = ''):
environment['runtime']['debug'].writeDebugOut(environment,"presentText:\nsoundIcon:'"+soundIcon+"'\nText:\n" + text ,debug.debugLevel.INFO)
if self.playSoundIcon(environment, soundIcon, interrupt):
environment['runtime']['debug'].writeDebugOut(environment,"presentText:\n" + text ,debug.debugLevel.INFO)
environment['runtime']['debug'].writeDebugOut(environment,"soundIcon found" ,debug.debugLevel.INFO)
return
self.speakText(environment, text, interrupt)
self.brailleText(environment, text, interrupt)