Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

fix plot options multi to single select #2505

Merged
merged 1 commit into from
Oct 11, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,9 @@ Bug Fixes
- Deleting a subset while actively editing it now deselects the subset tool,
preventing the appearance of "ghost" subsets. [#2497]

- Fixes a bug in plot options where switching from multi to single-select mode
failed to properly update the selection. [#2505]

Cubeviz
^^^^^^^

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,9 @@ def _update_stretch_histogram(self, msg={}):
for attr in ('x_min', 'x_max', 'y_min', 'y_max'):
vs.add_callback(attr, self._update_stretch_histogram)
if isinstance(msg, dict) and msg.get('name') == 'viewer_selected':
viewer_label_old = msg.get('old')[0] if self.multiselect else msg.get('old')
viewer_label_old = msg.get('old')
if isinstance(viewer_label_old, list):
viewer_label_old = viewer_label_old[0]
if len(viewer_label_old):
vs_old = self.app.get_viewer(viewer_label_old).state
for attr in ('x_min', 'x_max', 'y_min', 'y_max'):
Expand Down