Skip to content

Commit

Permalink
GUI: Release mutex if file selector window get closed
Browse files Browse the repository at this point in the history
  • Loading branch information
rcassani committed Nov 14, 2024
1 parent fc3d266 commit 5d386f5
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion doc/license.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<body alink="#fff000" link="#fff000" vlink="#fff000">
<h4><span style="font-family: Arial Black; color: #ffffff;"><strong>THERE IS NO UNDO BUTTON!<BR>SET UP A <FONT color=red>BACKUP</FONT> OF YOUR DATABASE</strong></span></h4>
<HR>
<!-- LICENCE_START -->Version: 3.241111 (11-Nov-2024)<br>
<!-- LICENCE_START -->Version: 3.241114 (14-Nov-2024)<br>
<span style="font-style: italic;">COPYRIGHT &copy; 2000-2024
USC &amp; McGill University.<br>
</span>
Expand Down
2 changes: 1 addition & 1 deletion doc/version.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
% Brainstorm
% v. 3.241111 (11-Nov-2024)
% v. 3.241114 (14-Nov-2024)
6 changes: 6 additions & 0 deletions toolbox/gui/java_getfile.m
Original file line number Diff line number Diff line change
Expand Up @@ -258,6 +258,12 @@ function FileSelectorAction(h, ev)

function FileSelectorPropertyChanged(h, ev)
import org.brainstorm.file.*;
% Release mutex if Dialog was closed
propertyName = char(java_call(ev, 'getPropertyName'));
if strcmpi(propertyName, 'JFileChooserDialogIsClosingProperty') && isempty(java_call(ev, 'getNewValue'))
bst_mutex('release', 'FileSelector');
return
end
% Only when saving
if (DialogType == BstFileSelector.TYPE_SAVE)
switch char(java_call(ev, 'getPropertyName'))
Expand Down

0 comments on commit 5d386f5

Please sign in to comment.