Skip to content
Snippets Groups Projects
Commit e5ef1c51 authored by Yves Gouriou's avatar Yves Gouriou
Browse files

Developpement du module de correction ajout des icones de selection de debut...

Developpement du module de correction ajout des icones de selection de debut et fin de série temporelle
parent cb2ef17f
No related branches found
No related tags found
No related merge requests found
......@@ -85,6 +85,6 @@ set(hAxes(2), 'Visible', 'on' );
% The 3 axes will behave identically when zoomed and panned
% ---------------------------------------------------------
%linkaxes([hAxes(1),hAxes(2),hAxes(3)], 'x');
linkaxes([hAxes(1),hAxes(2)], 'x');
end
......@@ -127,6 +127,23 @@ function tsgcor_GUI( hMainFig )
[DEFAULT_PATH_FILE 'tsg_icon' filesep 'bottleicon.mat']),...
'HandleVisibility','callback', ...
'ClickedCallback', @BottleMenuCallback);
hStartlimitPushtool = uipushtool(... % Open toolbar button
'Parent',hToolbar,...
'TooltipString','Start time',...
'Separator', 'on', ...
'Tag', 'off', ...
'CData',iconRead(...
[DEFAULT_PATH_FILE 'tsg_icon' filesep 'startlimit.mat']),...
'HandleVisibility','callback', ...
'ClickedCallback', @TimeLimitCallback);
hEndlimitPushtool = uipushtool(... % Open toolbar button
'Parent',hToolbar,...
'TooltipString','End time',...
'Tag', 'off', ...
'CData',iconRead(...
[DEFAULT_PATH_FILE 'tsg_icon' filesep 'endlimit.mat']),...
'HandleVisibility','callback', ...
'ClickedCallback', @TimeLimitCallback);
% Static text that displays the position, salinity and temperature
% ----------------------------------------------------------------
......@@ -176,7 +193,7 @@ function tsgcor_GUI( hMainFig )
htDateMin = uicontrol( ...
'Parent', hpDateLimit, ...
'Style', 'Text', ...
'String', 'Minimum (mm/dd/yyyy)', ...
'String', 'Minimum (yyyy-mm-dd hh:mm:ss)', ...
'HorizontalAlignment', 'left', ...
'Units', 'normalized', ...
'backgroundcolor', 'white', ...
......@@ -193,7 +210,7 @@ function tsgcor_GUI( hMainFig )
htDateMax = uicontrol( ...
'Parent', hpDateLimit, ...
'Style', 'Text', ...
'String', 'Maximum (mm/dd/yyyy)', ...
'String', 'Maximum (yyyy-mm-dd hh:mm:ss)', ...
'HorizontalAlignment', 'left', ...
'Units', 'normalized', ...
'backgroundcolor', 'white', ...
......@@ -273,8 +290,8 @@ tsg = getappdata( hMainFig, 'tsg_data' );
sample = getappdata( hMainFig, 'sample' );
cst = getappdata( hMainFig, 'constante');
dateMin = datestr(tsg.TIME(1), 23);
dateMax = datestr(tsg.TIME(end), 23);
dateMin = datestr(tsg.TIME(1), 31);
dateMax = datestr(tsg.TIME(end), 31);
set( hetDateMin, 'String', dateMin);
set( hetDateMax, 'String', dateMax);
......@@ -323,7 +340,9 @@ set( hChild1Fig, 'Tag', 'ButtonMotionOn');
zoomAdaptiveDateTicks('off');
case 'off'
pan off
% set(hQCPushtool, 'Tag', 'off' );
set(hChild1Fig,'Pointer','arrow');
set(hEndlimitPushtool, 'Tag', 'off' );
set(hStartlimitPushtool, 'Tag', 'off' );
zoom on
zoomAdaptiveDateTicks('on');
......@@ -347,13 +366,61 @@ set( hChild1Fig, 'Tag', 'ButtonMotionOn');
panAdaptiveDateTicks('off');
case 'off'
zoom off
% set(hQCPushtool, 'Tag', 'off' );
set(hChild1Fig,'Pointer','arrow');
set(hEndlimitPushtool, 'Tag', 'off' );
set(hStartlimitPushtool, 'Tag', 'off' );
pan on
panAdaptiveDateTicks('on');
end
end
%----------------------------------------------------------------------
function TimeLimitCallback(hObject, eventdata)
% Callback function run when the ....
% Desactivate the Zoom and Pan functions.
% ---------------------------------------
zoom off; pan off
panAdaptiveDateTicks('off');zoomAdaptiveDateTicks('off');
% Retrieve named application data
% -------------------------------
tsg = getappdata( hMainFig, 'tsg_data');
% Toggle the tag of the Qc pushbutton to 'on' or 'off'
% ----------------------------------------------------
switch get(hObject, 'Tag');
case 'off'
set(hObject, 'Tag', 'on' );
set( hChild1Fig, 'Pointer', 'crosshair');
case 'on'
set(hObject, 'Tag', 'off' );
set(hChild1Fig,'Pointer','arrow');
end
% Wait for key press
% ------------------
[x, y] = ginput(1);
% Write the date in the Editable uicontrol
% ----------------------------------------
if hObject == hEndlimitPushtool
set( hetDateMax, 'String', datestr(x, 31));
else
set( hetDateMin, 'String', datestr(x, 31));
end
set(hChild1Fig,'Pointer','arrow');
end
%----------------------------------------------------------------------
function StartLimitCallback(hObject, eventdata)
% Callback function run when the ....
end
%----------------------------------------------------------------------
function QCMenuCallback(gcbo, eventdata,handles)
% Callback function run when the QC pushbutton is selected
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment