diff --git a/tsgqc.m b/tsgqc.m index 0a5178639d919ae31672c7430c0f877de5778b29..f27e320f68b5357072deca2c61b97c1294185233 100644 --- a/tsgqc.m +++ b/tsgqc.m @@ -4149,15 +4149,15 @@ end end % enable toolbar on map figure from menu -% ------------------------------------ +% see Reverting axes controls in figure toolbar under: +% https://undocumentedmatlab.com/blog/reverting-axes-controls-in-figure-toolbar +% and Matlab Central: +% https://fr.mathworks.com/matlabcentral/answers/419036-what-happened-to-the-figure-toolbar-in-r2018b-why-is-it-an-axes-toolbar-how-can-i-put-the-buttons +% -------------------------------------------------------------------- function mapToolBarCallback(src, evnt) - get(hMapFig, 'toolbar') + if( strcmp(get(hMapFig, 'toolbar'), 'none')) set(hMapFig, 'toolbar', 'figure'); - % see Reverting axes controls in figure toolbar under: - % https://undocumentedmatlab.com/blog/reverting-axes-controls-in-figure-toolbar - % and Matlab Central: - % https://fr.mathworks.com/matlabcentral/answers/419036-what-happened-to-the-figure-toolbar-in-r2018b-why-is-it-an-axes-toolbar-how-can-i-put-the-buttons if ~verLessThan('matlab','9.5') addToolbarExplorationButtons(hMapFig); end