Skip to content

Commit

Permalink
Close thread before app exit
Browse files Browse the repository at this point in the history
  • Loading branch information
Gustav Hansen committed Jul 6, 2017
1 parent 7792ee8 commit 63dbb69
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions hue_plus/hue_ui.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,10 @@ def __init__(self):
except serial.serialutil.SerialException:
self.error("Serial port is invalid. Try /dev/ttyACM0 for Linux or COM3 or COM4 for Windows")

def closeEvent(self, event):
self.checkAudio()
event.accept()

def error(self, message):
msg = QMessageBox()
msg.setText(message)
Expand Down

0 comments on commit 63dbb69

Please sign in to comment.