- Timestamp:
- Jan 7, 2010, 11:17:27 AM (16 years ago)
- Location:
- branches/guitools-2.0/evfsgui
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/guitools-2.0/evfsgui/changes
r361 r362 3 3 - Debug on/off option is badly implemented (rework required) 4 4 - Create Icon. stem in order to ease maintainance of icons 5 6 Version 2.0.1 (Alex T. 2010-01-07) 7 - Added: Use 'Combined' font on DBCS systems 8 - Fixed: Default fonts are set correctly 9 - Fixed: Section title colours now correctly default to system settings 10 - Fixed: Various fixes and enhancements to window resize logic 5 11 6 12 Version 2.0.0 (Refresh) -
branches/guitools-2.0/evfsgui/evfsgui.VRP
r361 r362 8 8 VRXWindow: __VREMainWindow,1,1072,1783,891,3951 9 9 VRXWindow: __VRESectionListWindow,1,602,11033,11033,3975 10 VRXWindow: __VREToolsWindow,1,1963,819,69 92,166510 VRXWindow: __VREToolsWindow,1,1963,819,6986,1669 11 11 VRXWindow: __VREWindListWindow,1,470,8528,2650,3150 12 12 UserFile: 1 -
branches/guitools-2.0/evfsgui/evfsgui.VRX
r361 r362 66 66 if __vrlsHWnd = '' then signal __vrlsDone 67 67 if __vrlsWait \= 1 then signal __vrlsDone 68 call VRSet __vrlsHWnd, 'WindowMode', 'Modal' 68 call VRSet __vrlsHWnd, 'WindowMode', 'Modal' 69 69 __vrlsTmp = __vrlsWindows.0 70 70 if( DataType(__vrlsTmp) \= 'NUM' ) then do … … 82 82 __vrlsTmp = __vrlsWindows.0 83 83 __vrlsWindows.0 = __vrlsTmp - 1 84 call VRWindow __vrlsWindows.__vrlsTmp 84 call VRWindow __vrlsWindows.__vrlsTmp 85 85 __vrlsHWnd = '' 86 86 __vrlsDone: … … 91 91 __VXREXX____APPENDS__: 92 92 /* 93 #append U:\Develop\Samba\guitools-2.0\shared\smbtree.vrs94 93 #append U:\Develop\Samba\guitools-2.0\shared\cltinit.vrs 95 94 #append U:\Develop\Samba\guitools-2.0\shared\inittempdir.vrs 96 #append U:\Develop\Samba\guitools-2.0\shared\rexx_md5.VRS97 #append U:\Develop\Samba\guitools-2.0\shared\textini.vrs98 95 #append U:\Develop\Samba\guitools-2.0\shared\nlv.vrs 96 #append U:\Develop\Samba\guitools-2.0\shared\rexx_md5.vrs 97 #append U:\Develop\Samba\guitools-2.0\shared\smbtree.vrs 99 98 */ 100 99 return 101 100 /*:VRX _AddTemplates 102 101 */ 103 _AddTemplates: 102 _AddTemplates: 104 103 105 104 VolTplRH = VRMethod('CN_CURRENT', 'AddRecord', , 'First', 'Volume template', '#10:PMWP.DLL' ) … … 109 108 /*:VRX _ContainersInit 110 109 */ 111 _ContainersInit: 110 _ContainersInit: 112 111 113 112 /* Connection details */ … … 139 138 ok = VRMethod("CN_CONDET", "SetFieldAttr", cd.logfilefh , "Visible", 0) 140 139 ok = VRMethod("CN_CONDET", "SetFieldAttr", cd.loglevelfh , "Visible", 0) 141 ok = VRMethod("CN_CONDET", "SetFieldAttr", cd.hashfh , "Visible", 0) 140 ok = VRMethod("CN_CONDET", "SetFieldAttr", cd.hashfh , "Visible", 0) 142 141 143 142 ok = VRSet("CN_CONDET", "DetailSort", cd.mpointfh ) … … 155 154 /*:VRX _CreateSmbConf 156 155 */ 157 _CreateSmbConf: 156 _CreateSmbConf: 158 157 IF options.!debug == 1 THEN SAY time()' '||"_CreateSmbConf started" 159 158 call lineout samba.!smbconf, '# Samba config file created using EVFSGUI ver. 'word(VRGet("Main","Hinttext"),2) … … 174 173 /*:VRX _DialogPopulate 175 174 */ 176 _DialogPopulate: 175 _DialogPopulate: 177 176 178 177 ok = VRMethod( "CN_smbtree", "GetRecordList", "Visible", "rh." ) … … 196 195 when ResType = "DISK" then ok = VRMethod("EF_SHARE", "AddString", ResName) 197 196 otherwise nop 198 end 197 end 199 198 end 200 199 … … 203 202 /*:VRX _GUIInit 204 203 */ 205 _GUIInit: 204 _GUIInit: 206 205 CALL VRSet 'Main', 'HelpFile', settings.!helpfile 207 206 … … 281 280 CALL VRMethod CB_MOUNT, 'Clear' 282 281 CALL VRMethod CB_MOUNT, 'AddStringList', 'mtype.' 283 END 282 END 284 283 285 284 ok = VRSet("Main","Width", 8200) … … 289 288 /* Setup SmbTree View */ 290 289 ok = VRset("GB_SMBTREE","Painting", 0) 291 FWidth = 32 290 291 FWidth = ((VRGet("Main", "InteriorLeft") / 3) * 2) + 2 292 292 293 293 ok = VRSet("DT_STATUSBAR", "Caption", VRGet("Main", "HintText")) … … 297 297 /*:VRX _PassiveLoad 298 298 */ 299 _PassiveLoad: 299 _PassiveLoad: 300 300 Say "_PassiveLoad started" 301 301 do cnt = 1 to 255 … … 355 355 /*:VRX _PassiveSave 356 356 */ 357 _PassiveSave: 357 _PassiveSave: 358 358 ok = VRDelIni( "PassiveConnections", "ALL", settings.!ini ) 359 359 … … 363 363 cnt = 0 364 364 DO i = 1 TO records.0 365 365 366 366 if VRMethod( 'CN_CONDET', "GetFieldData", records.i, CD.StatusFH) = '#68:PMWP.DLL' then do 367 367 cnt = cnt + 1 … … 437 437 438 438 end 439 440 439 CALL VRMessage 'Main', PrinterName' ('PrinterQueue') prints to port ' Port' connected to \\'p_workgroup'\'p_prtsrv'\'p_printer, NLVGetMessage( 1 ), 'I' 441 440 end … … 447 446 /*:VRX _ShowMsg 448 447 */ 449 _ShowMsg: 450 /* preliminary implementation - we just do not ignore it anymore - 448 _ShowMsg: 449 /* preliminary implementation - we just do not ignore it anymore - 451 450 - ShowMsg from smbmon/smbusers shoule become a shared library */ 452 451 ok = VRSet("DT_StatusBar", "Caption", Msg.Text) … … 455 454 /*:VRX _UserCredUpdate 456 455 */ 457 _UserCredUpdate: 456 _UserCredUpdate: 458 457 credentials.!username = VRGet("EF_USER","Value") 459 458 credentials.!password = VRGet("EF_PASSWORD","Value") 460 459 461 if pos("4OS2", value("COMSPEC",,"OS2ENVIRONMENT")) = 0 460 if pos("4OS2", value("COMSPEC",,"OS2ENVIRONMENT")) = 0 462 461 then UserCred = '--user='Credentials.!username'%'Credentials.!password 463 462 else UserCred = '--user='Credentials.!username'%%'Credentials.!password … … 466 465 /*:VRX CB_DEBUG_Click 467 466 */ 468 CB_DEBUG_Click: 467 CB_DEBUG_Click: 469 468 470 469 return … … 472 471 /*:VRX CB_LOGGING_Click 473 472 */ 474 CB_LOGGING_Click: 475 if VRFileExists(SysBootDrive()'\ndpsmb.dbg') then 473 CB_LOGGING_Click: 474 if VRFileExists(SysBootDrive()'\ndpsmb.dbg') then 476 475 ok = SysFileDelete(SysBootDrive()'\ndpsmb.dbg') 477 476 else do … … 485 484 /*:VRX CB_MOUNT_Change 486 485 */ 487 CB_MOUNT_Change: 486 CB_MOUNT_Change: 488 487 IF options.!debug == 1 THEN SAY time()' '||"CB_MOUNT_Change started" 489 488 … … 542 541 /*:VRX CN_CONDET_Click 543 542 */ 544 CN_CONDET_Click: 543 CN_CONDET_Click: 545 544 ok = VRset("DT_StatusBar","Caption", VRGet("Main", "HintText")) 546 545 return … … 548 547 /*:VRX CN_CONDET_ContextMenu 549 548 */ 550 CN_CONDET_ContextMenu: 549 CN_CONDET_ContextMenu: 551 550 rh = VRInfo('Record') 552 551 if VRMethod( 'CN_CONDET', "ValidateRecord", rh) <> 1 then return 553 552 554 553 /* This is the place to enable specific context menu entries */ 555 ok = VRMethod( "CN_CONDET", "GetRecordList", "All", "records." ) 554 ok = VRMethod( "CN_CONDET", "GetRecordList", "All", "records." ) 556 555 ok = VRSet("Menu_Selected_Remove", "Visible", (records.0 <> 0)) 557 556 ok = VRSet("Menu_Selected_Retry", "Visible", (records.0 <> 0)) … … 565 564 /*:VRX CN_CONDET_DragStart 566 565 */ 567 CN_CONDET_DragStart: 568 566 CN_CONDET_DragStart: 567 569 568 obj = VRInfo( "object" ) 570 ok = VRMethod( "CN_CONDET", "GetRecordList", "SourceOrSelected", "selrec." ) 569 ok = VRMethod( "CN_CONDET", "GetRecordList", "SourceOrSelected", "selrec." ) 571 570 if selrec.0 = 0 then return 572 571 … … 603 602 end 604 603 /* 605 infotext = p_node 606 DO i = 1 TO p_mounts 604 infotext = p_node 605 DO i = 1 TO p_mounts 607 606 infotext = infotext ' ['p_string']' 608 END 607 END 609 608 */ 610 609 if p_string = "" then … … 638 637 CALL VRSet 'MENU_CONTEXT_DETACH', 'Visible', 1 639 638 END 640 ELSE DO 639 ELSE DO 641 640 CALL VRSet 'PB_DETACH', 'Enabled', 0 642 641 CALL VRSet 'MENU_CONTEXT_DETACH', 'Visible', 0 … … 655 654 656 655 /* Herwig B. */ 657 /* we have to check whether the record still exists because under certain 658 circumstances the event routine is executed after the record was already 656 /* we have to check whether the record still exists because under certain 657 circumstances the event routine is executed after the record was already 659 658 removed */ 660 659 if VRMethod( 'CN_CURRENT', "ValidateRecord", rh) <> 1 then return … … 669 668 IF options.!debug == 1 THEN SAY time()' '||p_string 670 669 /* 671 infotext = p_node 672 DO i = 1 TO p_mounts 670 infotext = p_node 671 DO i = 1 TO p_mounts 673 672 infotext = infotext ' ['p_string']' 674 END 673 END 675 674 */ 676 675 if p_string = "" then … … 704 703 CALL VRSet 'MENU_CONTEXT_DETACH', 'Visible', 1 705 704 END 706 ELSE DO 705 ELSE DO 707 706 CALL VRSet 'PB_DETACH', 'Enabled', 0 708 707 CALL VRSet 'MENU_CONTEXT_DETACH', 'Visible', 0 … … 715 714 /*:VRX CN_CURRENT_DoubleClick 716 715 */ 717 CN_CURRENT_DoubleClick: 716 CN_CURRENT_DoubleClick: 718 717 call beep 880, 20 719 718 say "double click" 720 719 rh = VRInfo('Record') 721 720 /* Herwig B. */ 722 /* we have to check whether the record still exists because under certain 723 circumstances the event routine is executed after the record was already 721 /* we have to check whether the record still exists because under certain 722 circumstances the event routine is executed after the record was already 724 723 removed */ 725 724 if VRMethod( 'CN_CURRENT', "ValidateRecord", rh) <> 1 then return … … 732 731 /*:VRX CN_CURRENT_DragDrop 733 732 */ 734 CN_CURRENT_DragDrop: 733 CN_CURRENT_DragDrop: 735 734 say "settings.!network = "settings.!network 736 735 p_workgroup = '' … … 815 814 ParDragCapt = VRMethod(srcCtn, "GetRecordAttr", ParRH, "Caption") 816 815 GParRH = VRMethod(srcCtn, "GetRecordAttr", ParRH, "Parent") 817 816 818 817 if GParRH = "" then do /* A server was dragged */ 819 818 say "Server dragged!" … … 874 873 875 874 do while parTrgRH <> "" 876 partrgCapt = VRMethod(trgCtn, "GetRecordAttr", partrgRH, "Caption") 875 partrgCapt = VRMethod(trgCtn, "GetRecordAttr", partrgRH, "Caption") 877 876 TargetString = partrgCapt||'\'||TargetString 878 877 parTrgRH = VRMethod(trgCtn, "GetRecordAttr", partrgRH , "Parent") … … 894 893 /*:VRX CN_SMBTREE_Click 895 894 */ 896 CN_SMBTREE_Click: 895 CN_SMBTREE_Click: 897 896 ok = VRset("DT_StatusBar","Caption", VRGet("Main", "HintText")) 898 897 rh = VRInfo('Record') … … 900 899 udata = VRMethod('CN_smbtree', 'GetRecordAttr', rh, 'UserData') 901 900 parse var udata udatatype'|'udatamsg 902 901 say udatatype 902 say udatamsg 903 903 ok = VRset("DT_Statusbar", "Caption", udatamsg) 904 904 drop udatatype 905 905 drop udatamsg 906 906 907 907 return 908 908 909 909 /*:VRX CN_SMBTREE_ContextMenu 910 910 */ 911 CN_SMBTREE_ContextMenu: 911 CN_SMBTREE_ContextMenu: 912 912 rh = VRInfo('Record') 913 913 if VRMethod( 'CN_SMBTREE', "ValidateRecord", rh) <> 1 then return 914 914 915 915 Icon = VRMethod("CN_SMBTREE", "GetRecordAttr", rh, "Icon") 916 916 917 917 ok = VRset("MItem_64","Visible", (Icon = "#35:PMWP.DLL")|(Icon = "#62:PMWP.DLL")) 918 918 ok = VRset("Menu_Selected_Info","Visible", (Icon = "#35:PMWP.DLL")) … … 926 926 927 927 /* This is the place to enable specific context menu entries */ 928 ok = VRMethod( "CN_SMBTREE", "GetRecordList", "All", "records." ) 928 ok = VRMethod( "CN_SMBTREE", "GetRecordList", "All", "records." ) 929 929 ok = VRSet("Menu_Selected_Connect", "Visible", (records.0 <> 0 & (Icon <> "#61:PMWP.DLL") )) 930 930 … … 934 934 /*:VRX CN_SMBTREE_DragStart 935 935 */ 936 CN_SMBTREE_DragStart: 937 936 CN_SMBTREE_DragStart: 937 938 938 obj = VRInfo( "object" ) 939 ok = VRMethod( "CN_SMBTREE", "GetRecordList", "SourceOrSelected", "selrec." ) 939 ok = VRMethod( "CN_SMBTREE", "GetRecordList", "SourceOrSelected", "selrec." ) 940 940 if selrec.0 = 0 then return 941 941 … … 962 962 /*:VRX DT_STATUSBAR_ContextMenu 963 963 */ 964 DT_STATUSBAR_ContextMenu: 964 DT_STATUSBAR_ContextMenu: 965 965 ok = VRSet("DT_STATUSBAR","Caption", VRGet("Main", "HintText")) 966 966 return … … 968 968 /*:VRX EF_PASSWORD1_KeyPress 969 969 */ 970 EF_PASSWORD1_KeyPress: 970 EF_PASSWORD1_KeyPress: 971 971 obj = VRInfo( "Object" ) 972 972 keystr = VRGet( obj, "KeyString" ) 973 973 /* say keystr */ 974 select 974 select 975 975 when keystr = "{Enter}" then call PB_LOGIN_OK_Click 976 976 when keystr = "{Newline}" then call PB_LOGIN_OK_Click … … 982 982 /*:VRX EF_PASSWORD_Change 983 983 */ 984 EF_PASSWORD_Change: 984 EF_PASSWORD_Change: 985 985 call _UserCredUpdate 986 986 return … … 988 988 /*:VRX EF_SERVER_Change 989 989 */ 990 EF_SERVER_Change: 990 EF_SERVER_Change: 991 991 Now = VRGet("EF_SERVER","value") 992 992 if Now = "" then return … … 1055 1055 /*:VRX EF_USER1_KeyPress 1056 1056 */ 1057 EF_USER1_KeyPress: 1057 EF_USER1_KeyPress: 1058 1058 obj = VRInfo( "Object" ) 1059 1059 keystr = VRGet( obj, "KeyString" ) 1060 1060 /* say keystr */ 1061 select 1062 when keystr = "{Enter}" then ok = VRMethod( "EF_Password1", "SetFocus" ) 1063 when keystr = "{Newline}" then ok = VRMethod( "EF_Password1", "SetFocus" ) 1061 select 1062 when keystr = "{Enter}" then ok = VRMethod( "EF_Password1", "SetFocus" ) 1063 when keystr = "{Newline}" then ok = VRMethod( "EF_Password1", "SetFocus" ) 1064 1064 when keystr = "{Esc}" then call PB_LOGIN_CANCEL_Click 1065 1065 otherwise nop … … 1069 1069 /*:VRX EF_USER_Change 1070 1070 */ 1071 EF_USER_Change: 1071 EF_USER_Change: 1072 1072 call _UserCredUpdate 1073 1073 return … … 1090 1090 IF options.!debug == 1 THEN SAY ' Dyn code: 'dyn 1091 1091 interpret dyn; drop dyn 1092 1093 1092 1093 1094 1094 IF info.2 > 0 THEN icon = '#64:PMWP.DLL' 1095 1095 ELSE icon = '#68:PMWP.DLL' … … 1099 1099 exc = exc + 1 1100 1100 existrec.exc = rh 1101 userdata = node';'info.2 1102 DO i = 1 TO res.0 1101 userdata = node';'info.2 1102 DO i = 1 TO res.0 1103 1103 userdata = ParseResourceData( userdata, res.i ) 1104 1104 END 1105 if userdata = "UNKNOWN" then ok = VRMethod('CN_CURRENT', 'RemoveRecord', rh) 1105 if userdata = "UNKNOWN" then ok = VRMethod('CN_CURRENT', 'RemoveRecord', rh) 1106 1106 else CALL VRMethod 'CN_CURRENT', 'SetRecordAttr', rh, 'UserData', userdata 1107 1107 1108 DO i = 1 TO points.0 1108 DO i = 1 TO points.0 1109 1109 childnode = node || points.i || '\' 1110 1110 CALL GetChildren childnode, rh … … 1117 1117 GetMountPoints: PROCEDURE EXPOSE existrec. options. fs. cd. samba. 1118 1118 IF options.!debug == 1 THEN SAY time()' GetMountPoints started' 1119 CALL VRSet 'CN_CURRENT', 'Painting', 0 1119 CALL VRSet 'CN_CURRENT', 'Painting', 0 1120 1120 /* IF options.!debug == 1 THEN SAY time()' '||"GetMountPoints: SysDriveMap(USED) started" */ 1121 1121 drvs = SysDriveMap('C:', 'USED') /* was "REMOTE" */ … … 1135 1135 node = attached.i'\' 1136 1136 1137 CALL VRMethod 'CB_DRIVES', 'AddString', attached.i 1137 CALL VRMethod 'CB_DRIVES', 'AddString', attached.i 1138 1138 1139 1139 dyn = "CALL "fs.!prefix"RxGetMount node, 'info.', 'points.', 'res.'" … … 1150 1150 existrec.exc = rh 1151 1151 userdata = node';'info.2 1152 DO j = 1 TO res.0 1152 DO j = 1 TO res.0 1153 1153 userdata = ParseResourceData( userdata, res.j ) 1154 1154 END … … 1189 1189 /*:VRX LoadFileSysFuncs 1190 1190 */ 1191 LoadFileSysFuncs: 1191 LoadFileSysFuncs: 1192 1192 IF options.!debug == 1 THEN SAY time()' LoadFileSysFuncs() started' 1193 1193 Fatal = 1 … … 1196 1196 1197 1197 CtlRestart: 1198 if \ForceNDFS then signal NoNetDrive 1198 if \ForceNDFS then signal NoNetDrive 1199 1199 1200 1200 ForceNDFS: … … 1203 1203 SIGNAL ON SYNTAX NAME NoNetdrive 1204 1204 call NdRxLoadFuncs 1205 SIGNAL OFF SYNTAX 1205 SIGNAL OFF SYNTAX 1206 1206 fs.!prefix = 'ND' 1207 1207 fs.!fileSystemtype = "NDFS32" … … 1211 1211 IF options.!debug == 1 THEN SAY ' NDFS not found' 1212 1212 CALL RxFuncAdd 'EvfsRxLoadFuncs', 'EVFSCALL.DLL', 'EvfsRxLoadFuncs' 1213 SIGNAL ON SYNTAX NAME NoEVFSCALL 1213 SIGNAL ON SYNTAX NAME NoEVFSCALL 1214 1214 CALL EvfsRxLoadFuncs 1215 SIGNAL OFF SYNTAX 1215 SIGNAL OFF SYNTAX 1216 1216 fs.!prefix = 'EVFS' 1217 1217 fs.!fileSystemtype = "EVFS" … … 1258 1258 /*:VRX LoadSettings 1259 1259 */ 1260 LoadSettings: PROCEDURE EXPOSE settings. options. fs. advanced. samba. ShowHidden FWidth1260 LoadSettings: PROCEDURE EXPOSE settings. options. fs. advanced. samba. ShowHidden 1261 1261 IF options.!debug == 1 THEN SAY time()' LoadSettings started' 1262 1262 … … 1314 1314 settings.!curbcolor = VRGetIni('Settings', 'TitleBarBackground', settings.!ini, 'NoClose') 1315 1315 settings.!curfcolor = VRGetIni('Settings', 'TitleBarForeground', settings.!ini, 'NoClose') 1316 IF settings.!curbcolor = '' THEN settings.!curbcolor = VRGetIni('PM_Default_Colors', 'ActiveTitleText', 'User', 'NoClose')1317 IF settings.!curfcolor = '' THEN settings.!curfcolor = VRGetIni('PM_Default_Colors', 'ActiveTitleTextBgnd', 'User', 'NoClose')1316 IF (settings.!curbcolor = '' | settings.!curbcolor = '<default>') THEN settings.!curbcolor = 'SystemActiveTitle' 1317 IF (settings.!curfcolor = '' | settings.!curfcolor = '<default>') THEN settings.!curfcolor = 'SystemActiveTitleText' 1318 1318 1319 1319 settings.!buttonson = VRGetIni('Settings', 'ButtonsOn', settings.!ini, 'NoClose') … … 1334 1334 settings.!network = '' 1335 1335 1336 if \VRFileExists( samba.!smbconf ) then call _CreateSmbConf 1336 if \VRFileExists( samba.!smbconf ) then call _CreateSmbConf 1337 1337 1338 1338 /* Load font settings. 1339 1339 */ 1340 IF VRFileExists( SysBootDrive() || '\OS2DBCS') == 1 THEN 1341 default_font = '9.WarpSans Combined' 1342 ELSE 1343 default_font = '9.WarpSans' 1340 1344 settings.!cfont = VRGetIni('Settings', 'ContainerFont', settings.!ini, 'NoClose') 1341 1345 settings.!wfont = VRGetIni('Settings', 'WindowFont', settings.!ini, 'NoClose' ) 1342 IF settings.!cfont == '' THEN settings.! font = '9.WarpSans'1343 IF settings.!wfont == '' THEN settings.! font = '9.WarpSans'1346 IF settings.!cfont == '' THEN settings.!cfont = default_font 1347 IF settings.!wfont == '' THEN settings.!wfont = default_font 1344 1348 1345 1349 advanced.!browseauth = VRGetIni('Settings', 'BrowseAuth', settings.!ini, 'NoClose') … … 1350 1354 1351 1355 advanced.!debug = VRGetIni('Settings', 'Debug', settings.!ini) 1352 IF advanced.!debug == '' THEN advanced.!debug = 1 /* change this later*/1356 IF advanced.!debug == '' THEN advanced.!debug = 0 /* Turn off debug by default for release builds */ 1353 1357 1354 1358 /* This is a hack and should be reworked! - using several variables for debug is bad! */ … … 1357 1361 1358 1362 advanced.!alwaysmp = VRGetIni('Settings', 'AlwaysMP', settings.!ini) 1359 IF advanced.!alwaysmp == '' THEN advanced.!alwaysmp = 1 1363 IF advanced.!alwaysmp == '' THEN advanced.!alwaysmp = 1 1360 1364 1361 1365 advanced.!special = VRGetIni('Settings', 'SpecialShares', settings.!ini) 1362 IF advanced.!special == '' THEN advanced.!special = 0 1366 IF advanced.!special == '' THEN advanced.!special = 0 1363 1367 1364 1368 advanced.!bigicons = VRGetIni('Settings', 'BigIcons', settings.!ini) 1365 IF advanced.!bigicons == '' THEN advanced.!bigicons = 1 1369 IF advanced.!bigicons == '' THEN advanced.!bigicons = 1 1366 1370 1367 1371 advanced.!savepassive = VRGetIni('Settings', 'SavePassive', settings.!ini) 1368 IF advanced.!savepassive == '' THEN advanced.!savepassive = 0 1372 IF advanced.!savepassive == '' THEN advanced.!savepassive = 0 1369 1373 1370 1374 advanced.!broadcast = VRGetIni('Settings', 'Broadcast', settings.!ini) 1371 IF advanced.!broadcast == '' THEN advanced.!broadcast = 0 1375 IF advanced.!broadcast == '' THEN advanced.!broadcast = 0 1372 1376 1373 1377 /* Apply the settings … … 1382 1386 ok = VRSet("DT_SMBTREE","BACKCOLOR", settings.!curbcolor ) 1383 1387 ok = VRSet("DT_SMBTREE","FORECOLOR", settings.!curfcolor ) 1388 ok = VRSet("DT_CONDET","BACKCOLOR", settings.!curbcolor ) 1389 ok = VRSet("DT_CONDET","FORECOLOR", settings.!curfcolor ) 1384 1390 1385 1391 ok = VRset("CN_CURRENT", "MiniIcons", \advanced.!bigicons) … … 1410 1416 end 1411 1417 1412 if advanced.!debug == 1 then ok = VRRedirectStdio("ON") 1418 if advanced.!debug == 1 then ok = VRRedirectStdio("ON") 1413 1419 1414 1420 IF ( settings.!x >= 0 ) & ( settings.!y >= 0 ) & ( settings.!l >= 0 ) & ( settings.!w >= 0 ) & ( settings.!s >= 0 ) THEN DO … … 1419 1425 CALL VRSet "SPLIT_MAIN", 'Left', settings.!s 1420 1426 END 1421 ELSE 1427 ELSE 1422 1428 CALL VRMethod VRWindow(), 'CenterWindow' 1423 1429 1424 1430 CALL VRSet 'CN_CURRENT', 'Font', settings.!cfont 1425 CALL VRSet 'Main', 'Font', settings.!wfont1426 CALL VRSet 'Main', 'StatusFont', settings.!wfont1427 1431 CALL VRSet 'Main', 'Font', settings.!wfont 1432 CALL VRSet 'Main', 'StatusFont', settings.!wfont 1433 1428 1434 END 1429 1435 … … 1443 1449 /*:VRX Main_Create 1444 1450 */ 1445 Main_Create: 1451 Main_Create: 1446 1452 ok = VRRedirectStdIO("OFF") 1447 1453 options.!debug = 0 … … 1477 1483 IF options.!autoload == 1 THEN CALL PB_LOAD_Click 1478 1484 1479 CALL VRSet "CB_MOUNT", "Selected", 1 1480 CALL VRSet "CB_DRIVES", "Selected", 1 1485 CALL VRSet "CB_MOUNT", "Selected", 1 1486 CALL VRSet "CB_DRIVES", "Selected", 1 1481 1487 IF options.!autoclose == 1 THEN CALL TM_AutoClose_Trigger 1482 1488 /* For whatever reason the timer is not triggered anymore.... … … 1495 1501 /*:VRX Main_KeyPress 1496 1502 */ 1497 Main_KeyPress: 1503 Main_KeyPress: 1498 1504 key = VRGet('Main', 'KeyString') 1499 1505 IF key == '{F5}' THEN CALL Refresh … … 1502 1508 /*:VRX Main_Resize 1503 1509 */ 1504 Main_Resize: 1510 Main_Resize: 1505 1511 if datatype(options.!buttondelta) = 'CHAR' then return 1506 1512 … … 1508 1514 ok = VRset("Main","Painting", 0) 1509 1515 1516 /* Basic measurements */ 1517 main_iwidth = VRGet("Main","InteriorWidth") /* Width of window client-area */ 1518 main_iheight = VRGet("Main","InteriorHeight") /* Height of window client-area */ 1519 sbar_height = VRGet("GB_STATUSBAR","Height") /* Height of status-bar */ 1520 split_left = VRGet("SPLIT_Main","Left") /* Position of the left edge of the split-bar */ 1521 margin = FWidth /* Common margin around controls */ 1522 pbtn_height = 400 /* Height of the panels' internal button areas */ 1523 buttons_top = main_iheight - sbar_height - margin - options.!buttondelta /* Top of the common button area */ 1524 pane_height = buttons_top - (margin * 3) /* Height of a split-bar panel */ 1525 lpane_width = split_left - margin /* Width of the left split-bar panel */ 1526 rpane_width = main_iwidth - split_left - 60 - margin /* Width of the right split-bar panel */ 1527 1510 1528 /* Button bar */ 1511 ok = VRSet("GB_BUTTONS", "Top", VRGet("GB_CURRENT","Height")+ FWidth * 2)1512 ok = VRSet("GB_BUTTONS", "Left", VRGet("Main","Width") -VRGet("GB_Buttons","Width") - FWidth)1529 ok = VRSet("GB_BUTTONS", "Top", buttons_top ) 1530 ok = VRSet("GB_BUTTONS", "Left", main_iwidth - VRGet("GB_Buttons","Width") - margin ) 1513 1531 1514 1532 /* Current Panel */ 1515 ok = VRSet("GB_CURRENT","Visible",1) 1516 ok = VRSet("GB_CURRENT","Top", FWidth) 1517 ok = VRSet("GB_CURRENT","Left", FWidth-24) 1518 ok = VRSet("GB_CURRENT","Width", VRGet("SPLIT_Main","Left")-FWidth+24) /* 2976-FWidth*2) */ 1519 ok = VRSet("GB_CURRENT","Height", VRGet("Main","Height") -920 -FWidth -options.!buttondelta) /* 988 */ 1520 1521 ok = VRset("GB_CURRENT3","Top", FWidth) 1522 ok = VRset("GB_CURRENT3","Left", FWidth) 1523 ok = VRset("GB_CURRENT3","Height", 245 ) 1524 ok = VRset("GB_CURRENT3","Width", VRGet("GB_CURRENT","Width") -(FWidth*2)) 1525 1526 ok = VRset("DT_CURRENT","Top", 8) 1527 ok = VRset("DT_CURRENT","Left", 8) 1528 ok = VRset("DT_CURRENT","Height", 213) 1529 ok = VRset("DT_CURRENT","Width", VRGet("GB_CURRENT3","Width") - 24) 1530 1531 ok = VRset("GB_CURRENT2","Left", FWidth) 1532 ok = VRset("GB_CURRENT2","Top", 245 + FWidth*2) 1533 ok = VRset("GB_CURRENT2","Width", VRGet("GB_CURRENT","Width")-FWidth*2) 1534 ok = VRset("GB_CURRENT2","Height", VRGet("GB_CURRENT","Height")-FWidth*4-400-245) 1535 1536 ok = VRset("CN_CURRENT", "Top", FWidth) 1537 ok = VRset("CN_CURRENT", "Left", FWidth) 1538 ok = VRset("CN_CURRENT", "Width", VRGet("GB_CURRENT2","Width") -(FWidth*2)) 1539 ok = VRset("CN_CURRENT", "Height", VRGet("GB_CURRENT2","Height")-(FWidth*2)) 1540 1541 ok = VRset("PB_DETACH", "Left", FWidth) 1542 ok = VRset("PB_DETACH", "Top", VRGet("GB_CURRENT","Height")- 400-FWidth-12) 1543 ok = VRset("PB_DETACH", "Width", min((VRGet("GB_CURRENT","Width")-FWidth*3)%2, 1313)) 1544 ok = VRset("PB_UNMOUNT", "Left", FWidth*2 +1313 - 12) 1545 /* ok = VRset("PB_UNMOUNT", "Left", VRGet("GB_CURRENT","Width") -VRGet("PB_DETACH","Width")-FWidth) */ 1546 ok = VRset("PB_UNMOUNT", "Top", VRGet("GB_CURRENT","Height")- 400-FWidth-12) 1547 ok = VRset("PB_UNMOUNT", "Width", min((VRGet("GB_CURRENT","Width")-FWidth*3)%2, 1313)) 1533 ok = VRSet("GB_CURRENT", "Visible", 1 ) 1534 ok = VRSet("GB_CURRENT", "Top", margin * 2 ) 1535 ok = VRSet("GB_CURRENT", "Left", margin ) 1536 ok = VRSet("GB_CURRENT", "Width", lpane_width ) 1537 ok = VRSet("GB_CURRENT", "Height", pane_height ) 1538 1539 ok = VRset("GB_CURRENT3", "Top", margin ) 1540 ok = VRset("GB_CURRENT3", "Left", margin ) 1541 ok = VRset("GB_CURRENT3", "Height", 245 ) 1542 ok = VRset("GB_CURRENT3", "Width", lpane_width - (margin * 2)) 1543 1544 ok = VRset("DT_CURRENT", "Top", 8 ) 1545 ok = VRset("DT_CURRENT", "Left", 8 ) 1546 ok = VRset("DT_CURRENT", "Height", 213 ) 1547 ok = VRset("DT_CURRENT", "Width", (lpane_width - (margin * 2)) - 24 ) 1548 1549 ok = VRset("GB_CURRENT2", "Left", margin ) 1550 ok = VRset("GB_CURRENT2", "Top", 245 + (margin * 2) ) 1551 ok = VRset("GB_CURRENT2", "Width", lpane_width - (margin * 2)) 1552 ok = VRset("GB_CURRENT2", "Height", pane_height - (margin * 5) - pbtn_height - 245 ) 1553 1554 ok = VRset("CN_CURRENT", "Top", margin ) 1555 ok = VRset("CN_CURRENT", "Left", margin ) 1556 ok = VRset("CN_CURRENT", "Width", VRGet("GB_CURRENT2","Width") - (margin * 2)) 1557 ok = VRset("CN_CURRENT", "Height", VRGet("GB_CURRENT2","Height") - (margin * 2)) 1558 1559 ok = VRset("PB_DETACH", "Left", margin ) 1560 ok = VRset("PB_DETACH", "Top", pane_height - pbtn_height - (margin * 2) ) 1561 ok = VRset("PB_DETACH", "Width", min((lpane_width-margin*3) % 2, 1313) ) 1562 ok = VRset("PB_UNMOUNT", "Left", VRGet("PB_DETACH","Width") + (margin * 2)) 1563 ok = VRset("PB_UNMOUNT", "Top", pane_height - pbtn_height - (margin * 2) ) 1564 ok = VRset("PB_UNMOUNT", "Width", min((lpane_width-margin*3) % 2, 1313) ) 1548 1565 1549 1566 /* SMBTree stuff */ 1550 ok = VRSet("GB_SMBTREE", "Top", FWidth)1551 ok = VRSet("GB_SMBTREE", "Left", VRGet("SPLIT_Main","Left")+60)1552 ok = VRset("GB_SMBTREE", "Height", VRGet("GB_CURRENT","Height"))1553 ok = VRset("GB_SMBTREE", "Width", VRGet("Main","Width")-VRGet("SPLIT_Main","Left")-60-FWidth*2-24*2)1554 1555 ok = VRset("GB_SMBTREE3","Top", FWidth)1556 ok = VRset("GB_SMBTREE3","Left", FWidth)1557 ok = VRset("GB_SMBTREE3","Height", 245 )1558 ok = VRset("GB_SMBTREE3","Width", VRGet("GB_SMBTREE","Width") -(FWidth*2))1559 1560 ok = VRset("DT_SMBTREE", "Top", 8 )1561 ok = VRset("DT_SMBTREE", "Left", 8 )1562 ok = VRset("DT_SMBTREE", "Width", VRGet("GB_SMBTREE3","Width") - 24)1563 1564 ok = VRset("GB_SMBTREE2","Left", FWidth)1565 ok = VRset("GB_SMBTREE2","Top", 245 + FWidth*2)1566 ok = VRset("GB_SMBTREE2","Width", VRGet("GB_SMBTREE","Width")-FWidth*2)1567 ok = VRset("GB_SMBTREE2","Height", VRGet("GB_SMBTREE","Height")-FWidth*4-400-245)1568 1569 ok = VRset("CN_SMBTREE", "Top", FWidth)1570 ok = VRset("CN_SMBTREE", "Left", FWidth)1571 ok = VRset("CN_SMBTREE", "Width", VRGet("GB_SMBTREE2","Width") -(FWidth*2))1572 ok = VRset("CN_SMBTREE", "Height", VRGet("GB_SMBTREE2","Height") -(FWidth*2))1573 1574 ok = VRset("PB_CONNECT", "Left", FWidth)1575 ok = VRset("PB_CONNECT", "Top", VRGet("GB_SMBTREE","Height")- 400-FWidth-12)1576 ok = VRset("PB_REFRESH", "Left", FWidth*2 +1313 - 12)1577 ok = VRset("PB_REFRESH", "Top", VRGet("GB_SMBTREE","Height")- 400-FWidth-12)1578 1579 ok = VRset("PICT_THROBBER", "Top", VRGet("CN_SMBTREE","Height")%2+100)1580 ok = VRset("PICT_THROBBER", "Left", VRGet("CN_SMBTREE","Width")%2-200)1567 ok = VRSet("GB_SMBTREE", "Top", margin * 2 ) 1568 ok = VRSet("GB_SMBTREE", "Left", split_left + 60 ) 1569 ok = VRset("GB_SMBTREE", "Height", pane_height ) 1570 ok = VRset("GB_SMBTREE", "Width", rpane_width ) 1571 1572 ok = VRset("GB_SMBTREE3","Top", margin ) 1573 ok = VRset("GB_SMBTREE3","Left", margin ) 1574 ok = VRset("GB_SMBTREE3","Height", 245 ) 1575 ok = VRset("GB_SMBTREE3","Width", rpane_width - (margin * 2)) 1576 1577 ok = VRset("DT_SMBTREE", "Top", 8 ) 1578 ok = VRset("DT_SMBTREE", "Left", 8 ) 1579 ok = VRset("DT_SMBTREE", "Width", (rpane_width - (margin * 2)) - 24 ) 1580 1581 ok = VRset("GB_SMBTREE2","Left", margin ) 1582 ok = VRset("GB_SMBTREE2","Top", 245 + (margin * 2) ) 1583 ok = VRset("GB_SMBTREE2","Width", rpane_width - (margin * 2)) 1584 ok = VRset("GB_SMBTREE2","Height", pane_height - (margin * 5) - pbtn_height - 245 ) 1585 1586 ok = VRset("CN_SMBTREE", "Top", margin ) 1587 ok = VRset("CN_SMBTREE", "Left", margin ) 1588 ok = VRset("CN_SMBTREE", "Width", VRGet("GB_SMBTREE2","Width") - (margin * 2)) 1589 ok = VRset("CN_SMBTREE", "Height", VRGet("GB_SMBTREE2","Height") - (margin * 2)) 1590 1591 ok = VRset("PB_CONNECT", "Left", margin) 1592 ok = VRset("PB_CONNECT", "Top", pane_height - pbtn_height - (margin * 2)) 1593 ok = VRset("PB_REFRESH", "Left", VRGet("PB_CONNECT","Width") + (margin * 2)) 1594 ok = VRset("PB_REFRESH", "Top", pane_height - pbtn_height - (margin * 2)) 1595 1596 ok = VRset("PICT_THROBBER", "Top", VRGet("CN_SMBTREE","Height") % 2 + 100 ) 1597 ok = VRset("PICT_THROBBER", "Left", VRGet("CN_SMBTREE","Width") % 2 - 200 ) 1581 1598 1582 1599 /* Connection details stuff */ 1583 ok = VRSet("GB_CONDET", "Top", FWidth)1584 ok = VRSet("GB_CONDET", "Left", VRGet("SPLIT_Main","Left")+60)1585 ok = VRset("GB_CONDET", "Height", VRGet("GB_CURRENT","Height"))1586 ok = VRset("GB_CONDET", "Width", VRGet("Main","Width")-VRGet("SPLIT_Main","Left")-60-FWidth*2-24*2)1587 1588 ok = VRset("GB_CONDET3","Top", FWidth)1589 ok = VRset("GB_CONDET3","Left", FWidth)1590 ok = VRset("GB_CONDET3","Height", 245 )1591 ok = VRset("GB_CONDET3","Width", VRGet("GB_CONDET","Width") -(FWidth*2))1592 1593 ok = VRset("DT_CONDET", "Top", 8 )1594 ok = VRset("DT_CONDET", "Left", 8 )1595 ok = VRset("DT_CONDET", "Width", VRGet("GB_CONDET3","Width") - 24)1596 1597 ok = VRset("GB_CONDET2", "Left", FWidth)1598 ok = VRset("GB_CONDET2", "Top", 245 + FWidth*2)1599 ok = VRset("GB_CONDET2", "Width", VRGet("GB_CONDET","Width")-FWidth*2)1600 ok = VRset("GB_CONDET2", "Height", VRGet("GB_CONDET","Height")-FWidth*4-400-245)1601 1602 ok = VRset("CN_CONDET", "Top", FWidth)1603 ok = VRset("CN_CONDET", "Left", FWidth)1604 ok = VRset("CN_CONDET", "Width", VRGet("GB_CONDET2","Width") -(FWidth*2))1605 ok = VRset("CN_CONDET", "Height", VRGet("GB_CONDET2","Height") -(FWidth*2))1606 1607 ok = VRset("PB_CONDET_SAVE", "Left", FWidth)1608 ok = VRset("PB_CONDET_SAVE", "Top", VRGet("GB_CONDET","Height")- 400-FWidth-12)1609 ok = VRset("PB_CONDET_LOAD", "Left", FWidth*2 +1313 - 12)1610 ok = VRset("PB_CONDET_LOAD", "Top", VRGet("GB_CONDET","Height")- 400-FWidth-12)1600 ok = VRSet("GB_CONDET", "Top", margin * 2 ) 1601 ok = VRSet("GB_CONDET", "Left", split_left + 60 ) 1602 ok = VRset("GB_CONDET", "Height", pane_height ) 1603 ok = VRset("GB_CONDET", "Width", rpane_width ) 1604 1605 ok = VRset("GB_CONDET3","Top", margin ) 1606 ok = VRset("GB_CONDET3","Left", margin ) 1607 ok = VRset("GB_CONDET3","Height", 245 ) 1608 ok = VRset("GB_CONDET3","Width", rpane_width - (margin * 2)) 1609 1610 ok = VRset("DT_CONDET", "Top", 8 ) 1611 ok = VRset("DT_CONDET", "Left", 8 ) 1612 ok = VRset("DT_CONDET", "Width", (rpane_width - (margin * 2)) - 24 ) 1613 1614 ok = VRset("GB_CONDET2", "Left", margin ) 1615 ok = VRset("GB_CONDET2", "Top", 245 + (margin * 2)) 1616 ok = VRset("GB_CONDET2", "Width", rpane_width - (margin * 2)) 1617 ok = VRset("GB_CONDET2", "Height", pane_height - (margin * 5) - pbtn_height - 245 ) 1618 1619 ok = VRset("CN_CONDET", "Top", margin ) 1620 ok = VRset("CN_CONDET", "Left", margin ) 1621 ok = VRset("CN_CONDET", "Width", VRGet("GB_CONDET2","Width") - (margin * 2)) 1622 ok = VRset("CN_CONDET", "Height", VRGet("GB_CONDET2","Height") - (margin * 2)) 1623 1624 ok = VRset("PB_CONDET_SAVE", "Left", margin ) 1625 ok = VRset("PB_CONDET_SAVE", "Top", pane_height - pbtn_height - (margin * 2) ) 1626 ok = VRset("PB_CONDET_LOAD", "Left", VRGet("PB_CONDET_SAVE","Width") + (margin * 2)) 1627 ok = VRset("PB_CONDET_LOAD", "Top", pane_height - pbtn_height - (margin * 2) ) 1611 1628 1612 1629 /* Dialog stuff */ 1613 ok = VRSet("GB_DIALOG", "Top", FWidth)1614 ok = VRSet("GB_DIALOG", "Left", VRGet("SPLIT_Main","Left")+60)1615 ok = VRset("GB_DIALOG", "Height", VRGet("GB_CURRENT","Height"))1616 ok = VRset("GB_DIALOG", "Width", VRGet("Main","Width")-VRGet("SPLIT_Main","Left")-60-FWidth*2-24*2)1617 1618 ok = VRset("GB_DIALOG3", "Top", FWidth)1619 ok = VRset("GB_DIALOG3", "Left", FWidth)1620 ok = VRset("GB_DIALOG3", "Height", 245)1621 ok = VRset("GB_DIALOG3", "Width", VRGet("GB_DIALOG","Width") -(FWidth*2))1622 1623 ok = VRset("DT_DIALOG", "Top", 8)1624 ok = VRset("DT_DIALOG", "Left", 8)1625 ok = VRset("DT_DIALOG", "Width", VRGet("GB_DIALOG3","Width") - 24)1626 1627 ok = VRset("PB_MOUNT", "Left", FWidth)1628 ok = VRset("PB_MOUNT", "Top", VRGet("GB_DIALOG","Height")- 400-FWidth-12)1629 ok = VRset("PB_EDITCANCEL", "Left", FWidth*2 +1313 - 12)1630 ok = VRset("PB_EDITCANCEL", "Top", VRGet("GB_DIALOG","Height")- 400-FWidth-12)1631 1632 ok = VRset("GB_SHARE", "Left", FWidth)1633 ok = VRset("GB_SHARE", "Top", 245 + FWidth*2)1634 ok = VRset("GB_SHARE", "Width", VRGet("GB_DIALOG","Width")-FWidth*2)1635 1636 ok = VRset("GB_AUTH", "Left", FWidth)1637 ok = VRset("GB_AUTH", "Top", 245 + FWidth*3+ VRGet("GB_SHARE","Height"))1638 ok = VRset("GB_AUTH", "Width", VRGet("GB_DIALOG","Width")-FWidth*2)1639 1640 ok = VRset("GB_MPOINT","Left", FWidth)1641 ok = VRset("GB_MPOINT","Top", 245 + FWidth*4+ VRGet("GB_SHARE","Height") + VRGet("GB_AUTH","Height"))1642 ok = VRset("GB_MPOINT","Width", VRGet("GB_DIALOG","Width")-FWidth*2)1643 1644 ok = VRset("SPLIT_Main", "Visible", 1)1645 ok = VRset("SPLIT_Main", "Top", FWidth)1646 ok = VRset("SPLIT_Main", "Height", VRGet("GB_CURRENT","Height"))1647 1648 ok = VRSet("GB_STATUSBAR", "Left", FWidth-24)1649 ok = VRSet("GB_STATUSBAR", "Top", VRGet("Main","Height")-VRGet("GB_STATUSBAR","Height")-FWidth-640+24)1650 ok = VRSet("GB_STATUSBAR", "Width", VRGet("Main","Width")-2*FWidth-2*24-12)1651 1652 ok = VRset("DT_STATUSBAR", "Top", 8)1653 ok = VRset("DT_STATUSBAR", "Left", 8)1654 ok = VRset("DT_STATUSBAR", "Width", VRGet("GB_CURRENT","Width")+VRGet("GB_SMBTREE","Width")+60-24*2)1630 ok = VRSet("GB_DIALOG", "Top", margin * 2 ) 1631 ok = VRSet("GB_DIALOG", "Left", split_left + 60 ) 1632 ok = VRset("GB_DIALOG", "Height", pane_height ) 1633 ok = VRset("GB_DIALOG", "Width", rpane_width ) 1634 1635 ok = VRset("GB_DIALOG3", "Top", margin ) 1636 ok = VRset("GB_DIALOG3", "Left", margin ) 1637 ok = VRset("GB_DIALOG3", "Height", 245 ) 1638 ok = VRset("GB_DIALOG3", "Width", rpane_width - (margin * 2)) 1639 1640 ok = VRset("DT_DIALOG", "Top", 8 ) 1641 ok = VRset("DT_DIALOG", "Left", 8 ) 1642 ok = VRset("DT_DIALOG", "Width", (rpane_width - (margin * 2)) - 24 ) 1643 1644 ok = VRset("PB_MOUNT", "Left", margin ) 1645 ok = VRset("PB_MOUNT", "Top", pane_height - pbtn_height - (margin * 2)) 1646 ok = VRset("PB_EDITCANCEL", "Left", VRGet("PB_MOUNT","Width") + (margin * 2)) 1647 ok = VRset("PB_EDITCANCEL", "Top", pane_height - pbtn_height - (margin * 2)) 1648 1649 ok = VRset("GB_SHARE", "Left", margin ) 1650 ok = VRset("GB_SHARE", "Top", 245 + (margin * 2)) 1651 ok = VRset("GB_SHARE", "Width", rpane_width - (margin * 2)) 1652 1653 ok = VRset("GB_AUTH", "Left", margin ) 1654 ok = VRset("GB_AUTH", "Top", 245 + (margin * 3) + VRGet("GB_SHARE","Height")) 1655 ok = VRset("GB_AUTH", "Width", rpane_width - (margin * 2)) 1656 1657 ok = VRset("GB_MPOINT","Left", margin ) 1658 ok = VRset("GB_MPOINT","Top", 245 + (margin * 4) + VRGet("GB_SHARE","Height") + VRGet("GB_AUTH","Height")) 1659 ok = VRset("GB_MPOINT","Width", rpane_width - (margin * 2)) 1660 1661 ok = VRset("SPLIT_Main", "Visible", 1 ) 1662 ok = VRset("SPLIT_Main", "Top", margin * 2 ) 1663 ok = VRset("SPLIT_Main", "Height", pane_height ) 1664 1665 ok = VRSet("GB_STATUSBAR", "Left", margin ) 1666 ok = VRSet("GB_STATUSBAR", "Top", main_iheight - sbar_height - margin ) 1667 ok = VRSet("GB_STATUSBAR", "Width", lpane_width + 50 + rpane_width ) 1668 1669 ok = VRset("DT_STATUSBAR", "Top", 12 ) 1670 ok = VRset("DT_STATUSBAR", "Left", 12 ) 1671 ok = VRset("DT_STATUSBAR", "Width", (lpane_width + 50 + rpane_width) - 24 ) 1655 1672 1656 1673 ok = VRset("Main","Painting", 1) … … 1666 1683 else interpret eventString 1667 1684 end 1668 end 1685 end 1669 1686 if TrashedResize then CALL Main_Resize 1670 1687 IF options.!debug == 1 THEN SAY time()' Main_Resize done' … … 1672 1689 /*:VRX Menu_Context_ChangeView_Click 1673 1690 */ 1674 Menu_Context_ChangeView_Click: 1691 Menu_Context_ChangeView_Click: 1675 1692 ok = VRSet("Cn_Current","View","NameTree") 1676 1693 return … … 1678 1695 /*:VRX Menu_Context_Detach_Click 1679 1696 */ 1680 Menu_Context_Detach_Click: 1697 Menu_Context_Detach_Click: 1681 1698 call PB_DETACH_Click 1682 1699 return … … 1684 1701 /*:VRX Menu_Context_Edit_Click 1685 1702 */ 1686 Menu_Context_Edit_Click: 1703 Menu_Context_Edit_Click: 1687 1704 IF options.!debug == 1 THEN SAY time()' Menu_Context_Edit_Click started' 1688 1705 options.!editmode = 1 … … 1723 1740 /*:VRX Menu_Context_Open_Click 1724 1741 */ 1725 Menu_Context_Open_Click: 1742 Menu_Context_Open_Click: 1726 1743 CALL VRMethod 'CN_CURRENT', 'GetRecordList', 'Selected', 'select.' 1727 1744 IF select.0 < 1 THEN RETURN … … 1731 1748 1732 1749 say mountpoint 1733 rc = SysOpenObject(mountpoint, "DEFAULT", 1) 1750 rc = SysOpenObject(mountpoint, "DEFAULT", 1) 1734 1751 return 1735 1752 1736 1753 /*:VRX Menu_Context_Unmount_Click 1737 1754 */ 1738 Menu_Context_Unmount_Click: 1755 Menu_Context_Unmount_Click: 1739 1756 call PB_UNMOUNT_Click 1740 1757 return … … 1742 1759 /*:VRX Menu_File_Advanced_Click 1743 1760 */ 1744 Menu_File_Advanced_Click: 1761 Menu_File_Advanced_Click: 1745 1762 call PB_ADVANCED_Click 1746 1763 return … … 1748 1765 /*:VRX Menu_File_Autostart_Activate_Click 1749 1766 */ 1750 Menu_File_Autostart_Activate_Click: 1767 Menu_File_Autostart_Activate_Click: 1751 1768 call PB_AUTOSTART_Click 1752 1769 return … … 1754 1771 /*:VRX Menu_File_Autostart_Click 1755 1772 */ 1756 Menu_File_Autostart_Click: 1773 Menu_File_Autostart_Click: 1757 1774 1758 1775 return … … 1760 1777 /*:VRX Menu_File_Autostart_Deactivate_Click 1761 1778 */ 1762 Menu_File_Autostart_Deactivate_Click: 1763 ok = SysDestroyObject("<EVFSGUI_AUTOSTART>") 1779 Menu_File_Autostart_Deactivate_Click: 1780 ok = SysDestroyObject("<EVFSGUI_AUTOSTART>") 1764 1781 IF ok == 1 THEN CALL VRMessage 'Main', NLVGetMessage( 79 ), NLVGetMessage( 1 ) 1765 1782 ELSE CALL VRMessage 'Main', NLVGetMessage( 78 ), NLVGetMessage( 5 ), 'E' … … 1768 1785 /*:VRX Menu_File_Close_Click 1769 1786 */ 1770 Menu_File_Close_Click: 1787 Menu_File_Close_Click: 1771 1788 call PB_CLOSE_Click 1772 1789 return … … 1774 1791 /*:VRX Menu_File_Load_Click 1775 1792 */ 1776 Menu_File_Load_Click: 1793 Menu_File_Load_Click: 1777 1794 call PB_LOAD_Click 1778 1795 return … … 1780 1797 /*:VRX Menu_File_Save_Click 1781 1798 */ 1782 Menu_File_Save_Click: 1799 Menu_File_Save_Click: 1783 1800 call PB_CONDET_SAVE_Click 1784 1801 return … … 1786 1803 /*:VRX Menu_File_Settings_Click 1787 1804 */ 1788 Menu_File_Settings_Click: 1805 Menu_File_Settings_Click: 1789 1806 adv_changed = 0 1790 1807 CALL VRLoadSecondary "SW_SETTINGS", "W" … … 1795 1812 advanced.!browseimme= adv_browseimme 1796 1813 advanced.!debug = adv_debug 1797 advanced.!special = adv_special 1814 advanced.!special = adv_special 1798 1815 advanced.!savepassive=adv_savepassive 1799 1816 advanced.!broadcast =adv_broadcast … … 1803 1820 /*:VRX Menu_Help_About_Click 1804 1821 */ 1805 Menu_Help_About_Click: 1822 Menu_Help_About_Click: 1806 1823 CALL VRMessage 'Main', VRGet("Main", "HintText")||'0D0A'x||'(c) 2007-2009 Alex Taylor and Herwig Bauernfeind',NLVGetMessage( 1 ), 'I' 1807 1824 return … … 1809 1826 /*:VRX Menu_Help_Extended_Click 1810 1827 */ 1811 Menu_Help_Extended_Click: 1828 Menu_Help_Extended_Click: 1812 1829 call PB_HELP_Click 1813 1830 return … … 1815 1832 /*:VRX Menu_Selected_Connect_Click 1816 1833 */ 1817 Menu_Selected_Connect_Click: 1834 Menu_Selected_Connect_Click: 1818 1835 call PB_CONNECT_Click 1819 1836 return … … 1821 1838 /*:VRX Menu_Selected_Default_Workgroup_Click 1822 1839 */ 1823 Menu_Selected_Default_Workgroup_Click: 1840 Menu_Selected_Default_Workgroup_Click: 1824 1841 workgroupname = VRMethod("CN_smbtree","GetRecordAttr",rh,"Caption") 1825 1842 ok = TRSetIni("[global]","workgroup", workgroupname, samba.!smbconf) … … 1828 1845 /*:VRX Menu_Selected_Info_Click 1829 1846 */ 1830 Menu_Selected_Info_Click: 1831 ok = VRMethod( "CN_smbtree", "GetRecordList", "SourceOrSelected", "srcrec." ) 1847 Menu_Selected_Info_Click: 1848 ok = VRMethod( "CN_smbtree", "GetRecordList", "SourceOrSelected", "srcrec." ) 1832 1849 if srcrec.0 = 0 then return 1833 1850 … … 1855 1872 /*:VRX Menu_Selected_Remove_Click 1856 1873 */ 1857 Menu_Selected_Remove_Click: 1858 ok = VRMethod( "CN_CONDET", "GetRecordList", "SourceOrSelected", "selrec." ) 1874 Menu_Selected_Remove_Click: 1875 ok = VRMethod( "CN_CONDET", "GetRecordList", "SourceOrSelected", "selrec." ) 1859 1876 if selrec.0 = 0 then return 1860 1877 … … 1871 1888 btns.2 = NLVGetMessage( 7 ) 1872 1889 confirm = VRMessage('Main', NLVGetMessage( 72, mountpoint ), NLVGetMessage( 8 ), 'Q', 'btns.', 1, 2 ) 1873 IF confirm \= 1 THEN RETURN 1890 IF confirm \= 1 THEN RETURN 1874 1891 1875 1892 dyn ="ok = "fs.!prefix"RxUnmount( mountpoint, mpidx )" … … 1890 1907 Menu_Selected_Retry_Click: PROCEDURE EXPOSE settings. options. vfs. fs. advanced. cd. samba. 1891 1908 1892 ok = VRMethod( "CN_CONDET", "GetRecordList", "SourceOrSelected", "srcrec." ) 1909 ok = VRMethod( "CN_CONDET", "GetRecordList", "SourceOrSelected", "srcrec." ) 1893 1910 if srcrec.0 = 0 then return 1894 1911 … … 1933 1950 /*:VRX Menu_View_Buttons_Click 1934 1951 */ 1935 Menu_View_Buttons_Click: 1952 Menu_View_Buttons_Click: 1953 current_height = VRGet("Main", "Height") 1954 buttons_height = FWidth * 2 + 400 1936 1955 if settings.!buttonson = 1 then do 1937 1956 ok = VRSet("Menu_View_Buttons","Checked",0) … … 1939 1958 options.!buttondelta = 0 1940 1959 settings.!buttonson = 0 1960 new_height = current_height - buttons_height 1941 1961 end 1942 1962 else do 1943 1963 ok = VRSet("GB_Buttons","Visible", 1) 1944 1964 ok = VRSet("Menu_View_Buttons","Checked",1) 1945 options.!buttondelta = 4401965 options.!buttondelta = buttons_height 1946 1966 settings.!buttonson = 1 1947 end 1948 1949 ok = VRSet("Main","Height", VRGet("GB_CURRENT", "Height") +920 +FWidth +options.!buttondelta) 1967 new_height = current_height + buttons_height 1968 end 1969 1970 ok = VRSet("Main", "Height", new_height ) 1950 1971 return 1951 1972 1952 1973 /*:VRX Menu_View_ConDet_Click 1953 1974 */ 1954 Menu_View_ConDet_Click: 1975 Menu_View_ConDet_Click: 1955 1976 if VRGet("TM_Throbber","Enabled") = 1 then ok = VRset("Pict_Throbber", "Visible", 0) 1956 1977 … … 1972 1993 /*:VRX Menu_View_Dialog_Click 1973 1994 */ 1974 Menu_View_Dialog_Click: 1995 Menu_View_Dialog_Click: 1975 1996 if VRGet("TM_Throbber","Enabled") = 1 then ok = VRset("Pict_Throbber", "Visible", 0) 1976 1997 … … 1996 2017 /*:VRX Menu_View_MiniIcons_Click 1997 2018 */ 1998 Menu_View_MiniIcons_Click: 2019 Menu_View_MiniIcons_Click: 1999 2020 advanced.!bigicons = \advanced.!bigicons 2000 2021 ok = VRset("CN_CURRENT", "MiniIcons", \advanced.!bigicons) … … 2006 2027 /*:VRX Menu_View_SmbTree_Click 2007 2028 */ 2008 Menu_View_SmbTree_Click: 2029 Menu_View_SmbTree_Click: 2009 2030 if VRGet("TM_Throbber","Enabled") = 1 then ok = VRset("Pict_Throbber", "Visible", 1) 2010 2031 … … 2032 2053 call VRSet VRWindow(), 'Pointer', 'Wait' 2033 2054 2034 /* Disabled because we merge profile now - in earlier revisions 2035 we replaced it but only for preexisting drives - this made only 2036 as long as we were unabled to detect double connections - this could be made an option! 2055 /* Disabled because we merge profile now - in earlier revisions 2056 we replaced it but only for preexisting drives - this made only 2057 as long as we were unabled to detect double connections - this could be made an option! 2037 2058 IF options.!autoload then do 2038 2059 dyn = "ok = "fs.!prefix"RxDetach(vfs.!drive)" 2039 2060 IF options.!debug == 1 THEN SAY time()' '||dyn 2040 2061 interpret dyn; drop dyn 2041 2042 IF options.!debug == 1 THEN SAY time()' '||'Autoload Detach "'vfs.!drive'" =' ok 2062 2063 IF options.!debug == 1 THEN SAY time()' '||'Autoload Detach "'vfs.!drive'" =' ok 2043 2064 end */ 2044 2065 … … 2049 2070 2050 2071 interpret dyn; drop dyn 2051 2052 IF options.!debug == 1 THEN SAY time()' '||'Attach "'vfs.!drive'" =' ok 2072 2073 IF options.!debug == 1 THEN SAY time()' '||'Attach "'vfs.!drive'" =' ok 2053 2074 end 2054 2075 … … 2057 2078 IF options.!debug == 1 THEN SAY time()' '||dyn 2058 2079 interpret dyn; drop dyn 2059 2060 IF options.!debug == 1 THEN SAY time()' '||'Create "'vfs.!mountpoint'" = 'CreateMP 2080 2081 IF options.!debug == 1 THEN SAY time()' '||'Create "'vfs.!mountpoint'" = 'CreateMP 2061 2082 2062 2083 … … 2071 2092 IF options.!master \= '' THEN src = src';MASTER='options.!master 2072 2093 IF options.!mastertype \= '' THEN src = src';MASTERTYPE='options.!mastertype 2073 IF options.!memlen \= '' THEN src = src';MEMLEN='options.!memlen 2094 IF options.!memlen \= '' THEN src = src';MEMLEN='options.!memlen 2074 2095 IF options.!logfile \= '' THEN src = src';LOGFILE='options.!logfile 2075 2096 IF options.!loglevel \= '' THEN src = src';LOGLEVEL='options.!loglevel … … 2119 2140 ok = ParseResourceData(vfs.!mountpoint,'SMBFS SMBFS64 \\'options.!workgroup':'options.!server'\'options.!share'@'options.!user||src' 'rwFlag) 2120 2141 2121 /* Now mount the resource */ 2142 /* Now mount the resource */ 2122 2143 dyn ="ok = "fs.!prefix"RxMount('smbfs', vfs.!mountpoint, src, rwFlag)" 2123 2144 IF options.!debug == 1 THEN SAY time()' '||dyn 2124 2145 interpret dyn; drop dyn 2125 2146 2126 2147 IF options.!debug == 1 THEN SAY time()' '||'Mount "'vfs.!mountpoint'" =' ok 2127 2148 if ok <> 0 then do … … 2142 2163 2143 2164 /* In case the mountpoint was created for this failed operation, it is (optionally) removed again */ 2144 if CreateMP = 0 & \advanced.!alwaysmp then do 2165 if CreateMP = 0 & \advanced.!alwaysmp then do 2145 2166 dyn ="ok = "fs.!prefix"RxDeleteMountPoint( vfs.!mountpoint )" 2146 2167 interpret dyn … … 2150 2171 drop CreateMP /* not required anymore */ 2151 2172 2152 /* Obsolete - the IOCtl will not be implemented this way in the plugin 2173 /* Obsolete - the IOCtl will not be implemented this way in the plugin 2153 2174 The REXX function is present, but is has no counterpart in the plugin 2154 2175 ok = EvfsRxIoctl( 100 , vfs.!mountpoint, outstring) … … 2168 2189 useddrives= SysDriveMap("C:","USED") 2169 2190 /* IF options.!debug == 1 THEN SAY time()' '||"SysDriveMap(USED) done" */ 2170 2191 2171 2192 Alldr = words(alldrives) 2172 2193 FreeDriveMap = "" … … 2185 2206 /*:VRX NoEVFSCALL 2186 2207 */ 2187 NoEVFSCALL: 2208 NoEVFSCALL: 2188 2209 CALL VRMessage 'Main', NLVGetMessage( 100 ), NLVGetMessage( 5 ), 'E' 2189 2210 signal Halt … … 2192 2213 /*:VRX ParseCommandLine 2193 2214 */ 2194 ParseCommandLine: 2215 ParseCommandLine: 2195 2216 IF options.!debug == 1 THEN SAY time()' ParseCommandLine() started' 2196 2217 CmdLine = VRGet("Application","Commandline") … … 2250 2271 userData = "UNKNOWN" 2251 2272 end 2252 else do 2273 else do 2253 2274 cd.lastrh = VRMethod("CN_CONDET","AddRecord") 2254 PARSE VAR userdata p_mpoint ';' p_mpidx ';' . 2275 PARSE VAR userdata p_mpoint ';' p_mpidx ';' . 2255 2276 2256 2277 p_mpoint = strip(p_mpoint,'T','\')||'\' … … 2259 2280 2260 2281 PARSE VAR resdata . 'WORKGROUP=' p_domain ';' . 2261 PARSE VAR resdata . 'SERVER=' p_server ';' . 2282 PARSE VAR resdata . 'SERVER=' p_server ';' . 2262 2283 PARSE VAR resdata . 'SHARE=' p_share ';' . 2263 2284 PARSE VAR resdata . 'USER=' p_user ';' . … … 2269 2290 PARSE VAR resdata . 'LOGFILE=' p_logfile ';' . 2270 2291 PARSE VAR resdata . 'LOGLEVEL=' p_loglevel ';' . 2271 PARSE VAR resdata . 'EASUPPORT=' p_easupport ' ' 2292 PARSE VAR resdata . 'EASUPPORT=' p_easupport ' ' 2272 2293 2273 2294 if p_master = "" then p_master = "WORKGROUP" … … 2295 2316 SELECT 2296 2317 WHEN p_share == '' & p_server \= '' THEN DO /* all shares on server */ 2297 IF p_domain == '' THEN 2318 IF p_domain == '' THEN 2298 2319 userdata = userdata';\\'p_server'\*' 2299 2320 ELSE … … 2305 2326 userdata = userdata';*:\\*' 2306 2327 OTHERWISE DO 2307 IF p_domain == '' THEN 2328 IF p_domain == '' THEN 2308 2329 userdata = userdata';\\'p_server'\'p_share 2309 2330 ELSE … … 2319 2340 /*:VRX PB_ADVANCED_Click 2320 2341 */ 2321 PB_ADVANCED_Click: 2342 PB_ADVANCED_Click: 2322 2343 adv_changed = 0 2323 2344 CALL VRLoadSecondary "SW_ADVANCED", "W" … … 2332 2353 /*:VRX PB_ADVCANCEL_Click 2333 2354 */ 2334 PB_ADVCANCEL_Click: 2355 PB_ADVCANCEL_Click: 2335 2356 2336 2357 adv_changed = 0 … … 2341 2362 /*:VRX PB_ADVHELP_Click 2342 2363 */ 2343 PB_ADVHELP_Click: 2364 PB_ADVHELP_Click: 2344 2365 CALL VRMethod 'SW_ADVANCED', 'InvokeHelp' 2345 2366 return … … 2347 2368 /*:VRX PB_ADVOK_Click 2348 2369 */ 2349 PB_ADVOK_Click: 2370 PB_ADVOK_Click: 2350 2371 2351 2372 adv_memlen = VRGet( "SPB_MEMLEN", "Value" ) … … 2388 2409 /*:VRX PB_CLOSE_Click 2389 2410 */ 2390 PB_CLOSE_Click: 2411 PB_CLOSE_Click: 2391 2412 CALL Quit 2392 2413 return … … 2394 2415 /*:VRX PB_CONDET_LOAD_Click 2395 2416 */ 2396 PB_CONDET_LOAD_Click: 2417 PB_CONDET_LOAD_Click: 2397 2418 IF options.!debug == 1 THEN SAY time()' '||"PB_REFRESH_Click started" 2398 2419 call PB_LOAD_CLICK … … 2405 2426 IF options.!debug == 1 THEN SAY time()' '||"PB_CONDET_SAVE_Click started" 2406 2427 2407 if options.!autostart == 0 THEN filename = VRFileDialog('Main', NLVGetMessage( 50 ), 'S', '*.'fs.!profileext) 2428 if options.!autostart == 0 THEN filename = VRFileDialog('Main', NLVGetMessage( 50 ), 'S', '*.'fs.!profileext) 2408 2429 ELSE filename = Profile 2409 2430 … … 2458 2479 p_share = '' 2459 2480 2460 ok = VRMethod( "CN_SMBTREE", "GetRecordList", "Selected", "handle." ) 2481 ok = VRMethod( "CN_SMBTREE", "GetRecordList", "Selected", "handle." ) 2461 2482 2462 2483 say "handle.0="handle.0 … … 2542 2563 2543 2564 do while parTrgRH <> "" 2544 partrgCapt = VRMethod(trgCtn, "GetRecordAttr", partrgRH, "Caption") 2565 partrgCapt = VRMethod(trgCtn, "GetRecordAttr", partrgRH, "Caption") 2545 2566 TargetString = partrgCapt||'\'||TargetString 2546 2567 parTrgRH = VRMethod(trgCtn, "GetRecordAttr", partrgRH , "Parent") … … 2573 2594 btns.2 = NLVGetMessage( 7 ) 2574 2595 confirm = VRMessage('Main', NLVGetMessage( 58, drive ), NLVGetMessage( 8 ), 'Q', 'btns.', 1, 2 ) 2575 IF confirm \= 1 THEN RETURN 2596 IF confirm \= 1 THEN RETURN 2576 2597 2577 2598 /* TODO: ?? Unmount & delete all child mountpoints? */ … … 2596 2617 /*:VRX PB_EDITCANCEL_Click 2597 2618 */ 2598 PB_EDITCANCEL_Click: 2619 PB_EDITCANCEL_Click: 2599 2620 options.!editmode = 0 2600 2621 CALL VRSet "PB_UNMOUNT","Enabled", 1 … … 2608 2629 /*:VRX PB_HELP_Click 2609 2630 */ 2610 PB_HELP_Click: 2631 PB_HELP_Click: 2611 2632 CALL VRMethod 'Main', 'InvokeHelp' 2612 2633 return … … 2614 2635 /*:VRX PB_INFO_OK_Click 2615 2636 */ 2616 PB_INFO_OK_Click: 2637 PB_INFO_OK_Click: 2617 2638 call SW_INFO_Close 2618 2639 RETURN … … 2622 2643 PB_LOAD_Click: PROCEDURE EXPOSE settings. options. advanced. vfs. Profile fs. cd. samba. 2623 2644 IF options.!autoload == 1 then filename = Profile 2624 else filename = VRFileDialog('Main', NLVGetMessage( 55 ), 'L', '*.'fs.!profileext) 2645 else filename = VRFileDialog('Main', NLVGetMessage( 55 ), 'L', '*.'fs.!profileext) 2625 2646 IF filename == '' THEN RETURN 2626 2647 IF STREAM( filename, 'C', 'QUERY EXISTS') == '' THEN DO … … 2666 2687 options.!loglevel = loglevel 2667 2688 2668 IF rwFlag == 'R' THEN 2689 IF rwFlag == 'R' THEN 2669 2690 options.!readonly = 1 2670 2691 ELSE … … 2683 2704 /*:VRX PB_LOGIN_CANCEL_Click 2684 2705 */ 2685 PB_LOGIN_CANCEL_Click: 2706 PB_LOGIN_CANCEL_Click: 2686 2707 call SW_LOGIN_Close 2687 2708 RETURN 0 … … 2689 2710 /*:VRX PB_LOGIN_OK_Click 2690 2711 */ 2691 PB_LOGIN_OK_Click: 2712 PB_LOGIN_OK_Click: 2692 2713 ok = VRSet("EF_USER","Value",VRGet("EF_USER1","Value")) 2693 2714 ok = VRSet("EF_PASSWORD","Value",VRGet("EF_PASSWORD1","Value")) … … 2698 2719 /*:VRX PB_MOUNT_Click 2699 2720 */ 2700 PB_MOUNT_Click: 2721 PB_MOUNT_Click: 2701 2722 IF options.!debug == 1 THEN SAY time()' '||"PB_MOUNT_Click started" 2702 2723 say "network = "network … … 2741 2762 2742 2763 /* The required/optional/ignored parameters depend on the type of mount 2743 * requested. (Note, however, that the user, password, easupport and 2764 * requested. (Note, however, that the user, password, easupport and 2744 2765 * memlen parameters are always optional.) 2745 2766 */ 2746 2767 SELECT 2747 2768 /* Scenario 1: Mount a single share. 2748 * Required: share, server 2769 * Required: share, server 2749 2770 * Optional: workgroup 2750 2771 * Unused: master, mastertype … … 2761 2782 2762 2783 /* Scenario 2: Mount all shares on a server. 2763 * Required: server 2784 * Required: server 2764 2785 * Optional: workgroup 2765 2786 * Unused: share, master, mastertype 2766 2787 */ 2767 WHEN stype = 2 THEN DO 2788 WHEN stype = 2 THEN DO 2768 2789 IF server == '' THEN DO 2769 2790 /* error */ … … 2779 2800 * Unused: share, server, master, mastertype 2780 2801 */ 2781 WHEN stype = 3 THEN DO 2802 WHEN stype = 3 THEN DO 2782 2803 IF workgroup == '' THEN DO 2783 2804 /* error */ … … 2792 2813 * Unused: share, server, workgroup 2793 2814 */ 2794 WHEN stype = 4 THEN DO 2815 WHEN stype = 4 THEN DO 2795 2816 IF master == '' | mastertype == '' THEN DO 2796 2817 /* error */ … … 2810 2831 CALL Mount 2811 2832 CALL Refresh 2812 IF options.!debug == 1 THEN SAY time()' '||"PB_MOUNT_Click done" 2833 IF options.!debug == 1 THEN SAY time()' '||"PB_MOUNT_Click done" 2813 2834 RETURN 0 2814 2835 2815 2836 /*:VRX PB_NEWMOUNTPOINTCANCEL_Click 2816 2837 */ 2817 PB_NEWMOUNTPOINTCANCEL_Click: 2818 ok = VRSet("CB_DRIVES","Value","") 2819 ok = VRSet("EF_DIRECTORY","Value","") 2838 PB_NEWMOUNTPOINTCANCEL_Click: 2839 ok = VRSet("CB_DRIVES","Value","") 2840 ok = VRSet("EF_DIRECTORY","Value","") 2820 2841 call SW_MOUNTPOINT_Close 2821 2842 RETURN 0 … … 2823 2844 /*:VRX PB_NEWMOUNTPOINTOK_Click 2824 2845 */ 2825 PB_NEWMOUNTPOINTOK_Click: 2846 PB_NEWMOUNTPOINTOK_Click: 2826 2847 ok = VRSet("CB_DRIVES","Value",VRGet("CB_DRIVES1","Value")) 2827 2848 ok = VRSet("EF_DIRECTORY","Value",VRGet("EF_DIRECTORY1","Value")) … … 2836 2857 /*:VRX PB_PROGRESS_ABORT_Click 2837 2858 */ 2838 PB_PROGRESS_ABORT_Click: 2859 PB_PROGRESS_ABORT_Click: 2839 2860 options.!autoload = 0 2840 2861 options.!autoclose = 0 … … 2863 2884 call PB_CONDET_SAVE_Click 2864 2885 2865 /* if options.!autostart == 0 THEN filename = VRFileDialog('Main', NLVGetMessage( 50 ), 'S', '*.'fs.!profileext) 2886 /* if options.!autostart == 0 THEN filename = VRFileDialog('Main', NLVGetMessage( 50 ), 'S', '*.'fs.!profileext) 2866 2887 ELSE filename = Profile 2867 2888 … … 2886 2907 IF options.!debug == 1 THEN SAY time()' '||dyn 2887 2908 interpret dyn; drop dyn 2888 2909 2889 2910 IF ok \= 0 THEN ITERATE 2890 2911 … … 2902 2923 /*:VRX PB_SETTINGS_CANCEL_Click 2903 2924 */ 2904 PB_SETTINGS_CANCEL_Click: 2925 PB_SETTINGS_CANCEL_Click: 2905 2926 2906 2927 adv_changed = 0 … … 2911 2932 /*:VRX PB_SETTINGS_HELP_Click 2912 2933 */ 2913 PB_SETTINGS_HELP_Click: 2934 PB_SETTINGS_HELP_Click: 2914 2935 CALL VRMethod 'SW_SETTINGS', 'InvokeHelp' 2915 2936 return … … 2917 2938 /*:VRX PB_SETTINGS_OK_Click 2918 2939 */ 2919 PB_SETTINGS_OK_Click: 2940 PB_SETTINGS_OK_Click: 2920 2941 2921 2942 adv_loglevel = VRGet( "SPIN_LOGLEVEL", "Value" ) … … 2952 2973 btns.2 = NLVGetMessage( 7 ) 2953 2974 confirm = VRMessage('Main', NLVGetMessage( 57, mountpoint ), NLVGetMessage( 8 ), 'Q', 'btns.', 1, 2 ) 2954 IF confirm \= 1 THEN RETURN 2975 IF confirm \= 1 THEN RETURN 2955 2976 END 2956 2977 … … 2960 2981 IF options.!debug == 1 THEN SAY time()' '||dyn 2961 2982 interpret dyn; drop dyn 2962 2983 2963 2984 /* IF options.!debug == 1 THEN SAY time()' '||'Unmount resource' i-1 '=' ok */ 2964 2985 END … … 2970 2991 IF options.!debug == 1 THEN SAY time()' '||dyn 2971 2992 interpret dyn; drop dyn 2972 2993 2973 2994 /* IF options.!debug == 1 THEN SAY time()' '||'Delete mountpoint' mountpoint '=' ok */ 2974 2995 END … … 2991 3012 /*:VRX Refresh 2992 3013 */ 2993 Refresh: 3014 Refresh: 2994 3015 IF options.!debug == 1 THEN SAY time()' Refresh started' 2995 3016 CALL VRMethod 'CN_CURRENT', 'RemoveRecord', 'All' 2996 3017 2997 3018 /* Remove Active connections from details view */ 2998 ok = VRMethod( 'CN_CONDET', "GetRecordList", 'All', "rh." ) 3019 ok = VRMethod( 'CN_CONDET', "GetRecordList", 'All', "rh." ) 2999 3020 3000 3021 do I = 1 to rh.0 … … 3011 3032 3012 3033 /* call _AddTemplates */ 3013 CALL VRSet "PB_DETACH", "Enabled", 0 3014 CALL VRSet "PB_UNMOUNT", "Enabled", 0 3034 CALL VRSet "PB_DETACH", "Enabled", 0 3035 CALL VRSet "PB_UNMOUNT", "Enabled", 0 3015 3036 3016 3037 ok = VRSet("Menu_Context_Detach", "Visible", 0) … … 3022 3043 3023 3044 IF options.!debug == 1 THEN SAY ' Remove records, disable buttons done.' 3024 3025 CALL VRMethod 'CB_DRIVES', 'Clear' 3026 3045 3046 CALL VRMethod 'CB_DRIVES', 'Clear' 3047 3027 3048 /* Herwig B. 3028 3049 CALL VRSet 'Main', 'StatusText', ' ' */ … … 3051 3072 IF options.!debug == 1 THEN SAY time()' '||"SaveSettings started" 3052 3073 3053 if advanced.!savepassive then call _PassiveSave 3054 3055 /* This does not make sense anymore 3074 if advanced.!savepassive then call _PassiveSave 3075 3076 /* This does not make sense anymore 3056 3077 settings.!network = VRGet("EF_NETWORK","Value") 3057 3078 CALL VRSetIni 'Settings', 'Network', settings.!network, settings.!ini, 'NoClose' … … 3109 3130 /*:VRX SPLIT_Main_Move 3110 3131 */ 3111 SPLIT_Main_Move: 3132 SPLIT_Main_Move: 3112 3133 ok = VRset("Main", "Painting", 0) 3113 3134 NewPos = VRInfo("Left") … … 3121 3142 /*:VRX StemsInit 3122 3143 */ 3123 StemsInit: 3144 StemsInit: 3124 3145 options.!workgroup = '' 3125 3146 options.!server = '' … … 3167 3188 /*:VRX SW_ADVANCED_Close 3168 3189 */ 3169 SW_ADVANCED_Close: 3190 SW_ADVANCED_Close: 3170 3191 call SW_ADVANCED_Fini 3171 3192 return … … 3173 3194 /*:VRX SW_ADVANCED_Create 3174 3195 */ 3175 SW_ADVANCED_Create: 3196 SW_ADVANCED_Create: 3176 3197 call SW_ADVANCED_Init 3177 3198 return … … 3179 3200 /*:VRX SW_ADVANCED_Fini 3180 3201 */ 3181 SW_ADVANCED_Fini: 3202 SW_ADVANCED_Fini: 3182 3203 window = VRInfo( "Window" ) 3183 3204 call VRDestroy window … … 3186 3207 /*:VRX SW_ADVANCED_Init 3187 3208 */ 3188 SW_ADVANCED_Init: 3189 3209 SW_ADVANCED_Init: 3210 3190 3211 CALL NLVSetText 'SW_ADVANCED', 'Caption', 40 3191 3212 CALL NLVSetText 'GB_MISC', 'Caption', 43 … … 3204 3225 CALL NLVSetText 'GB_MEM', 'Caption', 41 3205 3226 3206 IF advanced.!memlen \= '' THEN 3227 IF advanced.!memlen \= '' THEN 3207 3228 CALL VRSet 'SPB_MEMLEN', 'Value', advanced.!memlen 3208 3229 IF advanced.!easupport \= '' THEN … … 3210 3231 IF advanced.!readonly \= '' THEN 3211 3232 CALL VRSet 'CB_READONLY', 'Set', advanced.!readonly 3212 IF advanced.!alwaysmp \= '' THEN 3233 IF advanced.!alwaysmp \= '' THEN 3213 3234 CALL VRSet 'CB_alwaysmp', 'Set', advanced.!alwaysmp 3214 3235 … … 3224 3245 /*:VRX SW_INFO_Close 3225 3246 */ 3226 SW_INFO_Close: 3247 SW_INFO_Close: 3227 3248 call SW_INFO_Fini 3228 3249 return … … 3230 3251 /*:VRX SW_INFO_Create 3231 3252 */ 3232 SW_INFO_Create: 3253 SW_INFO_Create: 3233 3254 call SW_INFO_Init 3234 3255 CALL NLVSetText 'SW_INFO', 'Caption', 92 … … 3238 3259 Info.ValueFH = VRMethod( "CN_INFO", "AddField", "String", "Value" ) 3239 3260 3240 parse var infoline "Domain=["WorkGroup"] OS=["OS"] Server=["Server"]"Rest 3261 parse var infoline "Domain=["WorkGroup"] OS=["OS"] Server=["Server"]"Rest 3241 3262 Info.!domain = VRMethod( "CN_INFO", "AddRecord") 3242 3263 ok = VRMethod( "CN_INFO", "SetFieldData", Info.!domain, Info.TypeFH, strip(NLVGetMessage(21),'T',':'),Info.ValueFH, Workgroup ) … … 3253 3274 /*:VRX SW_INFO_Fini 3254 3275 */ 3255 SW_INFO_Fini: 3276 SW_INFO_Fini: 3256 3277 window = VRInfo( "Window" ) 3257 3278 call VRDestroy window … … 3260 3281 /*:VRX SW_INFO_Init 3261 3282 */ 3262 SW_INFO_Init: 3283 SW_INFO_Init: 3263 3284 window = VRInfo( "Object" ) 3264 3285 if( \VRIsChildOf( window, "Notebook" ) ) then do … … 3272 3293 /*:VRX SW_LOGIN_Close 3273 3294 */ 3274 SW_LOGIN_Close: 3295 SW_LOGIN_Close: 3275 3296 call SW_LOGIN_Fini 3276 3297 return … … 3278 3299 /*:VRX SW_LOGIN_Create 3279 3300 */ 3280 SW_LOGIN_Create: 3301 SW_LOGIN_Create: 3281 3302 call SW_LOGIN_Init 3282 3303 CALL NLVSetText 'DT_USER1', 'Caption', 25 … … 3290 3311 /*:VRX SW_LOGIN_Fini 3291 3312 */ 3292 SW_LOGIN_Fini: 3313 SW_LOGIN_Fini: 3293 3314 window = VRInfo( "Window" ) 3294 3315 call VRDestroy window … … 3297 3318 /*:VRX SW_LOGIN_Init 3298 3319 */ 3299 SW_LOGIN_Init: 3320 SW_LOGIN_Init: 3300 3321 window = VRInfo( "Object" ) 3301 3322 if( \VRIsChildOf( window, "Notebook" ) ) then do … … 3309 3330 /*:VRX SW_LOGIN_KeyPress 3310 3331 */ 3311 SW_LOGIN_KeyPress: 3332 SW_LOGIN_KeyPress: 3312 3333 obj = VRInfo( "Object" ) 3313 3334 keystr = VRGet( obj, "KeyString" ) 3314 3335 /* say keystr */ 3315 select 3316 when keystr = "{Enter}" then ok = VRMethod( "EF_LoginPassword", "SetFocus" ) 3317 when keystr = "{Newline}" then ok = VRMethod( "EF_LoginPassword", "SetFocus" ) 3336 select 3337 when keystr = "{Enter}" then ok = VRMethod( "EF_LoginPassword", "SetFocus" ) 3338 when keystr = "{Newline}" then ok = VRMethod( "EF_LoginPassword", "SetFocus" ) 3318 3339 when keystr = "{Esc}" then call PB_LOGIN_CANCEL_Click 3319 3340 otherwise nop … … 3323 3344 /*:VRX SW_MOUNTPOINT_Close 3324 3345 */ 3325 SW_MOUNTPOINT_Close: 3346 SW_MOUNTPOINT_Close: 3326 3347 call SW_MOUNTPOINT_Fini 3327 3348 return … … 3329 3350 /*:VRX SW_MOUNTPOINT_Create 3330 3351 */ 3331 SW_MOUNTPOINT_Create: 3352 SW_MOUNTPOINT_Create: 3332 3353 call SW_MOUNTPOINT_Init 3333 3354 /* NLVGetMessage(14)' ' */ … … 3339 3360 CALL NLVSetText 'CB_READONLY1', 'Caption', 45 3340 3361 CALL NLVSetText 'CB_ALWAYSMP1', 'Caption', 65 3341 ok = VRMethod( "CB_DRIVES", "GetStringList", "freedrives." ) 3362 ok = VRMethod( "CB_DRIVES", "GetStringList", "freedrives." ) 3342 3363 ok = VRMethod( "CB_DRIVES1", "AddStringList", "freedrives." ) 3343 3364 ok = VRSet("CB_DRIVES1", "Value", VRGet("CB_Drives","Value")) … … 3349 3370 /*:VRX SW_MOUNTPOINT_Fini 3350 3371 */ 3351 SW_MOUNTPOINT_Fini: 3372 SW_MOUNTPOINT_Fini: 3352 3373 window = VRInfo( "Window" ) 3353 3374 call VRDestroy window … … 3356 3377 /*:VRX SW_MOUNTPOINT_Init 3357 3378 */ 3358 SW_MOUNTPOINT_Init: 3379 SW_MOUNTPOINT_Init: 3359 3380 window = VRInfo( "Object" ) 3360 3381 if( \VRIsChildOf( window, "Notebook" ) ) then do … … 3368 3389 /*:VRX SW_PROGRESS_Close 3369 3390 */ 3370 SW_PROGRESS_Close: 3391 SW_PROGRESS_Close: 3371 3392 call SW_PROGRESS_Fini 3372 3393 return … … 3374 3395 /*:VRX SW_PROGRESS_Create 3375 3396 */ 3376 SW_PROGRESS_Create: 3397 SW_PROGRESS_Create: 3377 3398 call SW_PROGRESS_Init 3378 3399 CALL NLVSetText 'SW_PROGRESS', 'Caption', 1 … … 3383 3404 /*:VRX SW_PROGRESS_Fini 3384 3405 */ 3385 SW_PROGRESS_Fini: 3406 SW_PROGRESS_Fini: 3386 3407 window = VRInfo( "Window" ) 3387 3408 call VRDestroy window … … 3390 3411 /*:VRX SW_PROGRESS_Init 3391 3412 */ 3392 SW_PROGRESS_Init: 3413 SW_PROGRESS_Init: 3393 3414 window = VRInfo( "Object" ) 3394 3415 if( \VRIsChildOf( window, "Notebook" ) ) then do … … 3402 3423 /*:VRX SW_SETTINGS_Close 3403 3424 */ 3404 SW_SETTINGS_Close: 3425 SW_SETTINGS_Close: 3405 3426 call SW_SETTINGS_Fini 3406 3427 return … … 3408 3429 /*:VRX SW_SETTINGS_Create 3409 3430 */ 3410 SW_SETTINGS_Create: 3431 SW_SETTINGS_Create: 3411 3432 call SW_SETTINGS_Init 3412 3433 return … … 3414 3435 /*:VRX SW_SETTINGS_Fini 3415 3436 */ 3416 SW_SETTINGS_Fini: 3437 SW_SETTINGS_Fini: 3417 3438 window = VRInfo( "Window" ) 3418 3439 call VRDestroy window … … 3421 3442 /*:VRX SW_SETTINGS_Init 3422 3443 */ 3423 SW_SETTINGS_Init: 3444 SW_SETTINGS_Init: 3424 3445 3425 3446 CALL NLVSetText 'SW_SETTINGS', 'Caption', 47 … … 3445 3466 CALL VRSet 'SPIN_LOGLEVEL', 'Value', advanced.!loglevel 3446 3467 CALL VRSet 'CB_LOGGING', 'Set', VRFileExists(SysBootDrive()'\ndpsmb.dbg') 3447 IF advanced.!browseauth \= '' THEN 3468 IF advanced.!browseauth \= '' THEN 3448 3469 CALL VRSet 'CB_BROWSEAUTH', 'Set', advanced.!browseauth 3449 IF advanced.!browseimme \= '' THEN 3470 IF advanced.!browseimme \= '' THEN 3450 3471 CALL VRSet 'CB_BROWSEimme', 'Set', advanced.!browseimme 3451 IF advanced.!debug \= '' THEN 3472 IF advanced.!debug \= '' THEN 3452 3473 CALL VRSet 'CB_debug', 'Set', advanced.!debug 3453 3474 IF advanced.!special \= '' THEN … … 3469 3490 /*:VRX TM_AutoClose_Trigger 3470 3491 */ 3471 TM_AutoClose_Trigger: 3492 TM_AutoClose_Trigger: 3472 3493 call PB_CLOSE_Click 3473 3494 return … … 3475 3496 /*:VRX TM_RefreshTreeDisplay_Trigger 3476 3497 */ 3477 TM_RefreshTreeDisplay_Trigger: 3498 TM_RefreshTreeDisplay_Trigger: 3478 3499 ShowHidden = advanced.!special 3479 3500 BroadCast = advanced.!broadcast 3480 3501 3481 select 3502 select 3482 3503 when RefreshMode = "TREE" then do 3483 3504 call _RefreshTreeDisplay 3484 3505 3485 3506 if VRget("Menu_View_SmbTree", "Checked") then do 3486 3507 if smbtree.!workgroup <> 'SMBTREE.!WORKGROUP' then do … … 3490 3511 end 3491 3512 when RefreshMode = "SHARE" then do 3492 call _AddSharesDisplay 3513 call _AddSharesDisplay 3493 3514 end 3494 3515 otherwise say "RefreshMode = "RefreshMode … … 3499 3520 /*:VRX TM_TheCloser_Trigger 3500 3521 */ 3501 TM_TheCloser_Trigger: 3522 TM_TheCloser_Trigger: 3502 3523 call SW_PROGRESS_Close 3503 3524 return … … 3505 3526 /*:VRX TM_Throbber_Trigger 3506 3527 */ 3507 TM_Throbber_Trigger: 3528 TM_Throbber_Trigger: 3508 3529 pIdx = VRGet("Pict_Throbber","PicturePath") 3509 3530 parse var pIdx '#' pidx
Note:
See TracChangeset
for help on using the changeset viewer.