From fb0f44ee43027953f1601d5a4e4f5792e0693d16 Mon Sep 17 00:00:00 2001 From: Shrivaths Shyam Date: Thu, 7 Dec 2023 09:54:54 -0800 Subject: [PATCH 1/5] Add helpmenu option --- sleap/gui/app.py | 3 +++ sleap/gui/commands.py | 9 +++++++++ 2 files changed, 12 insertions(+) diff --git a/sleap/gui/app.py b/sleap/gui/app.py index f463a04e3..8e47ccce4 100644 --- a/sleap/gui/app.py +++ b/sleap/gui/app.py @@ -1023,6 +1023,9 @@ def new_instance_menu_action(): helpMenu.addSeparator() helpMenu.addAction("Keyboard Shortcuts", self._show_keyboard_shortcuts_window) + helpMenu.addSeparator() + helpMenu.addAction("Announcements", self.commands.showBulletin) + def process_events_then(self, action: Callable): """Decorates a function with a call to first process events.""" diff --git a/sleap/gui/commands.py b/sleap/gui/commands.py index 8ac4d87fb..ec378ace6 100644 --- a/sleap/gui/commands.py +++ b/sleap/gui/commands.py @@ -624,6 +624,10 @@ def openPrereleaseVersion(self): """Open the current prerelease version.""" self.execute(OpenPrereleaseVersion) + def showBulletin(self): + """Opens the latest bulletin""" + self.execute(ShowBulletin) + # File Commands @@ -3283,6 +3287,11 @@ def do_action(context: CommandContext, params: dict): if rls is not None: context.openWebsite(rls.url) +class ShowBulletin(AppCommand): + @staticmethod + def do_action(context: CommandContext, params: dict): + context.app.bulletin_dialog() + def copy_to_clipboard(text: str): """Copy a string to the system clipboard. From b5980fee3e9b971b8dd44a524654299bb2deddf5 Mon Sep 17 00:00:00 2001 From: Shrivaths Shyam Date: Mon, 18 Dec 2023 12:10:51 -0800 Subject: [PATCH 2/5] macos pyside2 >=5.12,<=5.15.6 --- environment_mac.yml | 2 +- sleap/gui/commands.py | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/environment_mac.yml b/environment_mac.yml index 85ef7d3b9..34b768f03 100644 --- a/environment_mac.yml +++ b/environment_mac.yml @@ -23,7 +23,7 @@ dependencies: - conda-forge::pillow - conda-forge::psutil - conda-forge::pykalman - - conda-forge::pyside2 >=5.12 # To ensure application works correctly with QtPy. + - conda-forge::pyside2 >=5.12,<=5.15.6 # To ensure application works correctly with QtPy. - conda-forge::python ~=3.9 - conda-forge::python-rapidjson - conda-forge::pyyaml diff --git a/sleap/gui/commands.py b/sleap/gui/commands.py index b9e0fb95e..81ce7e340 100644 --- a/sleap/gui/commands.py +++ b/sleap/gui/commands.py @@ -3401,6 +3401,7 @@ def do_action(context: CommandContext, params: dict): if rls is not None: context.openWebsite(rls.url) + class ShowBulletin(AppCommand): @staticmethod def do_action(context: CommandContext, params: dict): From f8f5fa776d8496e5f690a241f648a5c53c528f89 Mon Sep 17 00:00:00 2001 From: Shrivaths Shyam Date: Mon, 18 Dec 2023 12:54:48 -0800 Subject: [PATCH 3/5] pyside6 >=6 macos --- environment_mac.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/environment_mac.yml b/environment_mac.yml index 34b768f03..1e9d74d01 100644 --- a/environment_mac.yml +++ b/environment_mac.yml @@ -23,7 +23,7 @@ dependencies: - conda-forge::pillow - conda-forge::psutil - conda-forge::pykalman - - conda-forge::pyside2 >=5.12,<=5.15.6 # To ensure application works correctly with QtPy. + - conda-forge::pyside6 >=6 # To ensure application works correctly with QtPy. - conda-forge::python ~=3.9 - conda-forge::python-rapidjson - conda-forge::pyyaml From 027c4d6458a6395decd888fc19bdc914d944ed15 Mon Sep 17 00:00:00 2001 From: Shrivaths Shyam Date: Tue, 19 Dec 2023 12:16:56 -0800 Subject: [PATCH 4/5] pyside == 6.2.2.1 --- environment_mac.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/environment_mac.yml b/environment_mac.yml index 1e9d74d01..7f98c43f2 100644 --- a/environment_mac.yml +++ b/environment_mac.yml @@ -23,7 +23,7 @@ dependencies: - conda-forge::pillow - conda-forge::psutil - conda-forge::pykalman - - conda-forge::pyside6 >=6 # To ensure application works correctly with QtPy. + - conda-forge::pyside6 == 6.2.2.1 # To ensure application works correctly with QtPy. - conda-forge::python ~=3.9 - conda-forge::python-rapidjson - conda-forge::pyyaml From 0dcd27a58c6ec790624b59f05bf0e916a08623c7 Mon Sep 17 00:00:00 2001 From: Shrivaths Shyam Date: Thu, 21 Dec 2023 00:54:33 -0800 Subject: [PATCH 5/5] Edit the dhelp menu option --- sleap/gui/app.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sleap/gui/app.py b/sleap/gui/app.py index 8e47ccce4..94cbba77d 100644 --- a/sleap/gui/app.py +++ b/sleap/gui/app.py @@ -1024,7 +1024,7 @@ def new_instance_menu_action(): helpMenu.addAction("Keyboard Shortcuts", self._show_keyboard_shortcuts_window) helpMenu.addSeparator() - helpMenu.addAction("Announcements", self.commands.showBulletin) + helpMenu.addAction("What's New?", self.commands.showBulletin) def process_events_then(self, action: Callable): """Decorates a function with a call to first process events."""