""" AppRouter - cross-tab navigation signals ======================================== A tiny QObject signal hub connecting the watch-first pages (search, feed, browse) with the player and the downloader tab. Pages emit; the main window routes. Entry dicts are yt-dlp flat entries or the subset {id, url, title, channel, channel_url, duration, thumbnail}. """ from PySide6.QtCore import QObject, Signal class AppRouter(QObject): playVideo = Signal(dict) # play immediately in the Watch tab queueVideo = Signal(dict) # append to the play queue downloadVideo = Signal(str) # open Downloads tab with URL prefilled + analyzed openChannel = Signal(str) # open a channel URL in the Browse tab openPlaylist = Signal(str) # open a playlist URL in the Browse tab # Cookie settings were applied. YtdlpClient re-reads config per call so it # needs no telling, but the account button, the Feed's mode availability # and the live mpv handle all do -- otherwise signing in only takes effect # after a restart. cookiesChanged = Signal() # Somewhere in the UI asked for the cookie login dialog. cookieSetupRequested = Signal()