delete figure of current parameter gui. [USAGE] current_gui_delete(fig); [IN] fig : figure handle of current_gui. [OUT] none Copyright (C) 2011, ATR All Rights Reserved. License : New BSD License(see VBMEG_LICENSE.txt)
0001 function current_gui_delete(fig) 0002 % delete figure of current parameter gui. 0003 % [USAGE] 0004 % current_gui_delete(fig); 0005 % [IN] 0006 % fig : figure handle of current_gui. 0007 % [OUT] 0008 % none 0009 % 0010 % Copyright (C) 2011, ATR All Rights Reserved. 0011 % License : New BSD License(see VBMEG_LICENSE.txt) 0012 0013 % 0014 % --- Previous check 0015 % 0016 if ~exist('fig', 'var'), error('fig is a required parameter.'); end 0017 0018 % 0019 % --- Main Procedure 0020 % 0021 data = guidata(fig); 0022 0023 % delete advanced parameter figure 0024 for k=1:length(data.adv_fig) 0025 if ishandle(data.adv_fig(k)) 0026 current_gui_advanced_delete(data.adv_fig(k)); 0027 end 0028 end 0029 0030 delete(fig);