we dont want to use while(true) lol
This commit is contained in:
parent
f231f72cbe
commit
0ec1a0e56d
@ -33,8 +33,8 @@ class driver():
|
|||||||
r, w, x = select(self.iDevices, [], [], self.env['runtime']['settingsManager'].getSettingAsFloat('screen', 'screenUpdateDelay'))
|
r, w, x = select(self.iDevices, [], [], self.env['runtime']['settingsManager'].getSettingAsFloat('screen', 'screenUpdateDelay'))
|
||||||
if r != []:
|
if r != []:
|
||||||
for fd in r:
|
for fd in r:
|
||||||
while(True):
|
|
||||||
event = self.iDevices[fd].read_one()
|
event = self.iDevices[fd].read_one()
|
||||||
|
while(event):
|
||||||
if not event:
|
if not event:
|
||||||
return None
|
return None
|
||||||
self.env['input']['eventBuffer'].append( [self.iDevices[fd], self.uDevices[fd], event])
|
self.env['input']['eventBuffer'].append( [self.iDevices[fd], self.uDevices[fd], event])
|
||||||
@ -44,6 +44,7 @@ class driver():
|
|||||||
return currMapEvent
|
return currMapEvent
|
||||||
if currMapEvent['EventState'] in [0,1,2]:
|
if currMapEvent['EventState'] in [0,1,2]:
|
||||||
return currMapEvent
|
return currMapEvent
|
||||||
|
event = self.iDevices[fd].read_one()
|
||||||
return None
|
return None
|
||||||
|
|
||||||
def writeEventBuffer(self):
|
def writeEventBuffer(self):
|
||||||
|
Loading…
Reference in New Issue
Block a user