Changeset 509 for branches


Ignore:
Timestamp:
Jan 4, 2011, 9:56:37 AM (15 years ago)
Author:
Herwig Bauernfeind
Message:

GUI-Tools: EVFSGUI: Code refactoring

Location:
branches/guitools-2.0/evfsgui
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • branches/guitools-2.0/evfsgui/changes

    r506 r509  
    66
    77ToDo for 2.1:
    8 - Debug on/off option is badly implemented (rework required)
    9 - Create Icon. stem in order to ease maintenance of icons
    108- Fix endless loop if neither EVFS nor Netdrive is installed
    119  under all conditions
     
    1311- Passive connections/double connection detection does not seem
    1412  to work properly
     13
     14Version 2.1 beta3
     15- Refactoring: Create Icon. stem in order to ease maintenance of icons
     16- Refactoring: Common wrapper around all dynamic functions
     17- Refactoring: Remove double variables for settings and options
     18- Refactoring: Debug on/off option is properly done now
    1519
    1620Version 2.1 beta2 2010-12-26
  • branches/guitools-2.0/evfsgui/evfsgui.VRP

    r506 r509  
    1010VRXWindow: __VREFileListWindow,1,807,11033,1590,3358
    1111VRXWindow: __VRESectionListWindow,1,2674,10648,8696,4794
    12 VRXWindow: __VREToolsWindow,1,2517,7082,6480,1665
     12VRXWindow: __VREToolsWindow,1,2517,7082,6480,1669
    1313VRXWindow: __VREWindListWindow,1,542,8721,2650,3150
    1414UserFile: 1
    1515UserWindow: Main,1
    16 UserWindow: SW_PROGRESS,1
    17 UserWindow: SW_LOGIN,1
    18 UserWindow: SW_ABOUT,1
     16UserWindow: SW_SETTINGS,1
  • branches/guitools-2.0/evfsgui/evfsgui.VRX

    r506 r509  
    102102*/
    103103_AddTemplates:
    104 
    105     VolTplRH = VRMethod('CN_CURRENT', 'AddRecord', , 'First', 'Volume template', '#10:PMWP.DLL' )
    106     MpTplRH = VRMethod('CN_CURRENT', 'AddRecord', VolTplRH, 'First', 'Mountpoint template', '#10:PMWP.DLL'  )
     104    VolTplRH = VRMethod("CN_CURRENT", 'AddRecord', , 'First', 'Volume template', icons.!template )
     105    MpTplRH  = VRMethod("CN_CURRENT", 'AddRecord',  VolTplRH, 'First', 'Mountpoint template', icons.!template )
    107106return
    108107
    109108/*:VRX         _BrowseBuildPath
    110109*/
    111 _BrowseBuildPath: procedure expose options. sharerh
     110_BrowseBuildPath: procedure expose options. icons. sharerh
    112111    IF options.!debug == 1 THEN SAY time()' _BrowseBuildPath started'
    113112    rh = arg(1)
     
    117116   
    118117    do while \finished
    119         parentrh = VRMethod("CN_smbtree","GetRecordAttr",rh,"Parent")
    120         resname = VRMethod("CN_smbtree","GetRecordAttr",rh,"caption")
    121         userdata = VRMethod("CN_smbtree","GetRecordAttr",rh,"userdata")
     118        parentrh = VRMethod("CN_SMBTREE","GetRecordAttr",rh,"Parent")
     119        resname  = VRMethod("CN_SMBTREE","GetRecordAttr",rh,"caption")
     120        userdata = VRMethod("CN_SMBTREE","GetRecordAttr",rh,"userdata")
    122121        parse var userdata udatatype '|' udatamsg
    123122        parse var resname resname '0D0A'x .
     
    195194                    Ext = translate(VRParseFIleName(fname,'E'))
    196195                    select
    197                         when Ext = 'EXE' then ficon = '#3:PMWP.DLL' /* executable */
    198                         when Ext = 'CMD' then ficon = '#2:PMWP.DLL' /* OS/2 or NT batch */
    199                         when Ext = 'BAT' then ficon = '#1:PMWP.DLL' /* DOS batch */
    200                         when Ext = 'PDF' then ficon = '#80' /* PDF document */
    201                         when wordpos(Ext, 'XLS SXC ODS') > 0         then ficon = '#82' /* spreadsheet */
    202                         when wordpos(Ext, 'DOC SXW ODT') > 0         then ficon = '#86' /* text document */
    203                         when wordpos(Ext, 'FW2 FW3 FW4') > 0         then ficon = '#87' /* framework */
    204                         when wordpos(Ext, 'JPG BMP PNG GIF TIF') > 0 then ficon = '#88' /* image */
    205                         when wordpos(Ext, 'AVI MPG FLV WMV') > 0     then ficon = '#89' /* image */
    206                         when wordpos(Ext, 'WAV MP3 OGG MID') > 0     then ficon = '#90' /* sound */
    207                         when wordpos(Ext, 'WPI') > 0                 then ficon = '#91' /* warpin */
    208                         when wordpos(Ext, 'ZIP') > 0                 then ficon = '#92' /* zip */
    209                         when wordpos(Ext, 'INF HLP') > 0             then ficon = '#93' /* View */
    210                         when wordpos(Ext, 'TXT') > 0                 then ficon = '#94' /* View */
    211                         otherwise ficon = '#24:PMWP.DLL' /* default file icon */
     196                        when Ext = 'EXE' then ficon = icons.!exe /* executable */
     197                        when Ext = 'CMD' then ficon = icons.!cmd /* OS/2 or NT batch */
     198                        when Ext = 'BAT' then ficon = icons.!bat /* DOS batch */
     199                        when Ext = 'PDF' then ficon = icons.!pdf /* PDF document */
     200                        when wordpos(Ext, 'XLS SXC ODS') > 0         then ficon = icons.!spreadsheet
     201                        when wordpos(Ext, 'DOC SXW ODT') > 0         then ficon = icons.!textdocument
     202                        when wordpos(Ext, 'FW2 FW3 FW4') > 0         then ficon = icons.!framework
     203                        when wordpos(Ext, 'JPG BMP PNG GIF TIF') > 0 then ficon = icons.!image
     204                        when wordpos(Ext, 'AVI MPG FLV WMV') > 0     then ficon = icons.!movie
     205                        when wordpos(Ext, 'WAV MP3 OGG MID') > 0     then ficon = icons.!sound
     206                        when wordpos(Ext, 'WPI') > 0                 then ficon = icons.!warpin
     207                        when wordpos(Ext, 'ZIP') > 0                 then ficon = icons.!zip
     208                        when wordpos(Ext, 'INF HLP') > 0             then ficon = icons.!view
     209                        when wordpos(Ext, 'TXT') > 0                 then ficon = icons.!paintext
     210                        otherwise ficon = icons.!defaultfile /* default file icon */
    212211                    end
    213212                    ftype = 'FILE'
    214213                end
    215214                else do
    216                     ficon = '#26:PMWP.DLL' /* dir */
     215                    ficon = icons.!folder
    217216                    ftype = 'DIRECTORY'
    218217                end
     
    224223        end
    225224    end
    226     if I > 0 then ok = VRMethod("CN_SMBTREE","SetRecordAttr",SMBObj.rh, "Icon", "#34:PMWP.DLL") /* open folder */
     225    if I > 0 then ok = VRMethod("CN_SMBTREE","SetRecordAttr",SMBObj.rh, "Icon", icons.!folder_open)
    227226    ok = stream(samba.!msg,'c','close')
    228227    ok = SysFileDelete(samba.!msg)
     
    237236/*:VRX         _BrowseObjectOpen
    238237*/
    239 _BrowseObjectOpen: procedure expose options. cd.
     238_BrowseObjectOpen: procedure expose options. cd. icons.
    240239    machine    = arg(1)
    241240    sharename  = arg(2)
    242241    browsepath = arg(3)
    243242
    244     CALL VRMethod 'CN_CONDET', 'GetRecordList', 'All', 'records.'
     243    CALL VRMethod "CN_CONDET", 'GetRecordList', 'All', 'records.'
    245244
    246245    OpenOk = 0
    247246
    248247    DO i = 1 TO records.0
    249         if VRMethod( 'CN_CONDET', "GetFieldData", records.i, CD.StatusFH) = "#64:PMWP.DLL" then do
    250             IF options.!debug == 1 THEN SAY '  'VRMethod( 'CN_CONDET', "GetFieldData", records.i, CD.StatusFH)' 'VRMethod( 'CN_CONDET', "GetFieldData", records.i, CD.MPointFH)' 'VRMethod( 'CN_CONDET', "GetFieldData", records.i, CD.ServerFH)' 'VRMethod( 'CN_CONDET', "GetFieldData", records.i, CD.ShareFH)
    251             if machine = VRMethod( 'CN_CONDET', "GetFieldData", records.i, CD.ServerFH) &,
    252                sharename = VRMethod( 'CN_CONDET', "GetFieldData", records.i, CD.ShareFH) then do
    253                 Object = strip(VRMethod( 'CN_CONDET', "GetFieldData", records.i, CD.MPointFH),'T','\')'\'browsepath
     248        if VRMethod( "CN_CONDET", "GetFieldData", records.i, CD.StatusFH) = icons.!active then do
     249            IF options.!debug == 1 THEN SAY '  'VRMethod( "CN_CONDET", "GetFieldData", records.i, CD.StatusFH)' 'VRMethod( "CN_CONDET", "GetFieldData", records.i, CD.MPointFH)' 'VRMethod( "CN_CONDET", "GetFieldData", records.i, CD.ServerFH)' 'VRMethod( "CN_CONDET", "GetFieldData", records.i, CD.ShareFH)
     250            if machine = VRMethod( "CN_CONDET", "GetFieldData", records.i, CD.ServerFH) &,
     251               sharename = VRMethod( "CN_CONDET", "GetFieldData", records.i, CD.ShareFH) then do
     252                Object = strip(VRMethod( "CN_CONDET", "GetFieldData", records.i, CD.MPointFH),'T','\')'\'browsepath
    254253                IF options.!debug == 1 THEN SAY '  Non UNC object: "'Object'"'
    255254                ID = VRMethod( "Application", "StartThread", "wps_open", Object, "DEFAULT" )
     
    270269    ok = VRMethod( "CN_SMBTREE", "GetRecordList", "All", "AllRH." )
    271270    do I = 1 to AllRH.0
    272         AllParentRH  = VRMethod("CN_smbtree","GetRecordAttr",AllRH.I,"Parent")
     271        AllParentRH  = VRMethod("CN_SMBTREE","GetRecordAttr",AllRH.I,"Parent")
    273272        if AllParentRH = rh then ok = VRMethod( "CN_SMBTREE", "RemoveRecord", AllRH.I )
    274273    end
     
    345344_DialogPopulate:
    346345
    347     ok = VRMethod( "CN_smbtree", "GetRecordList", "Visible", "rh." )
     346    ok = VRMethod( "CN_SMBTREE", "GetRecordList", "Visible", "rh." )
    348347
    349348    ok = VRMethod("EF_SHARE",   "Reset")
     
    353352    do I = 1 to rh.0
    354353
    355         Userdata = VRMethod("CN_smbtree","GetRecordAttr",rh.I,"Userdata")
    356         ResName  = VRMethod("CN_smbtree","GetRecordAttr",rh.I,"Caption")
     354        Userdata = VRMethod("CN_SMBTREE","GetRecordAttr",rh.I,"Userdata")
     355        ResName  = VRMethod("CN_SMBTREE","GetRecordAttr",rh.I,"Caption")
    357356
    358357        parse var ResName  ResName '0D0A'x .
     
    381380return
    382381
     382/*:VRX         _Dynamic
     383*/
     384_Dynamic:
     385    dyn_code = arg(1)
     386    IF options.!debug == 1 THEN SAY '  Dynamic code: 'dyn_code
     387    interpret dyn_code; drop dyn_code
     388return
     389
    383390/*:VRX         _GetSMBObjectProperties
    384391*/
    385 _GetSMBObjectProperties: procedure expose options. SMBObj. rh icon resname udatatype udatamsg parentrh
     392_GetSMBObjectProperties: procedure expose options. SMBObj. rh icon resname udatatype udatamsg parentrh icons.
    386393    IF options.!debug == 1 THEN SAY time()' _GetSMBObjectProperties started'
    387394
     
    403410    SMBObj.rh = arg(1)
    404411
    405     if VRMethod( 'CN_SMBTREE', "ValidateRecord", SMBObj.rh) <> 1 | SMBObj.rh = "" then do
     412    if VRMethod( "CN_SMBTREE", "ValidateRecord", SMBObj.rh) <> 1 | SMBObj.rh = "" then do
    406413        SMBObj. = ""
    407414        IF options.!debug == 1 THEN SAY time()' _GetSMBObjectProperties aborted'
     
    413420    SMBObj.parentrh = VRMethod("CN_SMBTREE", "GetRecordAttr", SMBObj.rh, "Parent")
    414421
    415     SMBObj.resname  = VRMethod("CN_smbtree", "GetRecordAttr", SMBObj.rh, "Caption")
     422    SMBObj.resname  = VRMethod("CN_SMBTREE", "GetRecordAttr", SMBObj.rh, "Caption")
    416423    parse var SMBObj.resname SMBObj.resname '0D0A'x .
    417424    SMBObj.resname = strip(SMBObj.resname)
    418425
    419     Userdata = VRMethod("CN_smbtree", "GetRecordAttr", SMBObj.rh, "Userdata")
     426    Userdata = VRMethod("CN_SMBTREE", "GetRecordAttr", SMBObj.rh, "Userdata")
    420427    parse var userdata SMBObj.udatatype '|' SMBObj.udatamsg
    421428    SMBObj.udatatype = strip(SMBObj.udatatype)
     
    438445    CALL VRSet 'Main', 'HelpFile', settings.!helpfile
    439446
    440     CALL NLVSetText 'Main',        'Caption', 1
    441     CALL NLVSetText 'DT_CURRENT',  'Caption', 10
    442     CALL NLVSetText 'PB_DETACH',   'Caption', 11
    443     CALL NLVSetText 'PB_UNMOUNT',  'Caption', 12
    444     CALL NLVSetText 'DT_DIALOG',   'Caption', 13
    445     CALL NLVSetText 'DT_MOUNT',    'Caption', 14
    446 
    447     CALL NLVSetText 'DT_SERVER',   'Caption', 19
    448     CALL NLVSetText 'DT_SHARE',    'Caption', 20
    449     CALL NLVSetText 'CHK_MTYPE',   'Caption', 23
    450     CALL NLVSetText 'PB_ADVANCED', 'Caption', 24
    451     CALL NLVSetText 'DT_USER',     'Caption', 25
    452     CALL NLVSetText 'DT_PASSWORD', 'Caption', 26
    453     CALL NLVSetText 'DT_MPOINT',   'Caption', 27
    454     CALL NLVSetText 'PB_MOUNT',    'Caption', 28
    455     CALL NLVSetText 'PB_EDITCANCEL','Caption', 3
    456 
    457     CALL NLVSetText 'PB_AUTOSTART','Caption', 35
    458     CALL NLVSetText 'PB_CLOSE',    'Caption', 29
    459     CALL NLVSetText 'PB_SAVE',     'Caption', 30
    460     CALL NLVSetText 'PB_LOAD',     'Caption', 31
    461     CALL NLVSetText 'PB_HELP',     'Caption', 4
    462 
    463     CALL NLVSetText 'MENU_CONTEXT_DETACH',        'Caption', 11
    464     CALL NLVSetText 'MENU_CONTEXT_DETACH_ALL',    'Caption', 120
    465     CALL NLVSetText 'MENU_CONTEXT_REFRESH',       'Caption', 38
    466     CALL NLVSetText 'MENU_CONTEXT_UNMOUNT',       'Caption', 12
    467     CALL NLVSetText 'MENU_CONTEXT_EDIT',          'Caption', 32
    468     CALL NLVSetText 'MENU_CONTEXT_OPEN',          'Caption', 94
    469     CALL NLVSetText 'MENU_CONTEXT_OPEN_ICON',     'Caption', 95
    470     CALL NLVSetText 'MENU_CONTEXT_OPEN_TREE',     'Caption', 96
    471     CALL NLVSetText 'MENU_CONTEXT_OPEN_DETAIL',   'Caption', 97
    472     CALL NLVSetText 'MENU_CONTEXT_OPEN_SETTINGS', 'Caption', 98
    473     CALL NLVSetText 'MENU_CONTEXT_OPEN_SPLITVIEW','Caption', 99
    474 
    475     CALL NLVSetText 'Menu_File',                  'Caption', 80
    476     CALL NLVSetText 'Menu_Context',               'Caption', 81
    477     CALL NLVSetText 'Menu_View',                  'Caption', 82
    478     CALL NLVSetText 'Menu_Selected',              'Caption', 83
    479     CALL NLVSetText 'Menu_Help',                  'Caption', 84
    480 
    481     CALL NLVSetText 'Menu_View_Dialog',   'Caption', 85
    482     CALL NLVSetText 'Menu_View_SmbTree',  'Caption', 86
    483     CALL NLVSetText 'Menu_View_Buttons',  'Caption', 87
    484     CALL NLVSetText 'Menu_View_ConDet',   'Caption', 88
    485     CALL NLVSetText 'Menu_View_MiniIcons','Caption', 70
    486 
    487     CALL NLVSetText 'Menu_File_Autostart',           'Caption', 35
    488     CALL NLVSetText 'Menu_File_Autostart_Activate',  'Caption', 76
    489     CALL NLVSetText 'Menu_File_Autostart_Deactivate','Caption', 77
    490     CALL NLVSetText 'Menu_File_CLOSE',               'Caption', 29
    491     CALL NLVSetText 'Menu_File_SAVE',                'Caption', 30
    492     CALL NLVSetText 'Menu_File_LOAD',                'Caption', 31
    493     CALL NLVSetText 'Menu_File_SETTINGS',            'Caption', 47
    494     CALL NLVSetText 'Menu_File_ADVANCED',            'Caption', 40
    495 
    496     CALL NLVSetText 'Menu_Selected_Connect', 'Caption', 28
    497     CALL NLVSetText 'Menu_Selected_Remove',  'Caption', 12
    498     CALL NLVSetText 'Menu_Selected_Retry',   'Caption', 90
    499     CALL NLVSetText 'Menu_Selected_Info',    'Caption', 92
    500     CALL NLVSetText 'Menu_Selected_Default_Workgroup','Caption',75
    501 
    502     CALL NLVSetText 'Menu_Help_Extended', 'Caption', 4
    503     CALL NLVSetText 'Menu_Help_About', 'Caption', 91
    504 
    505     CALL NLVSetText 'DT_SMBTREE',          'Caption', 39
    506     CALL NLVSetText 'PB_CONNECT',          'Caption', 28
    507     CALL NLVSetText 'PB_REFRESH',          'Caption', 38
    508 
    509     CALL NLVSetText 'DT_CONDET',          'Caption', 63
    510     CALL NLVSetText 'PB_CONDET_SAVE',     'Caption', 30
    511     CALL NLVSetText 'PB_CONDET_LOAD',     'Caption', 31
     447    CALL NLVSetText 'Main',        "Caption", 1
     448    CALL NLVSetText 'DT_CURRENT',  "Caption", 10
     449    CALL NLVSetText 'PB_DETACH',   "Caption", 11
     450    CALL NLVSetText 'PB_UNMOUNT',  "Caption", 12
     451    CALL NLVSetText 'DT_DIALOG',   "Caption", 13
     452    CALL NLVSetText 'DT_MOUNT',    "Caption", 14
     453
     454    CALL NLVSetText 'DT_SERVER',   "Caption", 19
     455    CALL NLVSetText 'DT_SHARE',    "Caption", 20
     456    CALL NLVSetText 'CHK_MTYPE',   "Caption", 23
     457    CALL NLVSetText 'PB_ADVANCED', "Caption", 24
     458    CALL NLVSetText 'DT_USER',     "Caption", 25
     459    CALL NLVSetText 'DT_PASSWORD', "Caption", 26
     460    CALL NLVSetText 'DT_MPOINT',   "Caption", 27
     461    CALL NLVSetText 'PB_MOUNT',    "Caption", 28
     462    CALL NLVSetText 'PB_EDITCANCEL',"Caption", 3
     463
     464    CALL NLVSetText 'PB_AUTOSTART',"Caption", 35
     465    CALL NLVSetText 'PB_CLOSE',    "Caption", 29
     466    CALL NLVSetText 'PB_SAVE',     "Caption", 30
     467    CALL NLVSetText 'PB_LOAD',     "Caption", 31
     468    CALL NLVSetText 'PB_HELP',     "Caption", 4
     469
     470    CALL NLVSetText 'MENU_CONTEXT_DETACH',        "Caption", 11
     471    CALL NLVSetText 'MENU_CONTEXT_DETACH_ALL',    "Caption", 120
     472    CALL NLVSetText 'MENU_CONTEXT_REFRESH',       "Caption", 38
     473    CALL NLVSetText 'MENU_CONTEXT_UNMOUNT',       "Caption", 12
     474    CALL NLVSetText 'MENU_CONTEXT_EDIT',          "Caption", 32
     475    CALL NLVSetText 'MENU_CONTEXT_OPEN',          "Caption", 94
     476    CALL NLVSetText 'MENU_CONTEXT_OPEN_ICON',     "Caption", 95
     477    CALL NLVSetText 'MENU_CONTEXT_OPEN_TREE',     "Caption", 96
     478    CALL NLVSetText 'MENU_CONTEXT_OPEN_DETAIL',   "Caption", 97
     479    CALL NLVSetText 'MENU_CONTEXT_OPEN_SETTINGS', "Caption", 98
     480    CALL NLVSetText 'MENU_CONTEXT_OPEN_SPLITVIEW',"Caption", 99
     481
     482    CALL NLVSetText 'Menu_File',                  "Caption", 80
     483    CALL NLVSetText 'Menu_Context',               "Caption", 81
     484    CALL NLVSetText 'Menu_View',                  "Caption", 82
     485    CALL NLVSetText 'Menu_Selected',              "Caption", 83
     486    CALL NLVSetText 'Menu_Help',                  "Caption", 84
     487
     488    CALL NLVSetText 'Menu_View_Dialog',   "Caption", 85
     489    CALL NLVSetText 'Menu_View_SmbTree',  "Caption", 86
     490    CALL NLVSetText 'Menu_View_Buttons',  "Caption", 87
     491    CALL NLVSetText 'Menu_View_ConDet',   "Caption", 88
     492    CALL NLVSetText 'Menu_View_MiniIcons',"Caption", 70
     493
     494    CALL NLVSetText 'Menu_File_Autostart',           "Caption", 35
     495    CALL NLVSetText 'Menu_File_Autostart_Activate',  "Caption", 76
     496    CALL NLVSetText 'Menu_File_Autostart_Deactivate',"Caption", 77
     497    CALL NLVSetText 'Menu_File_CLOSE',               "Caption", 29
     498    CALL NLVSetText 'Menu_File_SAVE',                "Caption", 30
     499    CALL NLVSetText 'Menu_File_LOAD',                "Caption", 31
     500    CALL NLVSetText 'Menu_File_SETTINGS',            "Caption", 47
     501    CALL NLVSetText 'Menu_File_ADVANCED',            "Caption", 40
     502
     503    CALL NLVSetText 'Menu_Selected_Connect', "Caption", 28
     504    CALL NLVSetText 'Menu_Selected_Remove',  "Caption", 12
     505    CALL NLVSetText 'Menu_Selected_Retry',   "Caption", 90
     506    CALL NLVSetText 'Menu_Selected_Info',    "Caption", 92
     507    CALL NLVSetText 'Menu_Selected_Default_Workgroup',"Caption",75
     508
     509    CALL NLVSetText 'Menu_Help_Extended', "Caption", 4
     510    CALL NLVSetText 'Menu_Help_About', "Caption", 91
     511
     512    CALL NLVSetText 'DT_SMBTREE',          "Caption", 39
     513    CALL NLVSetText 'PB_CONNECT',          "Caption", 28
     514    CALL NLVSetText 'PB_REFRESH',          "Caption", 38
     515
     516    CALL NLVSetText 'DT_CONDET',          "Caption", 63
     517    CALL NLVSetText 'PB_CONDET_SAVE',     "Caption", 30
     518    CALL NLVSetText 'PB_CONDET_LOAD',     "Caption", 31
    512519
    513520
     
    584591        ok = VRMethod("CN_CONDET", "SetFieldData", cd.masterfh, p_master, cd.mtypefh, p_mtype, cd.lastrh, cd.easupportfh, p_easupport, cd.rwfh, p_rw)
    585592/*      ok = VRMethod("CN_CONDET", "SetFieldData", cd.lastrh, cd.memlenfh, p_memlen, cd.logfilefh, p_logfile, cd.loglevelfh, p_loglevel ) */
    586         ok = VRMethod("CN_CONDET", "SetFieldData", cd.lastrh, cd.statusfh, '#68:PMWP.DLL') /* Passive */
    587         ok = VRMethod("CN_CONDET", "SetRecordAttr", cd.lastrh, "Icon", '#68:PMWP.DLL') /* Active */
     593        ok = VRMethod("CN_CONDET", "SetFieldData", cd.lastrh, cd.statusfh, icons.!passive) /* Passive */
     594        ok = VRMethod("CN_CONDET", "SetRecordAttr", cd.lastrh, "Icon", icons.!passive) /* Active */
    588595
    589596        hashstr = p_mpoint' 'translate(p_domain)' 'translate(p_server)' 'translate(p_share)' 'p_user' 'p_spassword' 'p_easupport' 'p_rw
     
    604611    ok = SysIni(settings.!ini, 'PassiveConnections', 'DELETE:')
    605612
    606     CALL VRMethod 'CN_CONDET', 'GetRecordList', 'All', 'records.'
     613    CALL VRMethod "CN_CONDET", 'GetRecordList', 'All', 'records.'
    607614    cnt = 0
    608615    DO i = 1 TO records.0
    609616
    610         if VRMethod( 'CN_CONDET', "GetFieldData", records.i, CD.StatusFH) = '#68:PMWP.DLL' then do
     617        if VRMethod( "CN_CONDET", "GetFieldData", records.i, CD.StatusFH) = icons.!passive then do
    611618            cnt = cnt + 1
    612619            resdata = ""
     
    724731    end
    725732
    726     CALL VRSet 'CB_LOGGING', 'Set', VRFileExists(SysBootDrive()'\ndpsmb.dbg')
     733    CALL VRSet "CB_LOGGING", "Set", VRFileExists(SysBootDrive()'\ndpsmb.dbg')
    727734return
    728735
     
    742749            CALL VRSet "CHK_MTYPE",  "Visible", 0
    743750            CALL NLVSetText "DT_NETWORK", "Caption", 21
    744             /* Does not make sense anymore
    745             if options.!editmode = 0 Then CALL VRSet "EF_NETWORK",  "Value", settings.!network
    746              */
     751            /* Does not make sense anymore */
     752            /* if options.!editmode = 0 Then CALL VRSet "EF_NETWORK","Value", settings.!network */
    747753        END
    748754        WHEN mount == 2 THEN DO
     
    753759            CALL VRSet "CHK_MTYPE",  "Visible", 0
    754760            CALL NLVSetText "DT_NETWORK", "Caption", 21
    755             /* Does not make sense anymore
    756             CALL VRSet "EF_NETWORK",  "Value", settings.!network
    757              */
     761            /* Does not make sense anymore  */
     762            /* CALL VRSet "EF_NETWORK","Value", settings.!network */
    758763        END
    759764        WHEN mount == 3 THEN DO
     
    764769            CALL VRSet "CHK_MTYPE",  "Visible", 0
    765770            CALL NLVSetText "DT_NETWORK", "Caption", 21
    766             /* Does not make sense anymore
    767             CALL VRSet "EF_NETWORK",  "Value", settings.!network
    768              */
     771            /* Does not make sense anymore */
     772            /* CALL VRSet "EF_NETWORK","Value", settings.!network */
    769773        END
    770774        WHEN mount == 4 THEN DO
     
    775779            CALL VRSet "CHK_MTYPE",  "Visible", 1
    776780            CALL NLVSetText "DT_NETWORK", "Caption", 22
    777             /* Does not make sense anymore
    778             CALL VRSet "EF_NETWORK",  "Value", ""
    779              */
     781            /* Does not make sense anymore */
     782            /* CALL VRSet "EF_NETWORK","Value", "" */
    780783        END
    781784    END
    782785    IF options.!debug == 1 THEN SAY time()' '||"CB_MOUNT_Change done"
    783 
    784786RETURN
    785787
     
    794796CN_CONDET_ContextMenu:
    795797    rh = VRInfo('Record')
    796     if VRMethod( 'CN_CONDET', "ValidateRecord", rh) <> 1 then return
     798    if VRMethod( "CN_CONDET", "ValidateRecord", rh) <> 1 then return
    797799
    798800    /* This is the place to enable specific context menu entries */
     
    801803    ok = VRSet("Menu_Selected_Retry",  "Visible",  (records.0 <> 0))
    802804
    803     if VRMethod( 'CN_CONDET', "GetFieldData", rh, CD.StatusFH) = '#68:PMWP.DLL' then do
     805    if VRMethod( "CN_CONDET", "GetFieldData", rh, CD.StatusFH) = icons.!passive then do
    804806        ok = VRSet("Menu_Selected_Retry",  "Enabled",1)
    805807        ok = VRSet("Menu_Selected_Remove", "Enabled",1)
     
    817819    Icon = VRMethod("CN_CONDET", "GetRecordAttr", selrec.1, "Icon")
    818820
    819     if Icon = "#65:PMWP.DLL" then do /* Printers not supported at the moment */
     821    if Icon = icons.!printer then do /* Printers not supported at the moment */
    820822        CALL VRMessage 'Main', NLVGetMessage( 62 ), NLVGetMessage( 5 ), 'E'
    821823    end
     
    833835
    834836    rh = VRInfo('Record')
    835     if VRMethod( 'CN_CURRENT', "ValidateRecord", rh) <> 1 then return
    836 
    837     data = VRMethod('CN_CURRENT', 'GetRecordAttr', rh, 'UserData')
     837    if VRMethod( "CN_CURRENT", "ValidateRecord", rh) <> 1 then return
     838
     839    data = VRMethod("CN_CURRENT", 'GetRecordAttr', rh, 'UserData')
    838840    options.currentdata = data
    839841
     
    862864    CALL VRSet 'Main', 'StatusText', infotext */
    863865    if infotext = "" then infotext = " "
    864     CALL VRSet 'CN_CURRENT', 'Caption', infotext
    865     CALL VRSet 'CN_CURRENT', 'HintText',infotext
     866    CALL VRSet "CN_CURRENT", "Caption", infotext
     867    CALL VRSet "CN_CURRENT", 'HintText',infotext
    866868/* Herwig B. */
    867869
     
    879881    END
    880882
    881     parent = VRMethod('CN_CURRENT', 'GetRecordAttr', rh, 'Parent')
     883    parent = VRMethod("CN_CURRENT", 'GetRecordAttr', rh, 'Parent')
    882884
    883885    IF parent == '' THEN DO
     
    908910/*:VRX         CN_CURRENT_ContextMenu
    909911*/
    910 CN_CURRENT_ContextMenu: /* PROCEDURE EXPOSE existrec. options. fs. */
     912CN_CURRENT_ContextMenu: /* PROCEDURE EXPOSE existrec. options. icons. fs. */
    911913    IF options.!debug == 1 THEN SAY time()' '||"CN_CURRENT_ContextMenu started"
    912914
     
    918920       circumstances the event routine is executed after the record was already
    919921       removed */
    920     if VRMethod( 'CN_CURRENT', "ValidateRecord", rh) <> 1 then do
     922    if VRMethod( "CN_CURRENT", "ValidateRecord", rh) <> 1 then do
    921923        IF options.!debug == 1 THEN SAY time()' '||"CN_CURRENT_ContextMenu aborted"
    922924        return
    923925    end
    924926
    925     data = VRMethod('CN_CURRENT', 'GetRecordAttr', rh, 'UserData')
     927    data = VRMethod("CN_CURRENT", 'GetRecordAttr', rh, 'UserData')
    926928    PARSE VAR data p_node ';' p_mounts ';' p_string
    927929
     
    946948    CALL VRSet 'Main', 'StatusText', infotext */
    947949    if infotext = "" then infotext = " "
    948     CALL VRSet 'CN_CURRENT', 'Caption', infotext
    949     CALL VRSet 'CN_CURRENT', 'HintText',infotext
     950    CALL VRSet "CN_CURRENT", "Caption", infotext
     951    CALL VRSet "CN_CURRENT", 'HintText',infotext
    950952/* Herwig B. */
    951953
     
    969971    END
    970972
    971     parent = VRMethod('CN_CURRENT', 'GetRecordAttr', rh, 'Parent')
     973    parent = VRMethod("CN_CURRENT", 'GetRecordAttr', rh, 'Parent')
    972974
    973975    IF parent == '' THEN DO
     
    10061008       circumstances the event routine is executed after the record was already
    10071009       removed */
    1008     if VRMethod( 'CN_CURRENT', "ValidateRecord", rh) <> 1 then do
     1010    if VRMethod( "CN_CURRENT", "ValidateRecord", rh) <> 1 then do
    10091011        IF options.!debug == 1 THEN SAY time()' '||"CN_CURRENT_DoubleClick aborted"
    10101012        return
    10111013    end
    10121014
    1013     data = VRMethod('CN_CURRENT', 'GetRecordAttr', rh, 'UserData')
     1015    data = VRMethod("CN_CURRENT", 'GetRecordAttr', rh, 'UserData')
    10141016    PARSE VAR data p_node ';' p_mounts ';' p_string
    10151017
     
    10601062            Profile = srcFile
    10611063            call PB_LOAD_Click
     1064            ok = VRSet("EF_NETWORK","Value",options.!workgroup)
    10621065        end
    10631066        else do /* No - barf! */
     
    11931196    call PB_MOUNT_CLICK
    11941197
    1195     if VRGet(srcCtn,'Name') = "CN_CONDET" & VRMethod( 'CN_CONDET', "ValidateRecord", srcRec) = 1 then do
    1196         if VRMethod("CN_CONDET", "GetRecordAttr", srcRec, "Icon") = '#68:PMWP.DLL' then ok = VRMethod( "CN_CONDET", "RemoveRecord", srcRec)
     1198    if VRGet(srcCtn,'Name') = "CN_CONDET" & VRMethod( "CN_CONDET", "ValidateRecord", srcRec) = 1 then do
     1199        if VRMethod("CN_CONDET", "GetRecordAttr", srcRec, "Icon") = icons.!passive then ok = VRMethod( "CN_CONDET", "RemoveRecord", srcRec)
    11971200    end
    11981201    IF options.!debug == 1 THEN SAY time()' CN_CURRENT_DragDrop done'
     
    13011304
    13021305    if SMBObj.udatatype = "DISK" then do
    1303         machine  = VRMethod("CN_smbtree","GetRecordAttr",SMBObj.parentrh,"Caption")
     1306        machine  = VRMethod("CN_SMBTREE","GetRecordAttr",SMBObj.parentrh,"Caption")
    13041307        parse var machine machine '0D0A'x .
    13051308        machine = strip(machine)
     
    13921395    if strip(translate(VRGet("EF_SERVER","value"),copies(' ',11),'01234567890.')) = "" & length(VRGet("EF_SERVER","value")) < 7 then return
    13931396
    1394     ok = VRMethod( "CN_smbtree", "GetRecordList", "Visible", "rh." )
     1397    ok = VRMethod( "CN_SMBTREE", "GetRecordList", "Visible", "rh." )
    13951398
    13961399    FoundServer = 0
     
    13981401    do I = 1 to rh.0
    13991402
    1400         Userdata = VRMethod("CN_smbtree","GetRecordAttr",rh.I,"Userdata")
    1401         ResName  = VRMethod("CN_smbtree","GetRecordAttr",rh.I,"Caption")
    1402         ParentRH = VRMethod("CN_smbtree","GetRecordAttr",rh.I,"Parent")
     1403        Userdata = VRMethod("CN_SMBTREE","GetRecordAttr",rh.I,"Userdata")
     1404        ResName  = VRMethod("CN_SMBTREE","GetRecordAttr",rh.I,"Caption")
     1405        ParentRH = VRMethod("CN_SMBTREE","GetRecordAttr",rh.I,"Parent")
    14031406
    14041407        parse var ResName  ResName '0D0A'x .
     
    14091412            /* Workgroup properly */
    14101413            if ParentRH = "" then do
    1411                 ok = VRSet("EF_NETWORK", "Value", "") /* The workgroup might be unknown at this moment */
     1414                ok = VRSet("EF_NETWORK","Value", "") /* The workgroup might be unknown at this moment */
    14121415            end
    14131416            else do
    1414                 ok = VRSet("EF_NETWORK", "Value", VRMethod("CN_smbtree","GetRecordAttr",ParentRH,"Caption"))
     1417                ok = VRSet("EF_NETWORK","Value", VRMethod("CN_SMBTREE","GetRecordAttr",ParentRH,"Caption"))
    14151418            end
    14161419
     
    14211424            do J = 1 to rh.0 /* populate shares with valid entries */
    14221425
    1423                 Userdata = VRMethod("CN_smbtree","GetRecordAttr",rh.J,"Userdata")
    1424                 ResName  = VRMethod("CN_smbtree","GetRecordAttr",rh.J,"Caption")
    1425                 ParentRH = VRMethod("CN_smbtree","GetRecordAttr",rh.J,"Parent")
     1426                Userdata = VRMethod("CN_SMBTREE","GetRecordAttr",rh.J,"Userdata")
     1427                ResName  = VRMethod("CN_SMBTREE","GetRecordAttr",rh.J,"Caption")
     1428                ParentRH = VRMethod("CN_SMBTREE","GetRecordAttr",rh.J,"Parent")
    14261429
    14271430                parse var ResName  ResName '0D0A'x .
     
    14391442    if Foundserver = 0 then do
    14401443        machine = VRGet("EF_SERVER","value")
    1441         smbtree.!machine = VRMethod( "CN_smbtree", "AddRecord",,, machine)
     1444        smbtree.!machine = VRMethod( "CN_SMBTREE", "AddRecord",,, machine)
    14421445        /* We make any machine as sleeping initially */
    1443         ok = VRMethod( "CN_smbtree", "SetRecordAttr", smbtree.!machine, "Icon","#61:PMWP.DLL")
    1444         ok = VRMethod( "CN_smbtree", "SetRecordAttr", smbtree.!machine, "ReadOnly", 1)
    1445         ok = VRMethod( "CN_smbtree", "SetFieldData",  smbtree.!machine, NBFH, machine)
     1446        ok = VRMethod( "CN_SMBTREE", "SetRecordAttr", smbtree.!machine, "Icon",icons.!machine_sleeping)
     1447        ok = VRMethod( "CN_SMBTREE", "SetRecordAttr", smbtree.!machine, "ReadOnly", 1)
     1448        ok = VRMethod( "CN_SMBTREE", "SetFieldData",  smbtree.!machine, NBFH, machine)
    14461449        call _UserCredUpdate
    14471450        call _RefreshShares
     
    14791482/*:VRX         GetChildren
    14801483*/
    1481 GetChildren: PROCEDURE EXPOSE existrec. exc options. fs. cd. samba.
     1484GetChildren: PROCEDURE EXPOSE existrec. exc options. icons. fs. cd. samba.
    14821485    IF options.!debug == 1 THEN SAY time()' GetChildren started'
    14831486    PARSE ARG node, parec
    14841487
    1485     dyn = "CALL "fs.!prefix"RxGetMount node, 'info.', 'points.', 'res.'"
    1486     IF options.!debug == 1 THEN SAY '  Dyn code: 'dyn
    1487     interpret dyn; drop dyn
    1488 
    1489 
    1490     IF info.2 > 0 THEN icon = '#64:PMWP.DLL'
    1491     ELSE               icon = '#68:PMWP.DLL'
    1492     rh = VRMethod('CN_CURRENT', 'AddRecord', parec, 'Last', info.0, icon )
     1488    CALL _Dynamic "CALL "fs.!prefix"RxGetMount node, 'info.', 'points.', 'res.'"
     1489
     1490    IF info.2 > 0 THEN icon = icons.!active
     1491                  ELSE icon = icons.!passive
     1492                 
     1493    rh = VRMethod("CN_CURRENT", 'AddRecord', parec, 'Last', info.0, icon )
    14931494    IF rh == '' | datatype(res.0) <> "NUM" THEN RETURN
    14941495
     
    14991500        userdata = ParseResourceData( userdata, res.i )
    15001501    END
    1501     if userdata = "UNKNOWN" then ok = VRMethod('CN_CURRENT', 'RemoveRecord', rh)
     1502    if userdata = "UNKNOWN" then ok = VRMethod("CN_CURRENT", 'RemoveRecord', rh)
    15021503    else do
    1503         CALL VRMethod 'CN_CURRENT', 'SetRecordAttr', rh, 'UserData', userdata
    1504         if options.currentdata = userdata then ok = VRMethod('CN_CURRENT', 'SetRecordAttr', rh, 'Selected', 1)
     1504        CALL VRMethod "CN_CURRENT", 'SetRecordAttr', rh, 'UserData', userdata
     1505        if options.currentdata = userdata then ok = VRMethod("CN_CURRENT", 'SetRecordAttr', rh, 'Selected', 1)
    15051506    end
    15061507
     
    15141515/*:VRX         GetMountPoints
    15151516*/
    1516 GetMountPoints: PROCEDURE EXPOSE existrec. options. fs. cd. samba.
     1517GetMountPoints: PROCEDURE EXPOSE existrec. options. icons. fs. cd. samba.
    15171518    IF options.!debug == 1 THEN SAY time()' GetMountPoints started'
    1518 /*  CALL VRSet 'CN_CURRENT', 'Painting', 0 */
     1519/*  CALL VRSet "CN_CURRENT", 'Painting', 0 */
    15191520/*  IF options.!debug == 1 THEN SAY time()' '||"GetMountPoints: SysDriveMap(USED) started"  */
    15201521    drvs = SysDriveMap('C:', 'USED') /* was "REMOTE" */
     
    15361537        CALL VRMethod 'CB_DRIVES',  'AddString', attached.i
    15371538
    1538         dyn = "CALL "fs.!prefix"RxGetMount node, 'info.', 'points.', 'res.'"
    1539         IF options.!debug == 1 THEN SAY '  Dyn code: 'dyn
    1540         interpret dyn; drop dyn
    1541 
    1542         IF info.2 > 0 THEN icon = '#16:PMWP.DLL'
    1543         ELSE               icon = '#70:PMWP.DLL'
    1544 
    1545         rh = VRMethod('CN_CURRENT', 'AddRecord',, 'Last', attached.i, icon )
     1539        CALL _Dynamic "CALL "fs.!prefix"RxGetMount node, 'info.', 'points.', 'res.'"
     1540
     1541        IF info.2 > 0 THEN icon = icons.!drive
     1542                      ELSE icon = icons.!drive_inactive
     1543
     1544        rh = VRMethod("CN_CURRENT", 'AddRecord',, 'Last', attached.i, icon )
    15461545        IF rh == '' THEN ITERATE
    15471546
     
    15531552        END
    15541553/*      IF options.!debug == 1 THEN say '  "'attached.i'" "'userdata'"' */
    1555         CALL VRMethod 'CN_CURRENT', 'SetRecordAttr', rh, 'UserData', userdata
    1556         if options.currentdata = userdata then ok = VRMethod('CN_CURRENT', 'SetRecordAttr', rh, 'Selected', 1)
    1557 
    1558         CALL VRMethod 'CN_CURRENT', 'SetRecordAttr', rh, 'Expanded', 1
     1554        CALL VRMethod "CN_CURRENT", 'SetRecordAttr', rh, 'UserData', userdata
     1555        if options.currentdata = userdata then ok = VRMethod("CN_CURRENT", 'SetRecordAttr', rh, 'Selected', 1)
     1556
     1557        CALL VRMethod "CN_CURRENT", 'SetRecordAttr', rh, 'Expanded', 1
    15591558
    15601559        DO j = 1 TO points.0
     
    15651564    END
    15661565    existrec.0 = exc
    1567 /*  CALL VRSet 'CN_CURRENT', 'Painting', 1 */
     1566/*  CALL VRSet "CN_CURRENT", 'Painting', 1 */
    15681567    IF options.!debug == 1 THEN SAY time()' '||"GetMountPoints done"
    15691568RETURN
     
    16281627CommonToBothFS:
    16291628    IF options.!debug == 1 THEN SAY '  Common version check'
    1630     dyn = "fsstat = "fs.!prefix"RxQueryIFS()"
    1631     IF options.!debug == 1 THEN SAY '  Dyn code:        '||dyn
    1632     interpret dyn; drop dyn
    1633     IF options.!debug == 1 THEN SAY '  Dyn res fsstat = '||fsstat
    1634     if fsstat = 252 then do
    1635         dyn = "Found"fs.!prefix" = 0"
    1636         interpret dyn
    1637     end
     1629    CALL _Dynamic "fsstat = "fs.!prefix"RxQueryIFS()"
     1630    if fsstat = 252 then CALL _Dynamic "Found"fs.!prefix" = 0"
     1631
    16381632    if word(fsstat,1) = '0' then do
    16391633        PARSE VAR fsstat '0 'fsname fsver fsctl .
     
    16741668/*:VRX         LoadSettings
    16751669*/
    1676 LoadSettings: PROCEDURE EXPOSE settings. options. fs. advanced. samba. ShowHidden margin
     1670LoadSettings: PROCEDURE EXPOSE settings. options. icons. fs. advanced. samba. ShowHidden margin
    16771671    IF options.!debug == 1 THEN SAY time()' LoadSettings started'
    16781672
     
    17691763        IF advanced.!browseimme == '' THEN advanced.!browseimme = 1
    17701764
    1771         advanced.!debug = VRGetIni('Settings', 'Debug', settings.!ini)
    1772         IF advanced.!debug == '' THEN advanced.!debug = 0       /* Turn off debug by default for release builds */
     1765        options.!debug = VRGetIni('Settings', 'Debug', settings.!ini)
     1766        IF options.!debug == '' THEN options.!debug = 0       /* Turn off debug by default for release builds */
    17731767
    17741768        /* This is a hack and should be reworked! - using several variables for debug is bad! */
    1775         options.!debug = advanced.!debug
     1769        options.!debug = options.!debug
    17761770        IF options.!debug <> 1 THEN ok = VRRedirectStdIO("OFF")
    17771771
     
    18321826        end
    18331827
    1834         if advanced.!debug == 1 then ok = VRRedirectStdio("ON")
     1828        if options.!debug == 1 then ok = VRRedirectStdio("ON")
    18351829
    18361830        IF ( settings.!x >= 0 ) & ( settings.!y >= 0 ) & ( settings.!l >= 0 ) & ( settings.!w >= 0 ) & ( settings.!s >= 0 ) THEN DO
     
    18441838            CALL VRMethod VRWindow(), 'CenterWindow'
    18451839
    1846         CALL VRSet 'CN_CURRENT', 'Font',       settings.!cfont
     1840        CALL VRSet "CN_CURRENT", 'Font',       settings.!cfont
    18471841        CALL VRSet 'Main',       'Font',       settings.!wfont
    18481842        CALL VRSet 'Main',       'StatusFont', settings.!wfont
     
    21932187Menu_Context_Open_Default_Click:
    21942188    IF options.!debug == 1 THEN SAY time()' '||"Menu_Context_Open_Click started"
    2195     userdata = VRMethod( 'CN_CURRENT', 'GetRecordAttr', rh, 'UserData')
     2189    userdata = VRMethod( "CN_CURRENT", 'GetRecordAttr', rh, 'UserData')
    21962190    PARSE VAR userdata mountpoint ';' mounts ';' .
    21972191
     
    22072201Menu_Context_Open_Detail_Click:
    22082202    IF options.!debug == 1 THEN SAY time()' '||"Menu_Context_Open_Details_Click started"
    2209     userdata = VRMethod( 'CN_CURRENT', 'GetRecordAttr', rh, 'UserData')
     2203    userdata = VRMethod( "CN_CURRENT", 'GetRecordAttr', rh, 'UserData')
    22102204    PARSE VAR userdata mountpoint ';' mounts ';' .
    22112205
     
    22212215Menu_Context_Open_Icon_Click:
    22222216    IF options.!debug == 1 THEN SAY time()' '||"Menu_Context_Open_Icon_Click started"
    2223     userdata = VRMethod( 'CN_CURRENT', 'GetRecordAttr', rh, 'UserData')
     2217    userdata = VRMethod( "CN_CURRENT", 'GetRecordAttr', rh, 'UserData')
    22242218    PARSE VAR userdata mountpoint ';' mounts ';' .
    22252219
     
    22352229Menu_Context_Open_Settings_Click:
    22362230    IF options.!debug == 1 THEN SAY time()' '||"Menu_Context_Open_DetailsClick started"
    2237     userdata = VRMethod( 'CN_CURRENT', 'GetRecordAttr', rh, 'UserData')
     2231    userdata = VRMethod( "CN_CURRENT", 'GetRecordAttr', rh, 'UserData')
    22382232    PARSE VAR userdata mountpoint ';' mounts ';' .
    22392233
     
    22492243Menu_Context_Open_Splitview_Click:
    22502244    IF options.!debug == 1 THEN SAY time()' '||"Menu_Context_Open_Splitview_Click started"
    2251     userdata = VRMethod( 'CN_CURRENT', 'GetRecordAttr', rh, 'UserData')
     2245    userdata = VRMethod( "CN_CURRENT", 'GetRecordAttr', rh, 'UserData')
    22522246    PARSE VAR userdata mountpoint ';' mounts ';' .
    22532247
     
    22632257Menu_Context_Open_Tree_Click:
    22642258    IF options.!debug == 1 THEN SAY time()' '||"Menu_Context_Open_Tree_Click started"
    2265     userdata = VRMethod( 'CN_CURRENT', 'GetRecordAttr', rh, 'UserData')
     2259    userdata = VRMethod( "CN_CURRENT", 'GetRecordAttr', rh, 'UserData')
    22662260    PARSE VAR userdata mountpoint ';' mounts ';' .
    22672261
     
    22882282*/
    22892283Menu_File_Advanced_Click:
    2290     call PB_ADVANCED_Click
     2284    CALL VRLoadSecondary "SW_ADVANCED", "W"
    22912285return
    22922286
     
    23422336*/
    23432337Menu_File_Settings_Click:
    2344     adv_changed = 0
    23452338    CALL VRLoadSecondary "SW_SETTINGS", "W"
    2346     IF adv_changed == 1 THEN DO
    2347         advanced.!logfile   = adv_logfile
    2348         advanced.!loglevel  = adv_loglevel
    2349         advanced.!browseauth= adv_browseauth
    2350         advanced.!browseimme= adv_browseimme
    2351         advanced.!debug     = adv_debug
    2352         advanced.!special   = adv_special
    2353         advanced.!savepassive=adv_savepassive
    2354         advanced.!broadcast  =adv_broadcast
    2355     END
    23562339return
    23572340
     
    23772360*/
    23782361Menu_Selected_Default_Workgroup_Click:
    2379     workgroupname = VRMethod("CN_smbtree","GetRecordAttr",SMBObj.rh,"Caption")
     2362    workgroupname = VRMethod("CN_SMBTREE","GetRecordAttr",SMBObj.rh,"Caption")
    23802363    ok = TRSetIni("[global]","workgroup", workgroupname, samba.!smbconf)
    23812364return
     
    23862369    IF options.!debug == 1 THEN SAY time()' Menu_Selected_Info_Click started'
    23872370
    2388     ok = VRMethod( "CN_smbtree", "GetRecordList", "SourceOrSelected", "SelRH." )
     2371    ok = VRMethod( "CN_SMBTREE", "GetRecordList", "SourceOrSelected", "SelRH." )
    23892372    if SelRH.0 = 0 then do
    23902373        IF options.!debug == 1 THEN SAY time()' Menu_Selected_Info_Click aborted'
     
    24172400
    24182401    do I = 1 to selrec.0
    2419         if VRMethod("CN_CONDET", "GetFieldData", selrec.I, cd.statusfh) = '#68:PMWP.DLL' then do
    2420             CALL VRMethod 'CN_CONDET', 'RemoveRecord', selrec.I
     2402        if VRMethod("CN_CONDET", "GetFieldData", selrec.I, cd.statusfh) = icons.!passive then do
     2403            CALL VRMethod "CN_CONDET", 'RemoveRecord', selrec.I
    24212404        end
    24222405        else do
    2423             mountpoint = VRMethod('CN_CONDET', "GetFieldData", selrec.I, cd.mpointfh)
    2424             mpidx = VRMethod('CN_CONDET', "GetFieldData", selrec.I, cd.mpidxfh)
     2406            mountpoint = VRMethod("CN_CONDET", "GetFieldData", selrec.I, cd.mpointfh)
     2407            mpidx = VRMethod("CN_CONDET", "GetFieldData", selrec.I, cd.mpidxfh)
    24252408            if mpidx = 1 then do
    24262409                btns.0 = 2
     
    24302413                IF confirm \= 1 THEN RETURN
    24312414
    2432                 dyn ="ok = "fs.!prefix"RxUnmount( mountpoint, mpidx )"
    2433                 IF options.!debug == 1 THEN SAY time()' '||dyn
    2434                 interpret dyn; drop dyn
    2435                 CALL VRMethod 'CN_CONDET', 'RemoveRecord', selrec.I
     2415                CALL _Dynamic "ok = "fs.!prefix"RxUnmount( mountpoint, mpidx )"
     2416                CALL VRMethod "CN_CONDET", 'RemoveRecord', selrec.I
    24362417                CALL Refresh
    24372418            end
     
    24452426/*:VRX         Menu_Selected_Retry_Click
    24462427*/
    2447 Menu_Selected_Retry_Click: PROCEDURE EXPOSE settings. options. vfs. fs. advanced. cd. samba.
     2428Menu_Selected_Retry_Click: PROCEDURE EXPOSE settings. options. icons. vfs. fs. advanced. cd. samba.
    24482429
    24492430    ok = VRMethod( "CN_CONDET", "GetRecordList", "SourceOrSelected", "srcrec." )
     
    24832464    CALL PB_MOUNT_Click
    24842465
    2485     if VRMethod( 'CN_CONDET', "ValidateRecord", srcRec) = 1 then do
    2486         if VRMethod("CN_CONDET", "GetRecordAttr", srcRec, "Icon") = '#68:PMWP.DLL' then ok = VRMethod( "CN_CONDET", "RemoveRecord", srcRec)
     2466    if VRMethod( "CN_CONDET", "ValidateRecord", srcRec) = 1 then do
     2467        if VRMethod("CN_CONDET", "GetRecordAttr", srcRec, "Icon") = icons.!passive then ok = VRMethod( "CN_CONDET", "RemoveRecord", srcRec)
    24872468    end
    24882469return
     
    25882569/*:VRX         Mount
    25892570*/
    2590 Mount: PROCEDURE EXPOSE settings. options. vfs. fs. advanced. cd. samba.
     2571Mount: PROCEDURE EXPOSE settings. options. icons. vfs. fs. advanced. cd. samba.
    25912572    IF options.!debug == 1 THEN SAY time()' Mount procedure started'
    25922573    /* Set mouse pointer to wait - this operation might take a few seconds */
    25932574    call VRSet VRWindow(), 'Pointer', 'Wait'
    25942575
    2595 /*  Disabled because we merge profile now - in earlier revisions
     2576/*  Disabled, because we merge profile now - in earlier revisions
    25962577    we replaced it but only for preexisting drives - this made only
    2597     as long as we were unabled to detect double connections - this could be made an option!
     2578    sense as long as we were unable to detect double connections -
     2579    this could be made an option!
     2580   
    25982581    IF options.!autoload then do
    2599         dyn = "ok = "fs.!prefix"RxDetach(vfs.!drive)"
    2600         IF options.!debug == 1 THEN SAY time()' '||dyn
    2601             interpret dyn; drop dyn
    2602 
     2582        CALL _Dynamic "ok = "fs.!prefix"RxDetach(vfs.!drive)"
    26032583        IF options.!debug == 1 THEN SAY time()' '||'Autoload Detach "'vfs.!drive'" =' ok
    26042584    end */
     
    26062586    /* Attach the virtual drive - only if drive is not already attached */
    26072587    if pos(vfs.!drive,MyFreeDriveMap("C:","FREE")) > 0 then do
    2608         dyn = "ok = "fs.!prefix"RxAttach( vfs.!drive )"
    2609         IF options.!debug == 1 THEN SAY time()' '||dyn
    2610 
    2611         interpret dyn; drop dyn
     2588        CALL _Dynamic "ok = "fs.!prefix"RxAttach( vfs.!drive )"
    26122589
    26132590        IF options.!debug == 1 THEN SAY time()' '||'Attach "'vfs.!drive'" =' ok
     
    26152592
    26162593    /* Create the mount point and store whether it was created or already existed */
    2617     dyn = "CreateMP = "fs.!prefix"RxCreateMountPoint( vfs.!mountpoint )"
    2618     IF options.!debug == 1 THEN SAY time()' '||dyn
    2619     interpret dyn; drop dyn
     2594    CALL _Dynamic "CreateMP = "fs.!prefix"RxCreateMountPoint( vfs.!mountpoint )"
    26202595
    26212596    IF options.!debug == 1 THEN SAY time()' '||'Create "'vfs.!mountpoint'" = 'CreateMP
     
    26562631    md5 = rexx_md5(hashstr)
    26572632
    2658     CALL VRMethod 'CN_CONDET', 'GetRecordList', 'All', 'records.'
     2633    CALL VRMethod "CN_CONDET", 'GetRecordList', 'All', 'records.'
    26592634    DO i = 1 TO records.0
    26602635        hash = VRMethod("CN_CONDET","GetFieldData", records.i, cd.hashfh)
     
    26642639
    26652640        if hash = md5 then do
    2666             If VRMethod("CN_CONDET","GetFieldData", records.i, cd.statusfh) = '#64:PMWP.DLL' then do /* Same hash, status active */
     2641            If VRMethod("CN_CONDET","GetFieldData", records.i, cd.statusfh) = icons.!active then do /* Same hash, status active */
    26672642                say "Double connection detected!!"
    26682643                if options.!spassword <> "" then upw = ":********"
     
    26882663
    26892664    /* Now mount the resource */
    2690     dyn ="ok = "fs.!prefix"RxMount('smbfs', vfs.!mountpoint, src, rwFlag)"
    2691     IF options.!debug == 1 THEN SAY time()' '||dyn
    2692     interpret dyn; drop dyn
     2665    CALL _Dynamic "ok = "fs.!prefix"RxMount('smbfs', vfs.!mountpoint, src, rwFlag)"
    26932666
    26942667    IF options.!debug == 1 THEN SAY time()' '||'Mount "'vfs.!mountpoint'" =' ok
     
    27042677        end
    27052678        if cd.lastrh <> '' then do
    2706             ok = VRMethod("CN_CONDET", "SetFieldData",  cd.lastrh, cd.statusfh, '#68:PMWP.DLL') /* Passive Connection icon */
    2707             ok = VRMethod("CN_CONDET", "SetRecordAttr", cd.lastrh, "Icon", '#68:PMWP.DLL') /* Passive Connection icon */
     2679            ok = VRMethod("CN_CONDET", "SetFieldData",  cd.lastrh, cd.statusfh, icons.!passive) /* Passive Connection icon */
     2680            ok = VRMethod("CN_CONDET", "SetRecordAttr", cd.lastrh, "Icon", icons.!passive) /* Passive Connection icon */
    27082681            ok = VRMethod("CN_CONDET", "SetFieldData",  cd.lastrh, cd.passwordfh, '') /* remove pain text password */
    27092682        end
     
    27112684        /* In case the mountpoint was created for this failed operation, it is (optionally) removed again */
    27122685        if CreateMP = 0 & advanced.!alwaysmp <> 1 then do
    2713             dyn ="ok = "fs.!prefix"RxDeleteMountPoint( vfs.!mountpoint )"
    2714             interpret dyn
     2686            CALL _Dynamic "ok = "fs.!prefix"RxDeleteMountPoint( vfs.!mountpoint )"
    27152687            IF options.!debug == 1 THEN SAY time()' '||'Remove "'vfs.!mountpoint'" = 'ok
    27162688        end
     
    27302702/*:VRX         MyFreeDriveMap
    27312703*/
    2732 MyFreeDriveMap: procedure expose options. fs. samba.
     2704MyFreeDriveMap: procedure expose options. icons. fs. samba.
    27332705    IF options.!debug == 1 THEN SAY time()' MyFreeDriveMap(proc) started'
    27342706    alldrives = "C: D: E: F: G: H: I: J: K: L: M: N: O: P: Q: R: S: T: U: V: W: X: Y: Z:"
     
    28312803/*:VRX         ParseResourceData
    28322804*/
    2833 ParseResourceData: PROCEDURE EXPOSE userdata options. advanced. fs. cd. samba.
     2805ParseResourceData: PROCEDURE EXPOSE userdata options. icons. advanced. fs. cd. samba.
    28342806    PARSE ARG userdata, resdata
    28352807    IF options.!debug == 1 THEN SAY time()' ParseResourceData started'
     
    28912863        ok = VRMethod("CN_CONDET", "SetFieldData", cd.lastrh, cd.passwordfh, p_password, cd.spasswordfh, p_spassword, cd.masterfh, p_master, cd.mtypefh, p_mtype)
    28922864        ok = VRMethod("CN_CONDET", "SetFieldData", cd.lastrh, cd.memlenfh, p_memlen, cd.easupportfh, p_easupport, cd.logfilefh, p_logfile, cd.loglevelfh, p_loglevel, cd.rwfh, p_rw)
    2893         ok = VRMethod("CN_CONDET", "SetFieldData", cd.lastrh, cd.statusfh, '#64:PMWP.DLL') /* Active */
    2894         ok = VRMethod("CN_CONDET", "SetRecordAttr", cd.lastrh, "Icon", '#64:PMWP.DLL') /* Active */
     2865        ok = VRMethod("CN_CONDET", "SetFieldData", cd.lastrh, cd.statusfh, icons.!active) /* Active */
     2866        ok = VRMethod("CN_CONDET", "SetRecordAttr", cd.lastrh, "Icon", icons.!active) /* Active */
    28952867
    28962868        hashstr = p_mpoint' 'translate(p_domain)' 'translate(p_server)' 'translate(p_share)' 'p_user' 'p_spassword' 'p_easupport' 'p_rw
     
    29412913*/
    29422914PB_ADVANCED_Click:
    2943     adv_changed = 0
    2944     CALL VRLoadSecondary "SW_ADVANCED", "W"
    2945     IF adv_changed == 1 THEN DO
    2946         advanced.!memlen    = adv_memlen
    2947         advanced.!easupport = adv_eas
    2948         advanced.!readonly  = adv_readonly
    2949         advanced.!alwaysmp  = adv_alwaysmp
    2950     END
     2915    CALL Menu_File_Advanced_Click
    29512916RETURN
    29522917
     
    29542919*/
    29552920PB_ADVCANCEL_Click:
    2956 
    2957     adv_changed = 0
    29582921    CALL SW_ADVANCED_Close
    2959 
    29602922RETURN
    29612923
     
    29692931*/
    29702932PB_ADVOK_Click:
    2971 
    2972     adv_memlen     = VRGet( "SPB_MEMLEN",    "Value" )
    2973     adv_eas        = VRGet( "CB_EAS",        "Set" )
    2974     adv_readonly   = VRGet( "CB_READONLY",   "Set" )
    2975     adv_alwaysmp   = VRGet( "CB_ALWAYSMP",   "Set" )
     2933    advanced.!memlen    = VRGet( "SPB_MEMLEN",    "Value" )
     2934    advanced.!easupport = VRGet( "CB_EAS",        "Set" )
     2935    advanced.!readonly  = VRGet( "CB_READONLY",   "Set" )
     2936    advanced.!alwaysmp  = VRGet( "CB_ALWAYSMP",   "Set" )
    29762937
    29772938    CALL SW_ADVANCED_Close
    2978 
    29792939return
    29802940
    29812941/*:VRX         PB_AUTOSTART_Click
    29822942*/
    2983 PB_AUTOSTART_Click: /* PROCEDURE EXPOSE settings. options. Profile fs. cd. advanced. samba. */
     2943PB_AUTOSTART_Click: /* PROCEDURE EXPOSE settings. options. icons. Profile fs. cd. advanced. samba. */
    29842944    options.!autostart = 1
    29852945
     
    30473007/*:VRX         PB_CONDET_SAVE_Click
    30483008*/
    3049 PB_CONDET_SAVE_Click: PROCEDURE EXPOSE settings. options. Profile fs.  cd. advanced. samba.
     3009PB_CONDET_SAVE_Click: PROCEDURE EXPOSE settings. options. icons. Profile fs.  cd. advanced. samba.
    30503010    IF options.!debug == 1 THEN SAY time()' '||"PB_CONDET_SAVE_Click started"
    30513011
     
    30723032    END
    30733033
    3074     CALL VRMethod 'CN_CONDET', 'GetRecordList', 'All', 'records.'
     3034    CALL VRMethod "CN_CONDET", 'GetRecordList', 'All', 'records.'
    30753035    DO i = 1 TO records.0
    30763036        resdata = ""
     
    31103070/*:VRX         PB_CONNECT_Click
    31113071*/
    3112 PB_CONNECT_Click: PROCEDURE EXPOSE settings. options. fs. advanced. cd. samba.
     3072PB_CONNECT_Click: PROCEDURE EXPOSE settings. options. icons. fs. advanced. cd. samba.
    31133073    IF options.!debug == 1 THEN SAY time()' '||"PB_CONNECT_Click started"
    31143074
     
    32273187/*:VRX         PB_DETACH_Click
    32283188*/
    3229 PB_DETACH_Click: PROCEDURE EXPOSE settings. options. fs. cd. samba.
     3189PB_DETACH_Click: PROCEDURE EXPOSE settings. options. icons. fs. cd. samba.
    32303190    IF options.!debug == 1 THEN SAY time()' '||"PB_DETACH_Click started"
    3231     CALL VRMethod 'CN_CURRENT', 'GetRecordList', 'Selected', 'select.'
     3191    CALL VRMethod "CN_CURRENT", 'GetRecordList', 'Selected', 'select.'
    32323192    IF select.0 < 1 THEN RETURN
    32333193
    3234     userdata = VRMethod( 'CN_CURRENT', 'GetRecordAttr', select.1, 'UserData')
     3194    userdata = VRMethod( "CN_CURRENT", 'GetRecordAttr', select.1, 'UserData')
    32353195    PARSE VAR userdata mountpoint ';' mounts ';' .
    32363196    drive = STRIP( mountpoint, 'T', '\')
     
    32463206    /* Unmount any resources */
    32473207    DO i = 1 TO mounts
    3248         dyn ="ok = "fs.!prefix"RxUnmount( mountpoint, i-1 )"
    3249         IF options.!debug == 1 THEN SAY time()' '||dyn
    3250         interpret dyn; drop dyn
    3251 /* IF options.!debug == 1 THEN SAY time()' '||'Unmount resource' i-1 '=' ok */
     3208        CALL _Dynamic "ok = "fs.!prefix"RxUnmount( mountpoint, i-1 )"
     3209        /* IF options.!debug == 1 THEN SAY time()' '||'Unmount resource' i-1 '=' ok */
    32523210    END
    32533211
    3254     dyn ="ok = "fs.!prefix"RxDetach( drive )"
    3255     IF options.!debug == 1 THEN SAY time()' '||dyn
    3256     interpret dyn; drop dyn
    3257 /* IF options.!debug == 1 THEN SAY time()' '||'Detach' drive '=' ok */
     3212    CALL _Dynamic "ok = "fs.!prefix"RxDetach( drive )"
     3213 /* IF options.!debug == 1 THEN SAY time()' '||'Detach' drive '=' ok */
    32583214
    32593215    CALL Refresh
     
    32703226    CALL VRSet "GB_CURRENT", "ENABLED", 1
    32713227    ok = VRSet("PB_EDITCANCEL","Visible", 0)
    3272     CALL NLVSetText 'DT_DIALOG',        'Caption', 13
     3228    CALL NLVSetText 'DT_DIALOG',        "Caption", 13
    32733229RETURN 0
    32743230
     
    32873243/*:VRX         PB_LOAD_Click
    32883244*/
    3289 PB_LOAD_Click: PROCEDURE EXPOSE settings. options. advanced. vfs. Profile fs. cd. samba.
     3245PB_LOAD_Click: PROCEDURE EXPOSE settings. options. icons. advanced. vfs. Profile fs. cd. samba.
    32903246    IF options.!autoload == 1 then filename = Profile
    32913247    else filename = VRFileDialog('Main', NLVGetMessage( 55 ), 'L', '*.'fs.!profileext)
     
    33723328        CALL PB_UNMOUNT_Click
    33733329        options.!editmode = 0
    3374         CALL NLVSetText 'DT_DIALOG',        'Caption', 13
     3330        CALL NLVSetText 'DT_DIALOG',        "Caption", 13
    33753331        CALL VRSet "PB_UNMOUNT","Enabled", 1
    33763332        CALL VRSet "PB_SAVE","Enabled", 1
     
    35143470/*:VRX         PB_REFRESH_Click
    35153471*/
    3516 PB_REFRESH_Click: PROCEDURE EXPOSE settings. options. fs. samba. debuglevel advanced. UserCred Refreshmode
     3472PB_REFRESH_Click: PROCEDURE EXPOSE settings. options. icons. fs. samba. debuglevel advanced. UserCred Refreshmode
    35173473    IF options.!debug == 1 THEN SAY time()' '||"PB_REFRESH_Click started"
    35183474    call _UserCredUpdate
     
    35293485/*:VRX         PB_SAVE_Click
    35303486*/
    3531 PB_SAVE_Click: PROCEDURE EXPOSE settings. options. Profile fs. cd. advanced. samba.
     3487PB_SAVE_Click: PROCEDURE EXPOSE settings. options. icons. Profile fs. cd. advanced. samba.
    35323488    call PB_CONDET_SAVE_Click
    35333489
     
    35473503    END
    35483504
    3549     CALL VRMethod 'CN_CURRENT', 'GetRecordList', 'All', 'records.'
     3505    CALL VRMethod "CN_CURRENT", 'GetRecordList', 'All', 'records.'
    35503506    DO i = 1 TO records.0
    3551         data = VRMethod('CN_CURRENT', 'GetRecordAttr', records.i, 'UserData')
     3507        data = VRMethod("CN_CURRENT", 'GetRecordAttr', records.i, 'UserData')
    35523508        IF data == '' THEN ITERATE
    35533509        PARSE VAR data node ';' mounts ';' .
    3554         dyn = "ok = "fs.!prefix"RxGetMount( node, 'info.', 'mounts.', 'resource.')"
    3555         IF options.!debug == 1 THEN SAY time()' '||dyn
    3556         interpret dyn; drop dyn
    3557 
     3510
     3511        CALL _Dynamic "ok = "fs.!prefix"RxGetMount( node, 'info.', 'mounts.', 'resource.')"
    35583512        IF ok \= 0 THEN ITERATE
    35593513
     
    35723526*/
    35733527PB_SETTINGS_CANCEL_Click:
    3574 
    3575     adv_changed = 0
    35763528    CALL SW_SETTINGS_Close
    3577 
    35783529return
    35793530
     
    35873538*/
    35883539PB_SETTINGS_OK_Click:
    3589 
    3590     adv_loglevel   = VRGet( "SPIN_LOGLEVEL", "Value" )
    3591     adv_logfile    = VRGet( "EF_LOGFILE",    "Value" )
    3592     adv_browseauth = VRGet( "CB_BROWSEAUTH", "Set" )
    3593     adv_browseimme = VRGet( "CB_BROWSEIMME", "Set" )
    3594     adv_debug      = VRGet( "CB_DEBUG",      "Set" )
    3595     adv_special    = VRGet( "CB_SPECIAL",    "Set" )
    3596     adv_savepassive= VRGet( "CB_SAVEPASSIVE","Set" )
    3597     adv_broadcast  = VRGet( "CB_BROADCAST",  "Set" )
    3598 
    3599     adv_changed  = 1
    3600     if adv_debug == 1 then do
     3540    advanced.!loglevel    = VRGet("SPIN_LOGLEVEL", "Value" )
     3541    advanced.!logfile     = VRGet("EF_LOGFILE",    "Value" )
     3542    advanced.!browseauth  = VRGet("CB_BROWSEAUTH", "Set" )
     3543    advanced.!browseimme  = VRGet("CB_BROWSEIMME", "Set" )
     3544    advanced.!special     = VRGet("CB_SPECIAL",    "Set" )
     3545    advanced.!savepassive = VRGet("CB_SAVEPASSIVE","Set" )
     3546    advanced.!broadcast   = VRGet("CB_BROADCAST",  "Set" )
     3547
     3548    options.!debug        = VRGet("CB_DEBUG",      "Set" )
     3549
     3550    if options.!debug == 1 then do /* Turn on additional columns in connection details view */
    36013551        ok = VRRedirectStdio("ON")
    36023552        ok = VRMethod("CN_CONDET", "SetFieldAttr", cd.mpidxfh ,       "Visible", 1)
     
    36103560        ok = VRMethod("CN_CONDET", "SetFieldAttr", cd.hashfh ,        "Visible", 1)
    36113561    end
    3612     else do
    3613         ok = VRRedirectStdio("OFF")
     3562    else do /* Turn on additional columns in connection details view */
     3563        ok = VRRedirectStdio("OFF") 
    36143564        ok = VRMethod("CN_CONDET", "SetFieldAttr", cd.mpidxfh ,       "Visible", 0)
    36153565        ok = VRMethod("CN_CONDET", "SetFieldAttr", cd.passwordfh ,    "Visible", 0)
     
    36243574
    36253575    CALL SW_SETTINGS_Close
    3626 
    36273576return
    36283577
    36293578/*:VRX         PB_UNMOUNT_Click
    36303579*/
    3631 PB_UNMOUNT_Click: PROCEDURE EXPOSE settings. options. fs. cd. samba.
     3580PB_UNMOUNT_Click: PROCEDURE EXPOSE settings. options. icons. fs. cd. samba.
    36323581    IF options.!debug == 1 THEN SAY time()' '||"PB_UNMOUNT_Click started"
    36333582    IF options.!debug == 1 THEN SAY time()' '||'options.!editmode = 'options.!editmode
    3634     CALL VRMethod 'CN_CURRENT', 'GetRecordList', 'Selected', 'select.'
     3583    CALL VRMethod "CN_CURRENT", 'GetRecordList', 'Selected', 'select.'
    36353584    IF select.0 < 1 THEN RETURN
    36363585
    3637     userdata = VRMethod( 'CN_CURRENT', 'GetRecordAttr', select.1, 'UserData')
     3586    userdata = VRMethod( "CN_CURRENT", 'GetRecordAttr', select.1, 'UserData')
    36383587    PARSE VAR userdata mountpoint ';' mounts ';' .
    36393588say 'userdata="'userdata'"'
     
    36483597    /* Unmount any resources */
    36493598    DO i = 1 TO mounts
    3650         dyn ="ok = "fs.!prefix"RxUnmount( mountpoint, i-1 )"
    3651         IF options.!debug == 1 THEN SAY time()' '||dyn
    3652         interpret dyn; drop dyn
    3653 
    3654 /* IF options.!debug == 1 THEN SAY time()' '||'Unmount resource' i-1 '=' ok */
     3599        CALL _Dynamic "ok = "fs.!prefix"RxUnmount( mountpoint, i-1 )"
     3600        /* IF options.!debug == 1 THEN SAY time()' '||'Unmount resource' i-1 '=' ok */
    36553601    END
    36563602
    36573603    /* Delete mountpoint */
    3658     parent = VRMethod('CN_CURRENT', 'GetRecordAttr', select.1, 'Parent')
     3604    parent = VRMethod("CN_CURRENT", 'GetRecordAttr', select.1, 'Parent')
    36593605    IF parent \= '' THEN DO
    3660         dyn ="ok = "fs.!prefix"RxDeleteMountPoint( mountpoint )"
    3661         IF options.!debug == 1 THEN SAY time()' '||dyn
    3662         interpret dyn; drop dyn
    3663 
    3664 /* IF options.!debug == 1 THEN SAY time()' '||'Delete mountpoint' mountpoint '=' ok */
     3606        CALL _Dynamic "ok = "fs.!prefix"RxDeleteMountPoint( mountpoint )"
     3607        /* IF options.!debug == 1 THEN SAY time()' '||'Delete mountpoint' mountpoint '=' ok */
    36653608    END
    36663609
     
    36843627Refresh:
    36853628    IF options.!debug == 1 THEN SAY time()' Refresh started'
    3686     CALL VRSet 'CN_CURRENT', 'Painting', 0
    3687 
    3688     CALL VRMethod 'CN_CURRENT', 'RemoveRecord', 'All'
     3629    CALL VRSet "CN_CURRENT", 'Painting', 0
     3630
     3631    CALL VRMethod "CN_CURRENT", 'RemoveRecord', 'All'
    36893632
    36903633    /* Remove Active connections from details view */
    3691     ok = VRMethod( 'CN_CONDET', "GetRecordList", 'All', "rh." )
     3634    ok = VRMethod( "CN_CONDET", "GetRecordList", 'All', "rh." )
    36923635
    36933636    do I = 1 to rh.0
     
    37003643        end
    37013644        IF options.!debug == 1 THEN say '  Icon.'i' = "'||VRMethod( "CN_CONDET", "GetFieldData", rh.i, cd.statusfh)'"'
    3702         if VRMethod("CN_CONDET","GetFieldData", rh.i, cd.statusfh) = '#64:PMWP.DLL' then CALL VRMethod 'CN_CONDET', 'RemoveRecord', rh.i
     3645        if VRMethod("CN_CONDET","GetFieldData", rh.i, cd.statusfh) = icons.!active then CALL VRMethod "CN_CONDET", 'RemoveRecord', rh.i
    37033646    end
    37043647
     
    37223665/* Herwig B.
    37233666    CALL VRSet 'Main', 'StatusText', ' ' */
    3724     CALL VRSet 'CN_CURRENT', 'Caption', ' '
     3667    CALL VRSet "CN_CURRENT", "Caption", ' '
    37253668/* Herwig B. */
    37263669
     
    37383681
    37393682    CALL VRMethod "CB_DRIVES", "AddStringList", "drvstem."
    3740     CALL VRSet 'CN_CURRENT', 'Painting', 1
     3683    CALL VRSet "CN_CURRENT", 'Painting', 1
    37413684    IF options.!debug == 1 THEN SAY time()' '||"Refresh done"
    37423685RETURN 0
     
    37443687/*:VRX         SaveSettings
    37453688*/
    3746 SaveSettings: PROCEDURE EXPOSE settings. options. fs. advanced. cd. samba.
     3689SaveSettings: PROCEDURE EXPOSE settings. options. icons. fs. advanced. cd. samba.
    37473690    IF options.!debug == 1 THEN SAY time()' '||"SaveSettings started"
    37483691
     
    37543697 */
    37553698
    3756     font = VRGet('CN_CURRENT', 'Font')
     3699    font = VRGet("CN_CURRENT", 'Font')
    37573700    CALL VRSetIni 'Settings', 'ContainerFont', font, settings.!ini, 'NoClose'
    37583701
     
    37803723    CALL VRSetIni 'Settings', 'BrowseAuth',    advanced.!browseauth , settings.!ini, 'NoClose'
    37813724    CALL VRSetIni 'Settings', 'BrowseImme',    advanced.!browseimme , settings.!ini, 'NoClose'
    3782     CALL VRSetIni 'Settings', 'Debug',         advanced.!debug      , settings.!ini, 'NoClose'
    37833725    CALL VRSetIni 'Settings', 'AlwaysMP',      advanced.!alwaysmp   , settings.!ini, 'NoClose'
    37843726    CALL VRSetIni 'Settings', 'SpecialShares', advanced.!special    , settings.!ini, 'NoClose'
     
    37863728    CALL VRSetIni 'Settings', 'SavePassive',   advanced.!savepassive, settings.!ini, 'NoClose'
    37873729    CALL VRSetIni 'Settings', 'Broadcast',     advanced.!broadcast  , settings.!ini, 'NoClose'
     3730
     3731    CALL VRSetIni 'Settings', 'Debug',         options.!debug       , settings.!ini, 'NoClose'
    37883732
    37893733    /* Save position and size */
     
    38503794    advanced.!savepassive= ''
    38513795    advanced.!broadcast  = ''
    3852     advanced.!debug      = ''
    38533796    advanced.!alwaysmp   = ''
    38543797    advanced.!special    = ''
     
    38573800    credentials.!username = ""
    38583801    credentials.!password = ""
     3802
    38593803    UserCred = ""
    38603804    RefreshMode = ""
    3861 return
    3862 
     3805
     3806    icons.!bat              = '#1:PMWP.DLL'
     3807    icons.!cmd              = '#2:PMWP.DLL'
     3808    icons.!exe              = '#3:PMWP.DLL'
     3809    icons.!template         = '#10:PMWP.DLL'
     3810    icons.!drive            = '#16:PMWP.DLL'
     3811    icons.!defaultfile      = '#24:PMWP.DLL'
     3812    icons.!folder           = '#26:PMWP.DLL'
     3813    icons.!folder_open      = '#34:PMWP.DLL'
     3814    icons.!machine_sleeping = '#61:PMWP.DLL'
     3815    icons.!active           = '#64:PMWP.DLL'
     3816    icons.!passive          = '#68:PMWP.DLL'
     3817    icons.!printer          = '#65:PMWP.DLL'
     3818    icons.!drive_inactive   = '#70:PMWP.DLL'
     3819    icons.!pdf              = '#80'
     3820    icons.!spreadsheet      = '#82'
     3821    icons.!textdocument     = '#86'
     3822    icons.!framework        = '#87'
     3823    icons.!image            = '#88'
     3824    icons.!movie            = '#89'
     3825    icons.!sound            = '#90'
     3826    icons.!warpin           = '#91'
     3827    icons.!zip              = '#92'
     3828    icons.!view             = '#93'
     3829    icons.!plaintext        = '#94'
     3830return
    38633831/*:VRX         SW_ABOUT_Close
    38643832*/
     
    38723840    call SW_ABOUT_Init
    38733841
    3874     CALL NLVSetText 'SW_ABOUT',        'Caption', 1
    3875     CALL NLVSetText 'PB_ABOUT_CLOSE',  'Caption', 29
    3876     CALL NLVSetText 'PB_ABOUT_COPY',   'Caption', 121
     3842    CALL NLVSetText 'SW_ABOUT',        "Caption", 1
     3843    CALL NLVSetText 'PB_ABOUT_CLOSE',  "Caption", 29
     3844    CALL NLVSetText 'PB_ABOUT_COPY',   "Caption", 121
    38773845
    38783846    ok = VRSEt("DT_About","Caption", 'EVFSGUI (c) 2007-2011 Alexander Taylor and Herwig Bauernfeind')
     
    39903958*/
    39913959SW_ADVANCED_Init:
    3992 
    3993     CALL NLVSetText 'SW_ADVANCED',  'Caption', 40
    3994     CALL NLVSetText 'GB_MISC',      'Caption', 43
    3995 
    3996     CALL NLVSetText 'CB_EAS',       'Caption', 44
    3997     CALL NLVSetText 'CB_READONLY',  'Caption', 45
    3998     CALL NLVSetText 'CB_ALWAYSMP',  'Caption', 65
    3999 
    4000     CALL NLVSetText 'PB_ADVOK',     'Caption', 2
    4001     CALL NLVSetText 'PB_ADVCANCEL', 'Caption', 3
    4002     CALL NLVSetText 'PB_ADVHELP',   'Caption', 4
     3960    /* Title bar */
     3961    CALL NLVSetText "SW_ADVANCED",  "Caption", 40
     3962
     3963    /* Options */
     3964    CALL NLVSetText "GB_MISC",      "Caption", 43
     3965    CALL NLVSetText "CB_EAS",       "Caption", 44
     3966    CALL NLVSetText "CB_READONLY",  "Caption", 45
     3967    CALL NLVSetText "CB_ALWAYSMP",  "Caption", 65
     3968
     3969    /* Buttons */
     3970    CALL NLVSetText "PB_ADVOK",     "Caption", 2
     3971    CALL NLVSetText "PB_ADVCANCEL", "Caption", 3
     3972    CALL NLVSetText "PB_ADVHELP",   "Caption", 4
     3973    CALL NLVSetText "GB_MEM",       "Caption", 41     /* Obsolete */
    40033974
    40043975    CALL VRSet "SW_ADVANCED", "HelpTag", NLVGetMessage(40)
    40053976
    4006     /* Obsolete */
    4007     CALL NLVSetText 'GB_MEM',       'Caption', 41
    4008 
    4009     IF advanced.!memlen \= '' THEN
    4010         CALL VRSet 'SPB_MEMLEN', 'Value', advanced.!memlen
    4011     IF advanced.!easupport \= '' THEN
    4012         CALL VRSet 'CB_EAS', 'Set', advanced.!easupport
    4013     IF advanced.!readonly \= '' THEN
    4014         CALL VRSet 'CB_READONLY', 'Set', advanced.!readonly
    4015     IF advanced.!alwaysmp \= '' THEN
    4016         CALL VRSet 'CB_alwaysmp', 'Set', advanced.!alwaysmp
    4017 
    4018     window = VRInfo( "Object" )
    4019     if( \VRIsChildOf( window, "Notebook" ) ) then do
    4020         call VRMethod window, "CenterWindow"
    4021         call VRSet window, "Visible", 1
    4022         call VRMethod window, "Activate"
    4023     end
    4024     drop window
     3977    IF advanced.!memlen    \= "" THEN ok = VRSet("SPB_MEMLEN", "Value", advanced.!memlen)
     3978    IF advanced.!easupport \= "" THEN ok = VRSet("CB_EAS",     "Set",   advanced.!easupport)
     3979    IF advanced.!readonly  \= "" THEN ok = VRSet("CB_READONLY","Set",   advanced.!readonly)
     3980    IF advanced.!alwaysmp  \= "" THEN ok = VRSet("CB_ALWAYSMP","Set",   advanced.!alwaysmp)
     3981
     3982    call VRMethod "SW_ADVANCED", "CenterWindow"
     3983    ok = VRSet("SW_ADVANCED", "Visible", 1)
     3984    call VRMethod "SW_ADVANCED", "Activate"
    40253985return
    40263986
     
    40353995SW_INFO_Create:
    40363996    call SW_INFO_Init
    4037     CALL NLVSetText 'SW_INFO',    'Caption', 92
    4038     CALL NLVSetText 'PB_INFO_OK',    'Caption', 2
     3997    CALL NLVSetText 'SW_INFO',    "Caption", 92
     3998    CALL NLVSetText 'PB_INFO_OK',    "Caption", 2
    40393999
    40404000    Info.TypeFH    = VRMethod( "CN_INFO", "AddField", "String", "Type" )
     
    40834043SW_LOGIN_Create:
    40844044    call SW_LOGIN_Init
    4085     CALL NLVSetText 'DT_USER1',      'Caption', 25
    4086     CALL NLVSetText 'DT_PASSWORD1',  'Caption', 26
    4087     CALL NLVSetText 'PB_LOGIN_OK',    'Caption', 2
    4088     CALL NLVSetText 'PB_LOGIN_CANCEL','Caption', 3
     4045    CALL NLVSetText 'DT_USER1',      "Caption", 25
     4046    CALL NLVSetText 'DT_PASSWORD1',  "Caption", 26
     4047    CALL NLVSetText 'PB_LOGIN_OK',    "Caption", 2
     4048    CALL NLVSetText 'PB_LOGIN_CANCEL',"Caption", 3
    40894049    ok = VRSet("EF_USER1","Value",VRGet("EF_USER","Value"))
    40904050    ok = VRSet("EF_PASSWORD1","Value",VRGet("EF_PASSWORD","Value"))
     
    41364096/* NLVGetMessage(14)' ' */
    41374097    ok = VRSet("SW_MOUNTPOINT","Caption",strip(p_workgroup' \\'p_server'\'p_share,'T','\'))
    4138     CALL NLVSetText 'DT_MPOINT1',   'Caption', 27
    4139     CALL NLVSetText 'PB_NEWMOUNTPOINTOK',    'Caption', 2
    4140     CALL NLVSetText 'PB_NEWMOUNTPOINTCANCEL','Caption', 3
    4141     CALL NLVSetText 'CB_EAS1',       'Caption', 44
    4142     CALL NLVSetText 'CB_READONLY1',  'Caption', 45
    4143     CALL NLVSetText 'CB_ALWAYSMP1',  'Caption', 65
     4098    CALL NLVSetText 'DT_MPOINT1',   "Caption", 27
     4099    CALL NLVSetText 'PB_NEWMOUNTPOINTOK',    "Caption", 2
     4100    CALL NLVSetText 'PB_NEWMOUNTPOINTCANCEL',"Caption", 3
     4101    CALL NLVSetText 'CB_EAS1',       "Caption", 44
     4102    CALL NLVSetText 'CB_READONLY1',  "Caption", 45
     4103    CALL NLVSetText 'CB_ALWAYSMP1',  "Caption", 65
    41444104    ok = VRMethod( "CB_DRIVES", "GetStringList", "freedrives." )
    41454105    ok = VRMethod( "CB_DRIVES1", "AddStringList", "freedrives." )
     
    41824142SW_PROGRESS_Create:
    41834143    call SW_PROGRESS_Init
    4184     CALL NLVSetText 'SW_PROGRESS',  'Caption', 1
    4185     CALL NLVSetText 'DT_PROGRESS',  'Caption', 34
    4186     CALL NLVSetText 'PB_PROGRESS_ABORT',  'Caption', 3
     4144    CALL NLVSetText 'SW_PROGRESS',  "Caption", 1
     4145    CALL NLVSetText 'DT_PROGRESS',  "Caption", 34
     4146    CALL NLVSetText 'PB_PROGRESS_ABORT',  "Caption", 3
    41874147
    41884148    if options.!delay > 0 then ok = VRSet("TM_TheCloser","Delay", options.!delay*1000)
     
    42274187*/
    42284188SW_SETTINGS_Init:
    4229 
    4230     CALL NLVSetText 'SW_SETTINGS',  'Caption', 47
    4231 
    4232     CALL NLVSetText 'GB_GLOBAL',     'Caption', 47
    4233     CALL NLVSetText 'CB_DEBUG',      'Caption', 42
    4234     CALL NLVSetText 'CB_LOGGING',    'Caption', 46
    4235     CALL NLVSetText 'CB_BROWSEIMME', 'Caption', 48
    4236     CALL NLVSetText 'CB_BROWSEAUTH', 'Caption', 49
    4237     CALL NLVSetText 'CB_SPECIAL',    'Caption', 66
    4238     CALL NLVSetText 'CB_SAVEPASSIVE','Caption', 73
    4239     CALL NLVSetText 'CB_BROADCAST',  'Caption', 74
    4240 
    4241     CALL NLVSetText 'PB_SETTINGS_OK',     'Caption', 2
    4242     CALL NLVSetText 'PB_SETTINGS_CANCEL', 'Caption', 3
    4243     CALL NLVSetText 'PB_SETTINGS_HELP',   'Caption', 4
    4244 
    4245 /*  CALL VRSet "SW_ADVANCED", "HelpTag", NLVGetMessage(40) */
    4246 
    4247     IF advanced.!logfile \= '' THEN
    4248         CALL VRSet 'EF_LOGFILE',    'Value', advanced.!logfile
    4249     IF advanced.!loglevel \= '0' THEN
    4250         CALL VRSet 'SPIN_LOGLEVEL', 'Value', advanced.!loglevel
    4251     CALL VRSet 'CB_LOGGING', 'Set', VRFileExists(SysBootDrive()'\ndpsmb.dbg')
    4252     IF advanced.!browseauth \= '' THEN
    4253         CALL VRSet 'CB_BROWSEAUTH', 'Set', advanced.!browseauth
    4254     IF advanced.!browseimme \= '' THEN
    4255         CALL VRSet 'CB_BROWSEimme', 'Set', advanced.!browseimme
    4256     IF advanced.!debug \= '' THEN
    4257         CALL VRSet 'CB_debug',      'Set', advanced.!debug
    4258     IF advanced.!special \= '' THEN
    4259         CALL VRSet 'CB_SPECIAL',    'Set', advanced.!special
    4260     IF advanced.!savepassive \= '' THEN
    4261         CALL VRSet 'CB_SAVEPASSIVE',    'Set', advanced.!savepassive
    4262     IF advanced.!broadcast \= '' THEN
    4263         CALL VRSet 'CB_BROADCAST',    'Set', advanced.!broadcast
    4264 
    4265     window = VRInfo( "Object" )
    4266     if( \VRIsChildOf( window, "Notebook" ) ) then do
    4267         call VRMethod window, "CenterWindow"
    4268         call VRSet window, "Visible", 1
    4269         call VRMethod window, "Activate"
    4270     end
    4271     drop window
     4189    /* Title bar */
     4190    call NLVSetText "SW_SETTINGS",       "Caption", 47
     4191
     4192    /* Options */
     4193    call NLVSetText "GB_GLOBAL",         "Caption", 47
     4194    call NLVSetText "CB_DEBUG",          "Caption", 42
     4195    call NLVSetText "CB_LOGGING",        "Caption", 46
     4196    call NLVSetText "CB_BROWSEIMME",     "Caption", 48
     4197    call NLVSetText "CB_BROWSEAUTH",     "Caption", 49
     4198    call NLVSetText "CB_SPECIAL",        "Caption", 66
     4199    call NLVSetText "CB_SAVEPASSIVE",    "Caption", 73
     4200    call NLVSetText "CB_BROADCAST",      "Caption", 74
     4201
     4202    /* Buttons */
     4203    call NLVSetText "PB_SETTINGS_OK",    "Caption", 2
     4204    call NLVSetText "PB_SETTINGS_CANCEL","Caption", 3
     4205    call NLVSetText "PB_SETTINGS_HELP",  "Caption", 4
     4206
     4207/*  call VRSet "SW_ADVANCED", "HelpTag", NLVGetMessage(40) */
     4208
     4209    /* Init GUI from status variables */
     4210    call VRSet "CB_LOGGING", "Set", VRFileExists(SysBootDrive()"\ndpsmb.dbg")
     4211    if advanced.!logfile     \= ""  then ok = VRSet("EF_LOGFILE",    "Value", advanced.!logfile)
     4212    if advanced.!loglevel    \= "0" then ok = VRSet("SPIN_LOGLEVEL", "Value", advanced.!loglevel)
     4213    if advanced.!browseauth  \= ""  then ok = VRSet("CB_BROWSEAUTH", "Set",   advanced.!browseauth)
     4214    if advanced.!browseimme  \= ""  then ok = VRSet("CB_BROWSEIMME", "Set",   advanced.!browseimme)
     4215    if advanced.!special     \= ""  then ok = VRSet("CB_SPECIAL",    "Set",   advanced.!special)
     4216    if advanced.!savepassive \= ""  then ok = VRSet("CB_SAVEPASSIVE","Set",   advanced.!savepassive)
     4217    if advanced.!broadcast   \= ""  then ok = VRSet("CB_BROADCAST",  "Set",   advanced.!broadcast)
     4218
     4219    if options.!debug        \= ""  then ok = VRSet("CB_debug",      "Set",   options.!debug)
     4220
     4221    call VRMethod "SW_SETTINGS", "CenterWindow"
     4222    ok = VRSet("SW_SETTINGS", "Visible", 1)
     4223    call VRMethod "SW_SETTINGS", "Activate"
    42724224return
    42734225
     
    43064258            if VRget("Menu_View_SmbTree", "Checked") then do
    43074259                if smbtree.!workgroup <> 'SMBTREE.!WORKGROUP' then do
    4308                     ok = VRset("Menu_Selected_Connect", "Visible", VRMethod("CN_SmbTree", "ValidateRecord", smbtree.!workgroup ) )
     4260                    ok = VRset("Menu_Selected_Connect", "Visible", VRMethod("CN_SMBTREE", "ValidateRecord", smbtree.!workgroup ) )
    43094261                end
    43104262            end
     
    43334285    ok = VRSet("Pict_Throbber","PicturePath","#"pidx)
    43344286return
     4287
Note: See TracChangeset for help on using the changeset viewer.