From f8c911be6a20631e7cd72014b7287c2cb980f448 Mon Sep 17 00:00:00 2001
From: Jacques Grelet <jacques.grelet@ird.fr>
Date: Fri, 13 Feb 2009 09:34:16 +0000
Subject: [PATCH] remove comment in hMainFig = figure(... declaration for  
 'CloseRequestFcn', @QuitMenuCallback,...

add evalin('base','clear all') in quitProgram
clear base workspace just before quit, this is the only method
to clear NetCDF variables assign to base workspace with assignin
---
 tsg_util/quitProgram.m | 9 +++++++--
 tsgqc.m                | 1 +
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/tsg_util/quitProgram.m b/tsg_util/quitProgram.m
index 85134f1..60b989a 100644
--- a/tsg_util/quitProgram.m
+++ b/tsg_util/quitProgram.m
@@ -11,8 +11,8 @@ function quitProgram(DEFAULT_PATH_FILE, varargin)
 
 % $Id$
 
-% close windows
-% -------------
+% close all windows
+% -----------------
 for i=1:size(varargin,2)
   delete(varargin{i});
 end
@@ -31,4 +31,9 @@ rmpath( [DEFAULT_PATH_FILE filesep 'tsg_io'] );
 % --------------------------
 rehash;
 
+% clear base workspace just before quit, this is the only method
+% to clear NetCDF variables assign to base workspace with assignin
+% ----------------------------------------------------------------
+evalin('base','clear all');
+
 end
\ No newline at end of file
diff --git a/tsgqc.m b/tsgqc.m
index 6fc504b..aee96d8 100644
--- a/tsgqc.m
+++ b/tsgqc.m
@@ -131,6 +131,7 @@ hMainFig = figure(...
    --------------------------------------
   'CloseRequestFcn', @QuitMenuCallback,...
   %}
+  'CloseRequestFcn', @QuitMenuCallback,...
   'HandleVisibility', handleVisibility,...
   'Visible','on',...
   'Tag','TAG_TSG-QC_GUI',...
-- 
GitLab