mirror of
https://github.com/dbarzin/pandora-box.git
synced 2025-07-24 07:49:42 +02:00
code quality
This commit is contained in:
parent
ccf1a9b31c
commit
ed789fb9e8
8 changed files with 37 additions and 44 deletions
|
@ -1,15 +1,15 @@
|
|||
#!/usr/bin/python3
|
||||
|
||||
def waitMouseClick():
|
||||
mouse = open( "/dev/input/mice", "rb" )
|
||||
down = False;
|
||||
mouse = open("/dev/input/mice", "rb")
|
||||
down = False
|
||||
while True:
|
||||
buf = mouse.read(3)
|
||||
if ((buf[0] & 0x1)==1):
|
||||
if ((buf[0] & 0x1) == 1):
|
||||
down = True
|
||||
if (((buf[0] & 0x1)==0) and down):
|
||||
break;
|
||||
if (((buf[0] & 0x1) == 0) and down):
|
||||
break
|
||||
mouse.close()
|
||||
|
||||
waitMouseClick()
|
||||
|
||||
waitMouseClick()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue