-
-
Notifications
You must be signed in to change notification settings - Fork 410
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
Migrate Debug menu to app-model #6915
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #6915 +/- ##
==========================================
- Coverage 92.48% 92.42% -0.07%
==========================================
Files 612 612
Lines 55184 55189 +5
==========================================
- Hits 51038 51006 -32
- Misses 4146 4183 +37 ☔ View full report in Codecov by Sentry. |
Note that the enablement here is not correct currently, I realise in order to use a function call as an Need some thought on how best to do this. |
In light of all the discussion about contexts (see: pyapp-kit/app-model#199, pyapp-kit/app-model#198, pyapp-kit/app-model#196), I've placed the debug 'is_set_trace_active' context key in Note new changes depend on pyapp-kit/app-model#199. |
I think this is ready for review now. Note that I have 'manually' updated the 'is_set_trace_active' context key on |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pulled this down and all works as expected! Agreed the manual update of the context on_about_to_show
is not great but we're still working to a solution there so I think it's ok for now. Thanks @lucyleeow!
@@ -164,6 +165,10 @@ def __init__( | |||
# done outside the widget. See #1571 | |||
self.setFocusPolicy(Qt.FocusPolicy.StrongFocus) | |||
|
|||
# Ideally this would be in `NapariApplication` but that is outside of Qt | |||
self._ctx = create_context(self) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would be nice to call this viewer_context
or something
References and relevant issues
Towards #4860
Description
Migrates debug menu to app-model