Ignore:
Timestamp:
Feb 21, 2017 1:03:50 PM (6 years ago)
Author:
srkline
Message:

minor changes to prefix functions with "V_" to avoid conflicts with non-VSANS functions.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_MaskUtils.ipf

    r1023 r1024  
    3030// passing null file string presents a dialog 
    3131// called from the Main Button " Read Mask" 
    32 Proc LoadFakeMASKData() 
     32Proc V_LoadMASKData() 
    3333        V_LoadHDF5Data("","MSK") 
    3434End 
     
    8181 
    8282// called from the main button "Draw Mask" 
    83 Proc Edit_a_Mask() 
     83Proc V_Edit_a_Mask() 
    8484        V_EditMask() 
    8585end 
     
    101101                endif 
    102102                 
    103                 Execute "MaskEditorPanel()" 
     103                Execute "V_MaskEditorPanel()" 
    104104        endif 
    105105End 
     
    113113//    -- help (button is there, fill in the content) 
    114114// 
    115 Proc MaskEditorPanel() : Panel 
     115Proc V_MaskEditorPanel() : Panel 
    116116        PauseUpdate; Silent 1           // building window... 
    117117 
     
    119119//      ShowTools/A 
    120120         
    121         PopupMenu popup_0,pos={20,50},size={109,20},proc=SetMaskPanelPopMenuProc,title="Detector Panel" 
     121        PopupMenu popup_0,pos={20,50},size={109,20},proc=V_SetMaskPanelPopMenuProc,title="Detector Panel" 
    122122        PopupMenu popup_0,mode=1,popvalue="FT",value= #"\"FL;FR;FT;FB;MR;ML;MT;MB;B;\"" 
    123123        PopupMenu popup_2,pos={20,20},size={109,20},title="Data Source"//,proc=SetFldrPopMenuProc 
     
    126126        SetVariable setvar0,pos={257.00,20.00},size={150.00,14.00},title="tube number" 
    127127        SetVariable setvar0,limits={0,127,1},value=root:Packages:NIST:VSANS:Globals:Mask:gMaskTube 
    128         Button button_0,pos={257,46.00},size={50.00,20.00},proc=AddToMaskButtonProc,title="Add" 
    129         Button button_1,pos={319.00,46.00},size={50.00,20.00},proc=RemoveFromMaskButtonProc,title="Del" 
    130         Button button_2,pos={409.00,46.00},size={90.00,20.00},proc=ToggleMaskButtonProc,title="Toggle" 
    131         Button button_3,pos={509.00,46.00},size={80.00,20.00},proc=SaveMaskButtonProc,title="Save" 
    132         Button button_4,pos={603.00,10.00},size={20.00,20.00},proc=DrawMaskHelpButtonProc,title="?" 
    133         CheckBox check_0,pos={190.00,23.00},size={37.00,15.00},proc=DrawMaskRadioCheckProc,title="Row" 
     128        Button button_0,pos={257,46.00},size={50.00,20.00},proc=V_AddToMaskButtonProc,title="Add" 
     129        Button button_1,pos={319.00,46.00},size={50.00,20.00},proc=V_RemoveFromMaskButtonProc,title="Del" 
     130        Button button_2,pos={409.00,46.00},size={90.00,20.00},proc=V_ToggleMaskButtonProc,title="Toggle" 
     131        Button button_3,pos={509.00,46.00},size={80.00,20.00},proc=V_SaveMaskButtonProc,title="Save" 
     132        Button button_4,pos={603.00,10.00},size={20.00,20.00},proc=V_DrawMaskHelpButtonProc,title="?" 
     133        CheckBox check_0,pos={190.00,23.00},size={37.00,15.00},proc=V_DrawMaskRadioCheckProc,title="Row" 
    134134        CheckBox check_0,value= 0,mode=1 
    135         CheckBox check_1,pos={190.00,46.00},size={32.00,15.00},proc=DrawMaskRadioCheckProc,title="Col" 
     135        CheckBox check_1,pos={190.00,46.00},size={32.00,15.00},proc=V_DrawMaskRadioCheckProc,title="Col" 
    136136        CheckBox check_1,value= 1,mode=1 
    137137 
    138         SetWindow MaskEditPanel, hook(MyHook)=MaskWindowHook 
     138        SetWindow MaskEditPanel, hook(MyHook)=V_MaskWindowHook 
    139139 
    140140        // draw the correct images 
    141141        //draw the detector panel 
    142         DrawPanelToMask("FT") 
     142        V_DrawPanelToMask("FT") 
    143143         
    144144        // overlay the current mask 
     
    147147EndMacro 
    148148 
    149 Function DrawMaskHelpButtonProc(ba) : ButtonControl 
     149Function V_DrawMaskHelpButtonProc(ba) : ButtonControl 
    150150        STRUCT WMButtonAction &ba 
    151151 
     
    167167// update the limits on the tube nubmer based on row/col and the panel (gMaskMaxIndex global) 
    168168// 
    169 Function DrawMaskRadioCheckProc(cba) : CheckBoxControl 
     169Function V_DrawMaskRadioCheckProc(cba) : CheckBoxControl 
    170170        STRUCT WMCheckboxAction &cba 
    171171 
     
    211211End 
    212212 
    213 Function MaskWindowHook(s) 
     213Function V_MaskWindowHook(s) 
    214214        STRUCT WMWinHookStruct &s 
    215215         
     
    257257                        if(s.specialKeyCode == 102) 
    258258                                //up arrow 
    259                                 AddToMaskButtonProc(ba) 
     259                                V_AddToMaskButtonProc(ba) 
    260260                        endif 
    261261                        if(s.specialKeyCode == 103) 
    262262                                //down arrow 
    263                                 RemoveFromMaskButtonProc(ba) 
     263                                V_RemoveFromMaskButtonProc(ba) 
    264264                        endif 
    265265 
     
    297297End 
    298298 
    299 Function ToggleMaskButtonProc(ba) : ButtonControl 
     299 
     300Function V_ToggleMaskButtonProc(ba) : ButtonControl 
    300301        STRUCT WMButtonAction &ba 
    301302 
     
    322323 
    323324 
    324 Function AddToMaskButtonProc(ba) : ButtonControl 
     325Function V_AddToMaskButtonProc(ba) : ButtonControl 
    325326        STRUCT WMButtonAction &ba 
    326327 
     
    355356End 
    356357 
    357 Function RemoveFromMaskButtonProc(ba) : ButtonControl 
     358Function V_RemoveFromMaskButtonProc(ba) : ButtonControl 
    358359        STRUCT WMButtonAction &ba 
    359360 
     
    391392// function to choose which detector panel to display, and then to actually display it 
    392393// 
    393 Function SetMaskPanelPopMenuProc(pa) : PopupMenuControl 
     394Function V_SetMaskPanelPopMenuProc(pa) : PopupMenuControl 
    394395        STRUCT WMPopupAction &pa 
    395396 
     
    415416         
    416417                        // draw the correct images 
    417                         DrawPanelToMask(popStr) 
     418                        V_DrawPanelToMask(popStr) 
    418419 
    419420                        // fake a "click" on the radio buttons to re-set the row/col limits 
     
    428429                        endif 
    429430                         
    430                         DrawMaskRadioCheckProc(cba)             //call the radio button action proc      
     431                        V_DrawMaskRadioCheckProc(cba)           //call the radio button action proc      
    431432                         
    432433                        //overlay the mask 
     
    455456// draw the selected panel and the model calculation, adjusting for the  
    456457// orientation of the panel and the number of pixels, and pixel sizes 
    457 Function DrawPanelToMask(str) 
     458Function V_DrawPanelToMask(str) 
    458459        String str 
    459460         
     
    662663 
    663664 
    664 Function SaveMaskButtonProc(ba) : ButtonControl 
     665Function V_SaveMaskButtonProc(ba) : ButtonControl 
    665666        STRUCT WMButtonAction &ba 
    666667 
Note: See TracChangeset for help on using the changeset viewer.