-
Notifications
You must be signed in to change notification settings - Fork 81
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add callback mechanism for GUI mode #301
base: main
Are you sure you want to change the base?
Commits on Jul 15, 2024
-
In GUI mode, stash ImageJ gateway in a global var
Otherwise, there is no way to access it from other threads. This may be useful for scenarios like napari-imagej, where access to Python scripting is available from threads other than the blocked one.
Configuration menu - View commit details
-
Copy full SHA for fec5cee - Browse repository at this point
Copy the full SHA fec5ceeView commit details -
Make rai_lock property private
This is an internal variable, not intended as public API.
Configuration menu - View commit details
-
Copy full SHA for bd2e4d3 - Browse repository at this point
Copy the full SHA bd2e4d3View commit details -
Configuration menu - View commit details
-
Copy full SHA for f38b200 - Browse repository at this point
Copy the full SHA f38b200View commit details -
Simplify name of ImageJ2 gateway fixture
It doesn't need to be "ij_wrapper" or "ij_fixture". It's OK to be ij!
Configuration menu - View commit details
-
Copy full SHA for 29c2f9e - Browse repository at this point
Copy the full SHA 29c2f9eView commit details -
Add a simple test of when_imagej_starts callback
This test checks that functions registered via when_imagej_starts get called as part of imagej.init.
Configuration menu - View commit details
-
Copy full SHA for ccb0e81 - Browse repository at this point
Copy the full SHA ccb0e81View commit details -
Configuration menu - View commit details
-
Copy full SHA for 221da1e - Browse repository at this point
Copy the full SHA 221da1eView commit details -
Add docs section on how to use when_imagej_starts
This commit adds section 5.2 to the "Convenience methods of PyImageJ" that describes how to use the when_image_starts callback mechanism.
Configuration menu - View commit details
-
Copy full SHA for 3bae68b - Browse repository at this point
Copy the full SHA 3bae68bView commit details -
Add check to determine if current thread is main
This commit introduces a check to determine if the current running thread is the main thread. If True, then we continue to block interactive mode on macOS (it is not possible to share the main thread with GUI event loop needed for the ImageJ GUI). If False, then the current thread is *not* the main thread (e.g. a jaunched session) and interactive mode for macOS can proceed.
Configuration menu - View commit details
-
Copy full SHA for 735304b - Browse repository at this point
Copy the full SHA 735304bView commit details
Commits on Jul 19, 2024
-
Use descriptive attribute name for callback test
Use a more descriptive attribute name and value for when_imagej_starts() test.
Configuration menu - View commit details
-
Copy full SHA for 7667a09 - Browse repository at this point
Copy the full SHA 7667a09View commit details -
Improve macOS pthread detection exception handling
This commit adds the pthread library loading exception to the logger and assumes that the current thread is the main thread if no pthread library is found.
Configuration menu - View commit details
-
Copy full SHA for 972592d - Browse repository at this point
Copy the full SHA 972592dView commit details
Commits on Oct 14, 2024
-
Use None as the getattr default, not True
The default here should be None, not True, otherwise this test does not actually test for the `_testing` attribute value.
Configuration menu - View commit details
-
Copy full SHA for b2ce4cb - Browse repository at this point
Copy the full SHA b2ce4cbView commit details
Commits on Oct 15, 2024
-
Improve gui mode gateway clean up
This commit improves how we clean up the gateway once the UI is closed in gui mode. Although it is highly unlikely, it is possible for a user to run into a NameError when deleting the gateway if a user enters gui mode but is NOT on macos and successfully exits the gui without crashing the session (see next below, this requires some playing around). This is resolved by assigning the gateway to None, ensuring there is *something* to delete if no gateway object is assigned. This commit also adds an additional check for a running JVM instance when in gui mode on non-macos systems. This prevents a `jpype._core.JVMNotRunning: Java Virtual Machine is not running` error that is produced when the imagej ui visbility is polled but is no longer available because the JVM has been shut down via gui interactions.
Configuration menu - View commit details
-
Copy full SHA for 45c1448 - Browse repository at this point
Copy the full SHA 45c1448View commit details