Appease formatter
This commit is contained in:
parent
c722d8aeee
commit
ca493bc326
28
dropship.py
28
dropship.py
@ -104,14 +104,15 @@ class DropShip:
|
|||||||
|
|
||||||
else:
|
else:
|
||||||
log.info("Multiple file sending coming soon ™")
|
log.info("Multiple file sending coming soon ™")
|
||||||
def update_send_ui (self):
|
|
||||||
|
|
||||||
# UI response after adding files
|
def update_send_ui(self):
|
||||||
self.drop_label.set_visible(False)
|
|
||||||
self.drop_label.set_vexpand(False)
|
# UI response after adding files
|
||||||
self.drop_spinner.set_vexpand(True)
|
self.drop_label.set_visible(False)
|
||||||
self.drop_spinner.set_visible(True)
|
self.drop_label.set_vexpand(False)
|
||||||
self.drop_spinner.start()
|
self.drop_spinner.set_vexpand(True)
|
||||||
|
self.drop_spinner.set_visible(True)
|
||||||
|
self.drop_spinner.start()
|
||||||
|
|
||||||
def add_files(self, widget, event):
|
def add_files(self, widget, event):
|
||||||
"""Handler for adding files with system interface"""
|
"""Handler for adding files with system interface"""
|
||||||
@ -129,17 +130,18 @@ class DropShip:
|
|||||||
"""Read wormhole send code from command-line output."""
|
"""Read wormhole send code from command-line output."""
|
||||||
|
|
||||||
while True:
|
while True:
|
||||||
output = process.stderr.readline() # (rra) Why is it printing to stderr tho?
|
output = (
|
||||||
if output == '' and process.poll() is not None:
|
process.stderr.readline()
|
||||||
|
) # (rra) Why is it printing to stderr tho?
|
||||||
|
if output == "" and process.poll() is not None:
|
||||||
print(output)
|
print(output)
|
||||||
return #(rra) We need some exception handling here
|
return # (rra) We need some exception handling here
|
||||||
if output:
|
if output:
|
||||||
log.info(output)
|
log.info(output)
|
||||||
if output.startswith(b'Wormhole code is: '):
|
if output.startswith(b"Wormhole code is: "):
|
||||||
code_line = output.decode('utf-8')
|
code_line = output.decode("utf-8")
|
||||||
return code_line.split()[-1]
|
return code_line.split()[-1]
|
||||||
|
|
||||||
|
|
||||||
def on_recv(self, entry):
|
def on_recv(self, entry):
|
||||||
"""Handler for receiving transfers."""
|
"""Handler for receiving transfers."""
|
||||||
code = entry.get_text()
|
code = entry.get_text()
|
||||||
|
Loading…
Reference in New Issue
Block a user