Changeset 1128
- Timestamp:
- Aug 29, 2008, 4:03:23 PM (17 years ago)
- Location:
- trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/cfgmgr.cmd
r1125 r1128 14 14 /UNATTENDED 15 15 Runs without user interaction/confirmation 16 17 /TOOLBARSONLY 18 Process toolbar-related files only 16 19 17 20 If CFGMGR.CMD is run without parameters, it will install a default … … 56 59 if cfg.operation = 'INSTALL' then 57 60 if file_exists \= '' then 58 do 59 if cfg.defaults = 1 then 60 if FilesAreDifferent(cfg.file.f.default, cfg.file.f.name) = 1 then 61 do 62 if cfg.unattended = 0 then 63 do 64 user_choice = PromptForReplaceOption(f) 65 if user_choice == 'Q' then 66 signal NormalExit 67 if user_choice == 'N' then 68 iterate 69 end 70 /* unattended = 1 or user_choice = 'Y' */ 71 cfg.errorcode = CfgAction( 'RESETTODEFAULT', f ) 72 end 61 if (cfg.toolbarsonly = 0 | cfg.file.f.toolbar = 1) then 62 do 63 if cfg.defaults = 1 then 64 if FilesAreDifferent(cfg.file.f.default, cfg.file.f.name) = 1 then 65 do 66 if cfg.unattended = 0 then 67 do 68 user_choice = PromptForReplaceOption(f) 69 if user_choice == 'Q' then 70 signal NormalExit 71 if user_choice == 'N' then 72 iterate 73 end 74 /* unattended = 1 or user_choice = 'Y' */ 75 cfg.errorcode = CfgAction( 'RESETTODEFAULT', f ) 76 end 77 else 78 nop 73 79 else 74 nop75 else76 if (cfg.file.f.toolbar = 1) & (cfg.unattended = 1) then77 call Ticket267Fix cfg.file.f.name78 end80 if (cfg.file.f.toolbar = 1) & (cfg.unattended = 1) then 81 call Ticket267Fix cfg.file.f.name 82 end 83 else 84 nop 79 85 else 80 86 cfg.errorcode = CfgAction( 'INSTALLDEFAULT', f ) … … 166 172 cfg.defaults = 0 167 173 cfg.unattended = 0 174 cfg.toolbarsonly = 0 168 175 cfg.actionmethod = 'COPY' /* The default method of backing up and restoring */ 169 176 cfg.backupdir = '.\User_Config_Backup' … … 323 330 when param = '/DEFAULTS' then 324 331 cfg.defaults = 1 332 when param = '/TOOLBARSONLY' then 333 cfg.toolbarsonly = 1 325 334 otherwise 326 335 cfg.errorcode = 2 … … 570 579 call SysIni inifile, 'FM/3', 'LastToolbar', LastToolbar 571 580 end 572 if SysIni(inifile, 'FM/3', 'FM2Shu down.Toolbar') = 'ERROR:' then581 if SysIni(inifile, 'FM/3', 'FM2Shutdown.Toolbar') = 'ERROR:' then 573 582 call SysIni inifile, 'FM/3', 'FM2Shutdown.Toolbar', LastToolbar 583 if SysIni(inifile, 'FM/4', 'Toolbar') = 'ERROR:' then 584 call SysIni inifile, 'FM/4', 'Toolbar', LastToolbar 574 585 return 575 586 -
trunk/dll/mainwnd.c
r1125 r1128 67 67 19 Jul 08 GKY Replace save_dir2(dir) with pFM2SaveDirectory 68 68 26 Aug 08 GKY Require unique ID plus text and help strings for all tools save toolbar on button delete 69 27 Aug 08 JBS Ticket 259: Support saving/restoring toolbars with states 70 29 Aug 08 JBS Ticket 259: Support saving/restoring target directories with states (except the shutdown state) 69 71 70 72 ***********************************************************************/ … … 2839 2841 sprintf(szPrefix, "%s.", pszStateName); 2840 2842 2841 sprintf(szKey, "%sToolbar", szPrefix); 2842 PrfWriteProfileString(fmprof, FM3Str, szKey, lasttoolbar); 2843 if (*lasttoolbar) { 2844 sprintf(szKey, "%sToolbar", szPrefix); 2845 PrfWriteProfileString(fmprof, FM3Str, szKey, lasttoolbar); 2846 } 2847 2848 if (*targetdir && !fIsShutDownState) { 2849 sprintf(szKey, "%sTargetDir", szPrefix); 2850 PrfWriteProfileString(fmprof, FM3Str, szKey, targetdir); 2851 } 2843 2852 2844 2853 henum = WinBeginEnumWindows(hwndClient); … … 3078 3087 load_tools(NULL); 3079 3088 PostMsg(hwndToolback, UM_SETUP2, MPVOID, MPVOID); 3089 } 3090 size = (ULONG)0; 3091 sprintf(szKey, "%sTargetDir", szPrefix); 3092 if (PrfQueryProfileSize(fmprof, FM3Str, szKey, &size) && size) 3093 { 3094 PrfQueryProfileData(fmprof, FM3Str, szKey, targetdir, &size); 3095 PrfWriteProfileString(fmprof, FM3Str, "TargetDir", targetdir); 3096 SetTargetDir(NULL, TRUE); 3080 3097 } 3081 3098 size = sizeof(SWP); -
trunk/dll/mainwnd2.c
r1125 r1128 24 24 14 Feb 08 SHL Rework to support settings menu conditional cascade 25 25 29 Feb 08 GKY Use xfree where appropriate 26 27 Aug 08 JBS Ticket 259: Support saving/restoring toolbars with states 26 27 27 28 ***********************************************************************/ … … 702 703 strcpy(lasttoolbar, 703 704 quicktool[SHORT1FROMMP(mp1) - IDM_QUICKTOOLSTART]); 704 PrfWriteProfileString(fmprof, FM3Str, "LastToolbar", lasttoolbar); 705 // PrfWriteProfileString(fmprof, FM3Str, "LastToolbar", lasttoolbar); 706 PrfWriteProfileString(fmprof, appname, "LastToolbar", lasttoolbar); 705 707 } 706 708 PostMsg(hwndToolback, UM_SETUP2, MPVOID, MPVOID);
Note:
See TracChangeset
for help on using the changeset viewer.