-
Notifications
You must be signed in to change notification settings - Fork 98
Replace dynamic on_trait_change with observe part 2 #591
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
Merged
Merged
Changes from all commits
Commits
Show all changes
20 commits
Select commit
Hold shift + click to select a range
b43df96
update scatter_inspector_overlay.py
aaronayres35 4c34c1c
update tools/image_inspector_tool.py
aaronayres35 517dfa1
update examples/demo/zoomed_plot/zoom_overlay.py
aaronayres35 49bc9d7
update and fix examples/demo/financial/stock_prices.py
aaronayres35 67fc1b1
update examples/demo/financial/correlations.py and fix changes to sca…
aaronayres35 0a09063
update examples/demo/basic/scatter_toggle.py and fix changes to chaco…
aaronayres35 1137f04
update examples/demo/basic/scatter_select.py
aaronayres35 6de2d63
update examples/demo/basic/scatter_rect_select.py
aaronayres35 4d7ee30
update examples/demo/basic/scatter_inspector.py
aaronayres35 c48665f
update examples/demo/basic/image_lasso.py
aaronayres35 066d9f6
update examples/demo/advanced/scalar_image_function_inspector.py
aaronayres35 e45adbe
updat examples/demo/advanced/scalar_image_function_inspector_old.py
aaronayres35 c22e513
update examples/demo/chaco_trait_editor.py
aaronayres35 41f4c0d
update chaco/tools/tests/test_scatter_inspector.py
aaronayres35 3bd9cc7
update chaco/tools/tests/test_image_inspector.py
aaronayres35 d422909
update chaco/tools/simple_zoom.py
aaronayres35 51bf40d
update chaco/tools/range_selection.py tthis was and still is broken
aaronayres35 db11277
update chaco/tools/range_selection_overlay.py
aaronayres35 fa617a6
flake8 indentation
aaronayres35 8680d8c
Merge branch 'master' into replace-dynamic-on_trait_change2
aaronayres35 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -660,13 +660,13 @@ def _determine_axis(self): | |
| else: | ||
| return 0 | ||
|
|
||
| def __mapper_changed(self): | ||
| def __mapper_changed(self, event): | ||
| self.deselect() | ||
|
|
||
| def _axis_changed(self, old, new): | ||
| if old is not None: | ||
| self.plot.on_trait_change(self.__mapper_changed, | ||
| old + "_mapper", remove=True) | ||
| self.plot.observe( | ||
| self.__mapper_changed, old + "_mapper", remove=True | ||
| ) | ||
| if new is not None: | ||
| self.plot.on_trait_change(self.__mapper_changed, | ||
| old + "_mapper", remove=True) | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This previous code seems like it was a copy paste error... |
||
| self.plot.observe(self.__mapper_changed, new + "_mapper") | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
This is tangential but i want to dig a little and find the source of this comment - it looks like there was going to be some fancy traits feature which would remove unnecessary code.