Skip to content

Commit

Permalink
Fix _close() on MNEAnnotationsFigure and MNESelectionFigure [circle d…
Browse files Browse the repository at this point in the history
…eploy] (#13086)

Co-authored-by: Richard Höchenberger <[email protected]>
  • Loading branch information
wmvanvliet and hoechenberger authored Jan 27, 2025
1 parent 3db12ff commit 631ddb3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions mne/viz/_mpl_figure.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ def _inch_to_rel(self, dim_inches, horiz=True):
class MNEAnnotationFigure(MNEFigure):
"""Interactive dialog figure for annotations."""

def _close(self, event):
def _close(self, event=None):
"""Handle close events (via keypress or window [x])."""
parent = self.mne.parent_fig
# disable span selector
Expand Down Expand Up @@ -275,7 +275,7 @@ def _set_active_button(self, idx, *, draw=True):
class MNESelectionFigure(MNEFigure):
"""Interactive dialog figure for channel selections."""

def _close(self, event):
def _close(self, event=None):
"""Handle close events."""
self.mne.parent_fig.mne.child_figs.remove(self)
self.mne.fig_selection = None
Expand Down
2 changes: 1 addition & 1 deletion tutorials/epochs/60_make_fixed_length_epochs.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
We will also briefly demonstrate how to use these epochs in connectivity
analysis.
First, we import necessary modules and read in a sample raw data set.
First, we import the necessary modules and read in a sample raw data set.
This data set contains brain activity that is event-related, i.e.,
synchronized to the onset of auditory stimuli. However, rather than creating
epochs by segmenting the data around the onset of each stimulus, we will
Expand Down

0 comments on commit 631ddb3

Please sign in to comment.