;+ ;NAME: ; thm_ui_update_history ;PURPOSE: ; Adds the string input to the state structure history array ;INPUT: ; string = a string to add to the history array ; state = the themis_w state structure, ;OUTPUT: ; state.history is updated ;HISTORY: ; sep-2006, jmm, jimm@ssl.berkeley.edu ; ;$LastChangedBy: kenb-mac $ ;$LastChangedDate: 2007-01-26 15:52:34 -0800 (Fri, 26 Jan 2007) $ ;$LastChangedRevision: 241 $ ;$URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/thmsoc/trunk/idl/themis/common/thm_ui_update_history.pro $ ; ;- Pro thm_ui_update_history, string, state history = *state.history If(is_string(history[0]) And is_string(string)) Then Begin If(strupcase(strcompress(/remove_all, history[0])) Eq 'NONE') Then Begin history = temporary(string) Endif Else Begin history = [temporary(history), temporary(string)] Endelse ptr_free, state.history state.history = ptr_new(history) Endif Else message, /info, 'No history?' Return End