fix first shortcut is not handled

This commit is contained in:
chrys 2018-03-22 21:01:38 +01:00
parent bb5abbcc5a
commit 8f76457feb
2 changed files with 3 additions and 0 deletions

View File

@ -58,6 +58,7 @@ class fenrirManager():
self.environment['runtime']['inputManager'].handleInputEvent(event['Data'])
else:
return
if self.environment['runtime']['inputManager'].noKeyPressed():
self.environment['runtime']['inputManager'].clearLastDeepInput()
if self.environment['runtime']['screenManager'].isSuspendingScreen():
@ -144,6 +145,7 @@ class fenrirManager():
if not( self.singleKeyCommand and self.environment['runtime']['inputManager'].noKeyPressed()):
shortcut = self.environment['runtime']['inputManager'].getCurrShortcut()
self.command = self.environment['runtime']['inputManager'].getCommandForShortcut(shortcut)
if not self.modifierInput:
if self.environment['runtime']['inputManager'].isKeyPress():
if self.command != '':

View File

@ -23,6 +23,7 @@ class inputManager():
self.env['input']['newScrollLock'] = self.env['runtime']['inputDriver'].getLedState(2)
self.env['input']['oldScrollLock'] = self.env['input']['newScrollLock']
self.lastDeepestInput = []
self.env['input']['shortcutRepeat'] = 1
self.lastInputTime = time.time()
def shutdown(self):
self.removeAllDevices()