Wobuzz/wobuzz/gui_communication/gui_communication.py

22 lines
544 B
Python

#!/usr/bin/python3
from .track_control import TrackControl
class GUICommunication:
"""
Class handling events that are a bit more complex.
"""
def __init__(self, app):
self.app = app
self.track_control = TrackControl(self.app)
def on_track_change(self, previous_track=None, track=None):
self.track_control.on_track_change(previous_track, track)
self.app.library.on_track_change(previous_track, track)
def on_playstate_update(self):
self.track_control.on_playstate_update()