Ignore:
Timestamp:
Apr 29, 2013, 11:28:23 PM (11 years ago)
Author:
sommeria
Message:

waitbar system for series improved to aloow use as stand alone fcts.

to add at the head of series fcts:
hseries=findobj(allchild(0),'Tag','series');
RUNHandle=findobj(hseries,'Tag','RUN');%handle of RUN button in GUI series
WaitbarHandle?=findobj(hseries,'Tag','Waitbar');%handle of waitbar in GUI series

call to waitbar:

update_waitbar(WaitbarHandle?,index/nbfield)
if ishandle(RUNHandle) && ~strcmp(get(RUNHandle,'BusyAction?'),'queue')

disp('program stopped by user')
break

end

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/series/civ_series.m

    r614 r624  
    7373    checkrun=0;
    7474end
     75hseries=findobj(allchild(0),'Tag','series');
     76RUNHandle=findobj(hseries,'Tag','RUN');%handle of RUN button in GUI series
     77WaitbarHandle=findobj(hseries,'Tag','Waitbar');%handle of waitbar in GUI series
    7578
    7679%% input files and indexing
     
    214217%%%%% MAIN LOOP %%%%%%
    215218for ifield=1:NbField
    216    
     219    update_waitbar(WaitbarHandle,index/nbfield)
     220    if ishandle(RUNHandle) && ~strcmp(get(RUNHandle,'BusyAction'),'queue')
     221        disp('program stopped by user')
     222        break
     223    end
    217224    %% Civ1
    218225    if isfield (Param.ActionInput,'Civ1')
Note: See TracChangeset for help on using the changeset viewer.