


h = dyn_waitbar_close(h) adaptive close waitbar, compatible with octave and when console_mode=1


0001 function dyn_waitbar_close(h) 0002 % h = dyn_waitbar_close(h) 0003 % adaptive close waitbar, compatible with 0004 % octave and when console_mode=1 0005 0006 % 0007 % Copyright (C) 2011 Dynare Team 0008 % 0009 % This file is part of Dynare. 0010 % 0011 % Dynare is free software: you can redistribute it and/or modify 0012 % it under the terms of the GNU General Public License as published by 0013 % the Free Software Foundation, either version 3 of the License, or 0014 % (at your option) any later version. 0015 % 0016 % Dynare is distributed in the hope that it will be useful, 0017 % but WITHOUT ANY WARRANTY; without even the implied warranty of 0018 % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 0019 % GNU General Public License for more details. 0020 % 0021 % You should have received a copy of the GNU General Public License 0022 % along with Dynare. If not, see <http://www.gnu.org/licenses/>. 0023 global options_ 0024 0025 if exist('OCTAVE_VERSION') || options_.console_mode, 0026 clear dyn_waitbar; 0027 diary on, 0028 fprintf('\n'); 0029 else 0030 close(h), 0031 end 0032 0033 clear dyn_waitbar; 0034 0035