From 8f0c784187e55a7cd1015222a4347bf3fda14e90 Mon Sep 17 00:00:00 2001 From: Robert Honz Date: Wed, 22 Oct 2025 21:52:20 +0200 Subject: refactor(gui): ✨ update album download options and improve session validation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Added a new action to download all albums in a playlist. * Removed the deprecated `validate_session` method and replaced it with a direct call to `self.tidal.session.check_login()`. * Adjusted the UI layout in `dialog_settings` to accommodate new options and improved sizing. --- tidal_dl_ng/gui.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'tidal_dl_ng/gui.py') diff --git a/tidal_dl_ng/gui.py b/tidal_dl_ng/gui.py index fb8b6c8..14142c1 100644 --- a/tidal_dl_ng/gui.py +++ b/tidal_dl_ng/gui.py @@ -568,8 +568,10 @@ class MainWindow(QtWidgets.QMainWindow, Ui_MainWindow): # We build the menu. menu = QtWidgets.QMenu() menu.addAction("Download Playlist", lambda: self.thread_download_list_media(point)) + menu.addAction( + "Download All Albums in Playlist", lambda: self.thread_it(self.on_download_all_albums_from_playlist, point) + ) menu.addAction("Copy Share URL", lambda: self.on_copy_url_share(self.tr_lists_user, point)) - menu.addAction("Download All Albums", lambda: self.thread_it(self.on_download_all_albums_from_playlist, point)) menu.exec(self.tr_lists_user.mapToGlobal(point)) @@ -742,7 +744,7 @@ class MainWindow(QtWidgets.QMainWindow, Ui_MainWindow): time.sleep(delay_sec) # Check session validity before making API calls - if not self.tidal.validate_session(): + if not self.tidal.session.check_login(): logger_gui.error("Session expired. Please restart the application and login again.") return albums_dict -- cgit v1.3.1