Ignore:
Timestamp:
Apr 6, 2010 11:15:13 AM (12 years ago)
Author:
srkline
Message:

Modified installer to copy folders, rather than move them. This allows the installer to be re-run without downloading or unzipping a fresh copy.

Added a "refresh" button to the PlotManager?. Streamlined the filtering out of non-plottable data.

Made XML the default (set the global to 1 in Wrapper, Initialize, and Main_USANS).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sans/Dev/trunk/NCNR_User_Procedures/Common/Packages/PlotManager/PlotManager_v40.ipf

    r570 r662  
    4040        ListBox fileList,listWave=root:Packages:NIST:OneDLoader:fileWave 
    4141        ListBox fileList,selWave=root:Packages:NIST:OneDLoader:selWave,mode= 4 
    42         Button button6,pos={238,153},size={100,20},proc=A_OneDLoader_LoadButton,title="Load File(s)" 
     42        Button button6,pos={238,165},size={100,20},proc=A_OneDLoader_LoadButton,title="Load File(s)" 
    4343        Button button6,help={"Loads the selected files into memory and will graph them if that option is checked"} 
    4444        Button button7,pos={238,20},size={100,20},proc=A_OneDLoader_NewFolderButton,title="New Folder" 
    4545        Button button7,help={"Select a new data folder"} 
    46         GroupBox group0,pos={222,108},size={50,4},title="Shift-click to load" 
    47         GroupBox group0_1,pos={222,123},size={50,4},title="multiple files" 
     46        GroupBox group0,pos={222,127},size={50,4},title="Shift-click to load" 
     47        GroupBox group0_1,pos={222,143},size={50,4},title="multiple files" 
    4848        GroupBox group1,pos={7,207},size={350,4} 
    49         Button button8,pos={238,50},size={100,20},proc=A_OneDLoader_HelpButton,title="Help" 
     49        Button button8,pos={238,76},size={100,20},proc=A_OneDLoader_HelpButton,title="Help" 
     50        Button button9,pos={238,48},size={100,20},proc=A_PlotManager_Refresh,title="Refresh List" 
    5051EndMacro 
    5152 
     
    244245End 
    245246 
     247//refresh the listing 
     248Function A_PlotManager_Refresh(ctrlName) : ButtonControl 
     249        String ctrlName 
     250 
     251        A_OneDLoader_GetListButton("") 
     252        return(0) 
     253End 
     254 
    246255//filters to remove only the files that are named like a raw data file, i.e. "*.SAn" 
    247256//does not check to see if they really are RAW files though...(too tedious) 
     
    323332         
    324333        list = IndexedFile(catpathName,-1,"????") 
    325         num=ItemsInList(list,";") 
    326         //print "num = ",num 
    327         for(ii=(num-1);ii>=0;ii-=1) 
    328                 item = StringFromList(ii, list  ,";") 
    329                 //simply remove all that are not raw data files (SA1 SA2 SA3) 
    330                 if( !stringmatch(item,"*.SA1*") && !stringmatch(item,"*.SA2*") && !stringmatch(item,"*.SA3*") ) 
    331                         if( !stringmatch(item,".*") && !stringmatch(item,"*.pxp") && !stringmatch(item,"*.DIV"))                //eliminate mac "hidden" files, pxp, and div files 
    332                                 newlist += item + ";" 
    333                         endif 
    334                 endif 
    335         endfor 
     334         
     335        list = RemoveFromList(ListMatch(list,"*.SA1*",";"), list, ";", 0) 
     336        list = RemoveFromList(ListMatch(list,"*.SA2*",";"), list, ";", 0) 
     337        list = RemoveFromList(ListMatch(list,"*.SA3*",";"), list, ";", 0) 
     338        list = RemoveFromList(ListMatch(list,".*",";"), list, ";", 0) 
     339        list = RemoveFromList(ListMatch(list,"*.pxp",";"), list, ";", 0) 
     340        list = RemoveFromList(ListMatch(list,"*.DIV",";"), list, ";", 0) 
     341        list = RemoveFromList(ListMatch(list,"*.GSP",";"), list, ";", 0) 
     342        list = RemoveFromList(ListMatch(list,"*.MASK",";"), list, ";", 0) 
     343 
    336344        //sort 
    337         newList = SortList(newList,";",0) 
     345        newList = SortList(List,";",0) 
    338346 
    339347        return newlist 
Note: See TracChangeset for help on using the changeset viewer.