Loweynet
Revision | 958645db907a83aeac5b3f888b1652c4720cf36d (tree) |
---|---|
Time | 2014-10-31 19:52:54 |
Author | s_kawamoto <s_kawamoto@user...> |
Commiter | s_kawamoto |
Add option to change default host settings.
Modify documents.
Rename resource files.
@@ -28,7 +28,7 @@ | ||
28 | 28 | > |
29 | 29 | <Tool |
30 | 30 | Name="VCPreBuildEventTool" |
31 | - CommandLine="utf8msg.exe mesg-eng.h mesg-eng.h
cscript //nologo ReplaceAfxresh.js Resource_eng\FFFTP-eng.rc Resource_eng\FFFTP-eng._replaced_.rc
" | |
31 | + CommandLine="utf8msg.exe mesg-eng.h mesg-eng.h
cscript //nologo ReplaceAfxresh.js Resource_eng\ffftp.rc Resource_eng\ffftp._replaced_.rc
" | |
32 | 32 | /> |
33 | 33 | <Tool |
34 | 34 | Name="VCCustomBuildTool" |
@@ -122,7 +122,7 @@ | ||
122 | 122 | > |
123 | 123 | <Tool |
124 | 124 | Name="VCPreBuildEventTool" |
125 | - CommandLine="utf8msg.exe mesg-eng.h mesg-eng.h
cscript //nologo ReplaceAfxresh.js Resource_eng\FFFTP-eng.rc Resource_eng\FFFTP-eng._replaced_.rc
" | |
125 | + CommandLine="utf8msg.exe mesg-eng.h mesg-eng.h
cscript //nologo ReplaceAfxresh.js Resource_eng\ffftp.rc Resource_eng\ffftp._replaced_.rc
" | |
126 | 126 | /> |
127 | 127 | <Tool |
128 | 128 | Name="VCCustomBuildTool" |
@@ -216,7 +216,7 @@ | ||
216 | 216 | > |
217 | 217 | <Tool |
218 | 218 | Name="VCPreBuildEventTool" |
219 | - CommandLine="utf8msg.exe mesg-eng.h mesg-eng.h
cscript //nologo ReplaceAfxresh.js Resource_eng\FFFTP-eng.rc Resource_eng\FFFTP-eng._replaced_.rc
" | |
219 | + CommandLine="utf8msg.exe mesg-eng.h mesg-eng.h
cscript //nologo ReplaceAfxresh.js Resource_eng\ffftp.rc Resource_eng\ffftp._replaced_.rc
" | |
220 | 220 | /> |
221 | 221 | <Tool |
222 | 222 | Name="VCCustomBuildTool" |
@@ -309,7 +309,7 @@ | ||
309 | 309 | > |
310 | 310 | <Tool |
311 | 311 | Name="VCPreBuildEventTool" |
312 | - CommandLine="utf8msg.exe mesg-eng.h mesg-eng.h
cscript //nologo ReplaceAfxresh.js Resource_eng\FFFTP-eng.rc Resource_eng\FFFTP-eng._replaced_.rc
" | |
312 | + CommandLine="utf8msg.exe mesg-eng.h mesg-eng.h
cscript //nologo ReplaceAfxresh.js Resource_eng\ffftp.rc Resource_eng\ffftp._replaced_.rc
" | |
313 | 313 | /> |
314 | 314 | <Tool |
315 | 315 | Name="VCCustomBuildTool" |
@@ -448,11 +448,11 @@ | ||
448 | 448 | > |
449 | 449 | </File> |
450 | 450 | <File |
451 | - RelativePath=".\Resource_eng\FFFTP-eng._replaced_.rc" | |
451 | + RelativePath=".\Resource_eng\ffftp._replaced_.rc" | |
452 | 452 | > |
453 | 453 | </File> |
454 | 454 | <File |
455 | - RelativePath=".\Resource_eng\FFFTP-eng.rc" | |
455 | + RelativePath=".\Resource_eng\ffftp.rc" | |
456 | 456 | > |
457 | 457 | <FileConfiguration |
458 | 458 | Name="Debug|Win32" |
@@ -445,7 +445,7 @@ | ||
445 | 445 | > |
446 | 446 | </File> |
447 | 447 | <File |
448 | - RelativePath=".\Resource_eng\FFFTP-eng.rc" | |
448 | + RelativePath=".\Resource_eng\ffftp.rc" | |
449 | 449 | > |
450 | 450 | </File> |
451 | 451 | <File |
@@ -448,7 +448,7 @@ | ||
448 | 448 | > |
449 | 449 | </File> |
450 | 450 | <File |
451 | - RelativePath=".\Resource_eng\FFFTP-eng.rc" | |
451 | + RelativePath=".\Resource_eng\ffftp.rc" | |
452 | 452 | > |
453 | 453 | </File> |
454 | 454 | <File |
@@ -296,14 +296,14 @@ BEGIN | ||
296 | 296 | LTEXT "ðíµÜ·©H",-1,17,21,167,8 |
297 | 297 | END |
298 | 298 | |
299 | -hostlist_dlg DIALOG 0, 0, 232, 120 | |
299 | +hostlist_dlg DIALOG 0, 0, 232, 136 | |
300 | 300 | STYLE DS_LOCALEDIT | DS_SETFONT | WS_POPUP | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU | WS_THICKFRAME |
301 | 301 | CAPTION "zXgê" |
302 | 302 | FONT 9, "MS Shell Dlg" |
303 | 303 | BEGIN |
304 | - CONTROL "Tree1",HOST_LIST,"SysTreeView32",TVS_HASLINES | TVS_DISABLEDRAGDROP | TVS_SHOWSELALWAYS | TVS_FULLROWSELECT | WS_BORDER | WS_TABSTOP,7,6,152,89 | |
305 | - DEFPUSHBUTTON "Ú±(&S)",IDOK,27,102,50,14 | |
306 | - PUSHBUTTON "妎(&O)",IDCANCEL,91,102,50,14 | |
304 | + CONTROL "Tree1",HOST_LIST,"SysTreeView32",TVS_HASLINES | TVS_DISABLEDRAGDROP | TVS_SHOWSELALWAYS | TVS_FULLROWSELECT | WS_BORDER | WS_TABSTOP,7,6,152,105 | |
305 | + DEFPUSHBUTTON "Ú±(&S)",IDOK,27,118,50,14 | |
306 | + PUSHBUTTON "妎(&O)",IDCANCEL,91,118,50,14 | |
307 | 307 | PUSHBUTTON "VKzXg(&N)...",HOST_NEW,165,6,60,14 |
308 | 308 | PUSHBUTTON "VKO[v(&G)...",HOST_FOLDER,165,22,60,14 |
309 | 309 | PUSHBUTTON "ÝèÏX(&M)...",HOST_SET,165,38,60,14 |
@@ -311,8 +311,9 @@ BEGIN | ||
311 | 311 | PUSHBUTTON "í(&D)...",HOST_DEL,165,70,60,14 |
312 | 312 | PUSHBUTTON "ª",HOST_UP,165,86,14,14 |
313 | 313 | PUSHBUTTON "«",HOST_DOWN,184,86,14,14 |
314 | - SCROLLBAR HOST_SIZEGRIP,222,106,10,13,SBS_BOTTOMALIGN | SBS_VERT | SBS_SIZEGRIP | |
315 | - PUSHBUTTON "wv",9,165,102,60,14 | |
314 | + PUSHBUTTON "ùèÌÝè(&F)...",HOST_SET_DEFAULT,165,102,60,14 | |
315 | + SCROLLBAR HOST_SIZEGRIP,222,122,10,13,SBS_BOTTOMALIGN | SBS_VERT | SBS_SIZEGRIP | |
316 | + PUSHBUTTON "wv",9,165,118,60,14 | |
316 | 317 | END |
317 | 318 | |
318 | 319 | hset_main_dlg DIALOG 0, 0, 207, 155 |
@@ -1536,9 +1537,9 @@ BEGIN | ||
1536 | 1537 | hostlist_dlg, DIALOG |
1537 | 1538 | BEGIN |
1538 | 1539 | LEFTMARGIN, 7 |
1539 | - RIGHTMARGIN, 215 | |
1540 | + RIGHTMARGIN, 225 | |
1540 | 1541 | TOPMARGIN, 6 |
1541 | - BOTTOMMARGIN, 116 | |
1542 | + BOTTOMMARGIN, 132 | |
1542 | 1543 | END |
1543 | 1544 | |
1544 | 1545 | hset_main_dlg, DIALOG |
@@ -468,6 +468,7 @@ | ||
468 | 468 | #define UPDATES_INTERVAL 1224 |
469 | 469 | #define UPDATES_INTERVAL_SPN 1225 |
470 | 470 | #define HSET_NO_WEAK 1226 |
471 | +#define HOST_SET_DEFAULT 1227 | |
471 | 472 | #define MENU_END 40001 |
472 | 473 | #define MENU_EXIT 40001 |
473 | 474 | #define MENU_CONNECT 40003 |
@@ -660,7 +661,7 @@ | ||
660 | 661 | #ifndef APSTUDIO_READONLY_SYMBOLS |
661 | 662 | #define _APS_NEXT_RESOURCE_VALUE 199 |
662 | 663 | #define _APS_NEXT_COMMAND_VALUE 40182 |
663 | -#define _APS_NEXT_CONTROL_VALUE 1227 | |
664 | +#define _APS_NEXT_CONTROL_VALUE 1228 | |
664 | 665 | #define _APS_NEXT_SYMED_VALUE 101 |
665 | 666 | #endif |
666 | 667 | #endif |
@@ -296,23 +296,24 @@ BEGIN | ||
296 | 296 | LTEXT "Delete following file?",-1,7,7,167,8 |
297 | 297 | END |
298 | 298 | |
299 | -hostlist_dlg DIALOG 0, 0, 222, 120 | |
299 | +hostlist_dlg DIALOG 0, 0, 232, 136 | |
300 | 300 | STYLE DS_LOCALEDIT | DS_SETFONT | WS_POPUP | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU | WS_THICKFRAME |
301 | 301 | CAPTION "Host List" |
302 | 302 | FONT 9, "MS Shell Dlg" |
303 | 303 | BEGIN |
304 | - CONTROL "Tree1",HOST_LIST,"SysTreeView32",TVS_HASLINES | TVS_DISABLEDRAGDROP | TVS_SHOWSELALWAYS | TVS_FULLROWSELECT | WS_BORDER | WS_TABSTOP,7,6,152,89 | |
305 | - DEFPUSHBUTTON "&Connect",IDOK,27,102,50,14 | |
306 | - PUSHBUTTON "C&lose",IDCANCEL,91,102,50,14 | |
307 | - PUSHBUTTON "New &Host...",HOST_NEW,165,6,50,14 | |
308 | - PUSHBUTTON "New &Group...",HOST_FOLDER,165,22,50,14 | |
309 | - PUSHBUTTON "&Modify...",HOST_SET,165,38,50,14 | |
310 | - PUSHBUTTON "Co&py",HOST_COPY,165,54,50,14 | |
311 | - PUSHBUTTON "&Delete...",HOST_DEL,165,70,50,14 | |
312 | - PUSHBUTTON "Up",HOST_UP,165,86,22,14 | |
313 | - PUSHBUTTON "Down",HOST_DOWN,193,86,22,14 | |
314 | - SCROLLBAR HOST_SIZEGRIP,212,106,10,13,SBS_BOTTOMALIGN | SBS_VERT | SBS_SIZEGRIP | |
315 | - PUSHBUTTON "Help",9,165,102,50,14 | |
304 | + CONTROL "Tree1",HOST_LIST,"SysTreeView32",TVS_HASLINES | TVS_DISABLEDRAGDROP | TVS_SHOWSELALWAYS | TVS_FULLROWSELECT | WS_BORDER | WS_TABSTOP,7,6,152,105 | |
305 | + DEFPUSHBUTTON "&Connect",IDOK,27,118,50,14 | |
306 | + PUSHBUTTON "C&lose",IDCANCEL,91,118,50,14 | |
307 | + PUSHBUTTON "New &Host...",HOST_NEW,165,6,60,14 | |
308 | + PUSHBUTTON "New &Group...",HOST_FOLDER,165,22,60,14 | |
309 | + PUSHBUTTON "&Modify...",HOST_SET,165,38,60,14 | |
310 | + PUSHBUTTON "Co&py",HOST_COPY,165,54,60,14 | |
311 | + PUSHBUTTON "&Delete...",HOST_DEL,165,70,60,14 | |
312 | + PUSHBUTTON "Up",HOST_UP,165,86,27,14 | |
313 | + PUSHBUTTON "Down",HOST_DOWN,198,86,27,14 | |
314 | + PUSHBUTTON "Modify Def&ault...",HOST_SET_DEFAULT,165,102,60,14 | |
315 | + SCROLLBAR HOST_SIZEGRIP,222,122,10,13,SBS_BOTTOMALIGN | SBS_VERT | SBS_SIZEGRIP | |
316 | + PUSHBUTTON "Help",9,165,118,60,14 | |
316 | 317 | END |
317 | 318 | |
318 | 319 | hset_main_dlg DIALOG 0, 0, 207, 155 |
@@ -1574,9 +1575,9 @@ BEGIN | ||
1574 | 1575 | hostlist_dlg, DIALOG |
1575 | 1576 | BEGIN |
1576 | 1577 | LEFTMARGIN, 7 |
1577 | - RIGHTMARGIN, 215 | |
1578 | + RIGHTMARGIN, 225 | |
1578 | 1579 | TOPMARGIN, 6 |
1579 | - BOTTOMMARGIN, 116 | |
1580 | + BOTTOMMARGIN, 132 | |
1580 | 1581 | END |
1581 | 1582 | |
1582 | 1583 | hset_main_dlg, DIALOG |
@@ -468,6 +468,7 @@ | ||
468 | 468 | #define UPDATES_INTERVAL 1224 |
469 | 469 | #define UPDATES_INTERVAL_SPN 1225 |
470 | 470 | #define HSET_NO_WEAK 1226 |
471 | +#define HOST_SET_DEFAULT 1227 | |
471 | 472 | #define MENU_END 40001 |
472 | 473 | #define MENU_EXIT 40001 |
473 | 474 | #define MENU_CONNECT 40003 |
@@ -660,7 +661,7 @@ | ||
660 | 661 | #ifndef APSTUDIO_READONLY_SYMBOLS |
661 | 662 | #define _APS_NEXT_RESOURCE_VALUE 199 |
662 | 663 | #define _APS_NEXT_COMMAND_VALUE 40182 |
663 | -#define _APS_NEXT_CONTROL_VALUE 1227 | |
664 | +#define _APS_NEXT_CONTROL_VALUE 1228 | |
664 | 665 | #define _APS_NEXT_SYMED_VALUE 101 |
665 | 666 | #endif |
666 | 667 | #endif |
@@ -1534,6 +1534,10 @@ void DecomposeSortType(ulong Sort, int *LFSort, int *LDSort, int *RFSort, int *R | ||
1534 | 1534 | int AskCurrentHost(void); |
1535 | 1535 | void SetCurrentHost(int Num); |
1536 | 1536 | void CopyDefaultHost(HOSTDATA *Set); |
1537 | +// ホスト共通設定機能 | |
1538 | +void ResetDefaultHost(void); | |
1539 | +void SetDefaultHost(HOSTDATA *Set); | |
1540 | +void CopyDefaultDefaultHost(HOSTDATA *Set); | |
1537 | 1541 | int SearchHostName(char *Name); |
1538 | 1542 | void ImportFromWSFTP(void); |
1539 | 1543 | // 暗号化通信対応 |
@@ -33,6 +33,9 @@ Changes in Ver.1.99 | ||
33 | 33 | |
34 | 34 | -- Tested on Windows 8.1 (32bit/64bit). |
35 | 35 | |
36 | +-- 64bit version is now available. | |
37 | + This works around the certain restriction on 64bit Windows. | |
38 | + | |
36 | 39 | -- Added the feature of automatic software update. |
37 | 40 | It will connect to the dedicated server to check whether there are updates |
38 | 41 | every 7 days by default, and then confirm whether to apply them. |
@@ -78,10 +81,13 @@ Changes in Ver.1.99 | ||
78 | 81 | -- Added a feature to export settings as FileZilla XML format. |
79 | 82 | |
80 | 83 | -- Added an option not to use weak encryption methods for each host. |
81 | - This refuses SSL 2.0 and encryption algorithms whose keys are shorter than | |
82 | - 128 bits. | |
84 | + This refuses SSL 3.0 or older and encryption algorithms whose keys are | |
85 | + shorter than 128 bits. | |
83 | 86 | This feature is enabled by default. |
84 | 87 | |
88 | +-- Added the default settings to the host list. | |
89 | + This is used for the initial state of new hosts and Quick Connect. | |
90 | + | |
85 | 91 | |
86 | 92 | Outline |
87 | 93 | ------- |
@@ -5,6 +5,9 @@ Changes in Ver.1.99 | ||
5 | 5 | |
6 | 6 | -- Tested on Windows 8.1 (32bit/64bit). |
7 | 7 | |
8 | +-- 64bit version is now available. | |
9 | + This works around the certain restriction on 64bit Windows. | |
10 | + | |
8 | 11 | -- Added the feature of automatic software update. |
9 | 12 | It will connect to the dedicated server to check whether there are updates |
10 | 13 | every 7 days by default, and then confirm whether to apply them. |
@@ -50,10 +53,13 @@ Changes in Ver.1.99 | ||
50 | 53 | -- Added a feature to export settings as FileZilla XML format. |
51 | 54 | |
52 | 55 | -- Added an option not to use weak encryption methods for each host. |
53 | - This refuses SSL 2.0 and encryption algorithms whose keys are shorter than | |
54 | - 128 bits. | |
56 | + This refuses SSL 3.0 or older and encryption algorithms whose keys are | |
57 | + shorter than 128 bits. | |
55 | 58 | This feature is enabled by default. |
56 | 59 | |
60 | +-- Added the default settings to the host list. | |
61 | + This is used for the initial state of new hosts and Quick Connect. | |
62 | + | |
57 | 63 | Changes in Ver.1.98g2 |
58 | 64 | -------------------- |
59 | 65 |
@@ -32,6 +32,9 @@ Ver 1.99 | ||
32 | 32 | |
33 | 33 | EWindows 8.1 (32bit/64bit)Å®ìðmFµÜµ½B |
34 | 34 | |
35 | +E64bitŪpÂ\ÉÈèܵ½B | |
36 | +@±êÉæè64bitÅWindowsÅÁèÌ쪧À³êéÌðñðÅ«Ü·B | |
37 | + | |
35 | 38 | E\tgEFAÌ©®XV@\ðÇÁµÜµ½B |
36 | 39 | @ùèÅÍ7ú²ÆÉêpÌT[o[ÉÚ±µÄXVª é©Ç¤©mFµA |
37 | 40 | @XVª êÎXVðKp·é©Ç¤©[U[ÉmFµÜ·B |
@@ -83,9 +86,12 @@ Ver 1.99 | ||
83 | 86 | EÝèðFileZilla XML`®ÉGNX|[g·é@\ðÇÁµÜµ½B |
84 | 87 | |
85 | 88 | EzXgÌÝèÉã¢Ã»û®ðgpµÈ¢ÝèðÇÁµÜµ½B |
86 | -@SSL 2.0â®Ìxª128rbg¢ÌÃðÛ·éæ¤ÉÈèÜ·B | |
89 | +@SSL 3.0ÈOâ®Ìxª128rbg¢ÌÃðÛ·éæ¤ÉÈèÜ·B | |
87 | 90 | @±Ì@\ÍùèÅÍLøÉÈèÜ·B |
88 | 91 | |
92 | +EzXgêÉùèÌÝèðÇÁµÜµ½B | |
93 | +@VKzXgÌì¬âNCbNÚ±ÌúóÔƵÄgp³êÜ·B | |
94 | + | |
89 | 95 | |
90 | 96 | Ver 1.96dÈOÖß·ê |
91 | 97 | ----------------------- |
@@ -4,6 +4,9 @@ FFFTP | ||
4 | 4 | |
5 | 5 | EWindows 8.1 (32bit/64bit)Å®ìðmFµÜµ½B |
6 | 6 | |
7 | +E64bitŪpÂ\ÉÈèܵ½B | |
8 | +@±êÉæè64bitÅWindowsÅÁèÌ쪧À³êéÌðñðÅ«Ü·B | |
9 | + | |
7 | 10 | E\tgEFAÌ©®XV@\ðÇÁµÜµ½B |
8 | 11 | @ùèÅÍ7ú²ÆÉêpÌT[o[ÉÚ±µÄXVª é©Ç¤©mFµA |
9 | 12 | @XVª êÎXVðKp·é©Ç¤©[U[ÉmFµÜ·B |
@@ -55,9 +58,12 @@ FFFTP | ||
55 | 58 | EÝèðFileZilla XML`®ÉGNX|[g·é@\ðÇÁµÜµ½B |
56 | 59 | |
57 | 60 | EzXgÌÝèÉã¢Ã»û®ðgpµÈ¢ÝèðÇÁµÜµ½B |
58 | -@SSL 2.0â®Ìxª128rbg¢ÌÃðÛ·éæ¤ÉÈèÜ·B | |
61 | +@SSL 3.0ÈOâ®Ìxª128rbg¢ÌÃðÛ·éæ¤ÉÈèÜ·B | |
59 | 62 | @±Ì@\ÍùèÅÍLøÉÈèÜ·B |
60 | 63 | |
64 | +EzXgêÉùèÌÝèðÇÁµÜµ½B | |
65 | +@VKzXgÌì¬âNCbNÚ±ÌúóÔƵÄgp³êÜ·B | |
66 | + | |
61 | 67 | ¡Ver 1.98g2 |
62 | 68 | |
63 | 69 | ECXg[ÅÉZIPÅÌt@Cª¬üµÄ¢½âèðC³µÜµ½B |
@@ -103,6 +103,9 @@ static HOSTDATA TmpHost; /* ホスト情報コピー用 */ | ||
103 | 103 | static int Apply; /* プロパティシートでOKを押したフラグ */ |
104 | 104 | static WNDPROC HostListProcPtr; |
105 | 105 | |
106 | +// ホスト共通設定機能 | |
107 | +HOSTDATA DefaultHost; | |
108 | + | |
106 | 109 | |
107 | 110 | |
108 | 111 | /*----- ホスト一覧ウインドウ -------------------------------------------------- |
@@ -539,6 +542,13 @@ static INT_PTR CALLBACK SelectHostProc(HWND hDlg, UINT message, WPARAM wParam, L | ||
539 | 542 | } |
540 | 543 | break; |
541 | 544 | |
545 | + // ホスト共通設定機能 | |
546 | + case HOST_SET_DEFAULT : | |
547 | + CopyDefaultHost(&TmpHost); | |
548 | + if(DispHostSetDlg(hDlg) == YES) | |
549 | + SetDefaultHost(&TmpHost); | |
550 | + break; | |
551 | + | |
542 | 552 | case HOST_LIST : |
543 | 553 | if(HIWORD(wParam) == LBN_DBLCLK) |
544 | 554 | PostMessage(hDlg, WM_COMMAND, MAKEWORD(IDOK, 0), 0); |
@@ -1307,6 +1317,62 @@ void SetCurrentHost(int Num) | ||
1307 | 1317 | |
1308 | 1318 | void CopyDefaultHost(HOSTDATA *Set) |
1309 | 1319 | { |
1320 | + // ホスト共通設定機能 | |
1321 | +// Set->Level = 0; | |
1322 | +// strcpy(Set->HostName, ""); | |
1323 | +// strcpy(Set->HostAdrs, ""); | |
1324 | +// strcpy(Set->UserName, ""); | |
1325 | +// strcpy(Set->PassWord, ""); | |
1326 | +// strcpy(Set->Account, ""); | |
1327 | +// strcpy(Set->LocalInitDir, DefaultLocalPath); | |
1328 | +// strcpy(Set->RemoteInitDir, ""); | |
1329 | +// memcpy(Set->BookMark, "\0\0", 2); | |
1330 | +// strcpy(Set->ChmodCmd, CHMOD_CMD_NOR); | |
1331 | +// strcpy(Set->LsName, LS_FNAME); | |
1332 | +// strcpy(Set->InitCmd, ""); | |
1333 | +// Set->Port = PORT_NOR; | |
1334 | +// Set->Anonymous = NO; | |
1335 | +// Set->KanjiCode = KANJI_NOCNV; | |
1336 | +// Set->KanaCnv = YES; | |
1337 | +// Set->NameKanjiCode = KANJI_NOCNV; | |
1338 | +// Set->NameKanaCnv = NO; | |
1339 | +// Set->Pasv = YES; | |
1340 | +// Set->FireWall = NO; | |
1341 | +// Set->ListCmdOnly = YES; | |
1342 | +// Set->UseNLST_R = YES; | |
1343 | +// Set->LastDir = NO; | |
1344 | +// Set->TimeZone = 9; /* GMT+9 (JST) */ | |
1345 | +// Set->HostType = HTYPE_AUTO; | |
1346 | +// Set->SyncMove = NO; | |
1347 | +// Set->NoFullPath = NO; | |
1348 | +// Set->Sort = SORT_NOTSAVED; | |
1349 | +// Set->Security = SECURITY_AUTO; | |
1350 | +// Set->Dialup = NO; | |
1351 | +// Set->DialupAlways = NO; | |
1352 | +// Set->DialupNotify = YES; | |
1353 | +// strcpy(Set->DialEntry, ""); | |
1354 | + memcpy(Set, &DefaultHost, sizeof(HOSTDATA)); | |
1355 | + return; | |
1356 | +} | |
1357 | + | |
1358 | + | |
1359 | +// ホスト共通設定機能 | |
1360 | +void ResetDefaultHost(void) | |
1361 | +{ | |
1362 | + CopyDefaultDefaultHost(&DefaultHost); | |
1363 | + return; | |
1364 | +} | |
1365 | + | |
1366 | +void SetDefaultHost(HOSTDATA *Set) | |
1367 | +{ | |
1368 | + memcpy(&DefaultHost, Set, sizeof(HOSTDATA)); | |
1369 | + return; | |
1370 | +} | |
1371 | + | |
1372 | +void CopyDefaultDefaultHost(HOSTDATA *Set) | |
1373 | +{ | |
1374 | + // 国際化対応 | |
1375 | + TIME_ZONE_INFORMATION tzi; | |
1310 | 1376 | Set->Level = 0; |
1311 | 1377 | strcpy(Set->HostName, ""); |
1312 | 1378 | strcpy(Set->HostAdrs, ""); |
@@ -1332,7 +1398,10 @@ void CopyDefaultHost(HOSTDATA *Set) | ||
1332 | 1398 | Set->ListCmdOnly = YES; |
1333 | 1399 | Set->UseNLST_R = YES; |
1334 | 1400 | Set->LastDir = NO; |
1335 | - Set->TimeZone = 9; /* GMT+9 (JST) */ | |
1401 | + // 国際化対応 | |
1402 | +// Set->TimeZone = 9; /* GMT+9 (JST) */ | |
1403 | + GetTimeZoneInformation(&tzi); | |
1404 | + Set->TimeZone = (int)(tzi.Bias / -60); | |
1336 | 1405 | Set->HostType = HTYPE_AUTO; |
1337 | 1406 | Set->SyncMove = NO; |
1338 | 1407 | Set->NoFullPath = NO; |
@@ -1370,7 +1439,6 @@ void CopyDefaultHost(HOSTDATA *Set) | ||
1370 | 1439 | return; |
1371 | 1440 | } |
1372 | 1441 | |
1373 | - | |
1374 | 1442 | /*----- 設定名一覧をウィンドウに送る ------------------------------------------ |
1375 | 1443 | * |
1376 | 1444 | * Parameter |
@@ -696,6 +696,9 @@ static int InitApp(LPSTR lpszCmdLine, int cmdShow) | ||
696 | 696 | |
697 | 697 | if(masterpass != 0) |
698 | 698 | { |
699 | + // ホスト共通設定機能 | |
700 | + ResetDefaultHost(); | |
701 | + | |
699 | 702 | LoadRegistry(); |
700 | 703 | |
701 | 704 | // ポータブル版判定 |
@@ -657,6 +657,66 @@ void SaveRegistry(void) | ||
657 | 657 | break; |
658 | 658 | } |
659 | 659 | |
660 | + // ホスト共通設定機能 | |
661 | + if(CreateSubKey(hKey4, "DefaultHost", &hKey5) == FFFTP_SUCCESS) | |
662 | + { | |
663 | + CopyDefaultDefaultHost(&DefaultHost); | |
664 | + CopyDefaultHost(&Host); | |
665 | + WriteIntValueToReg(hKey5, "Set", Host.Level); | |
666 | + SaveStr(hKey5, "HostName", Host.HostName, DefaultHost.HostName); | |
667 | + SaveStr(hKey5, "HostAdrs", Host.HostAdrs, DefaultHost.HostAdrs); | |
668 | + SaveStr(hKey5, "UserName", Host.UserName, DefaultHost.UserName); | |
669 | + SaveStr(hKey5, "Account", Host.Account, DefaultHost.Account); | |
670 | + SaveStr(hKey5, "LocalDir", Host.LocalInitDir, NULL); | |
671 | + SaveStr(hKey5, "RemoteDir", Host.RemoteInitDir, DefaultHost.RemoteInitDir); | |
672 | + SaveStr(hKey5, "Chmod", Host.ChmodCmd, DefaultHost.ChmodCmd); | |
673 | + SaveStr(hKey5, "Nlst", Host.LsName, DefaultHost.LsName); | |
674 | + SaveStr(hKey5, "Init", Host.InitCmd, DefaultHost.InitCmd); | |
675 | + if(Host.Anonymous == NO) | |
676 | + EncodePassword(Host.PassWord, Str); | |
677 | + else | |
678 | + strcpy(Str, DefaultHost.PassWord); | |
679 | + SaveStr(hKey5, "Password", Str, DefaultHost.PassWord); | |
680 | + SaveIntNum(hKey5, "Port", Host.Port, DefaultHost.Port); | |
681 | + SaveIntNum(hKey5, "Anonymous", Host.Anonymous, DefaultHost.Anonymous); | |
682 | + SaveIntNum(hKey5, "Kanji", Host.KanjiCode, DefaultHost.KanjiCode); | |
683 | + SaveIntNum(hKey5, "KanaCnv", Host.KanaCnv, DefaultHost.KanaCnv); | |
684 | + SaveIntNum(hKey5, "NameKanji", Host.NameKanjiCode, DefaultHost.NameKanjiCode); | |
685 | + SaveIntNum(hKey5, "NameKana", Host.NameKanaCnv, DefaultHost.NameKanaCnv); | |
686 | + SaveIntNum(hKey5, "Pasv", Host.Pasv, DefaultHost.Pasv); | |
687 | + SaveIntNum(hKey5, "Fwall", Host.FireWall, DefaultHost.FireWall); | |
688 | + SaveIntNum(hKey5, "List", Host.ListCmdOnly, DefaultHost.ListCmdOnly); | |
689 | + SaveIntNum(hKey5, "NLST-R", Host.UseNLST_R, DefaultHost.UseNLST_R); | |
690 | + SaveIntNum(hKey5, "Last", Host.LastDir, DefaultHost.LastDir); | |
691 | + SaveIntNum(hKey5, "Tzone", Host.TimeZone, DefaultHost.TimeZone); | |
692 | + SaveIntNum(hKey5, "Type", Host.HostType, DefaultHost.HostType); | |
693 | + SaveIntNum(hKey5, "Sync", Host.SyncMove, DefaultHost.SyncMove); | |
694 | + SaveIntNum(hKey5, "Fpath", Host.NoFullPath, DefaultHost.NoFullPath); | |
695 | + WriteBinaryToReg(hKey5, "Sort", &Host.Sort, sizeof(Host.Sort)); | |
696 | + SaveIntNum(hKey5, "Secu", Host.Security, DefaultHost.Security); | |
697 | + WriteMultiStringToReg(hKey5, "Bmarks", Host.BookMark); | |
698 | + SaveIntNum(hKey5, "Dial", Host.Dialup, DefaultHost.Dialup); | |
699 | + SaveIntNum(hKey5, "UseIt", Host.DialupAlways, DefaultHost.DialupAlways); | |
700 | + SaveIntNum(hKey5, "Notify", Host.DialupNotify, DefaultHost.DialupNotify); | |
701 | + SaveStr(hKey5, "DialTo", Host.DialEntry, DefaultHost.DialEntry); | |
702 | + SaveIntNum(hKey5, "NoEncryption", Host.UseNoEncryption, DefaultHost.UseNoEncryption); | |
703 | + SaveIntNum(hKey5, "FTPES", Host.UseFTPES, DefaultHost.UseFTPES); | |
704 | + SaveIntNum(hKey5, "FTPIS", Host.UseFTPIS, DefaultHost.UseFTPIS); | |
705 | + SaveIntNum(hKey5, "SFTP", Host.UseSFTP, DefaultHost.UseSFTP); | |
706 | + EncodePassword(Host.PrivateKey, Str); | |
707 | + SaveStr(hKey5, "PKey", Str, DefaultHost.PrivateKey); | |
708 | + SaveIntNum(hKey5, "NoWeak", Host.NoWeakEncryption, DefaultHost.NoWeakEncryption); | |
709 | + SaveIntNum(hKey5, "ThreadCount", Host.MaxThreadCount, DefaultHost.MaxThreadCount); | |
710 | + SaveIntNum(hKey5, "ReuseCmdSkt", Host.ReuseCmdSkt, DefaultHost.ReuseCmdSkt); | |
711 | + SaveIntNum(hKey5, "MLSD", Host.UseMLSD, DefaultHost.UseMLSD); | |
712 | + SaveIntNum(hKey5, "NetType", Host.NetType, DefaultHost.NetType); | |
713 | + SaveIntNum(hKey5, "Noop", Host.NoopInterval, DefaultHost.NoopInterval); | |
714 | + SaveIntNum(hKey5, "ErrMode", Host.TransferErrorMode, DefaultHost.TransferErrorMode); | |
715 | + SaveIntNum(hKey5, "ErrNotify", Host.TransferErrorNotify, DefaultHost.TransferErrorNotify); | |
716 | + SaveIntNum(hKey5, "ErrReconnect", Host.TransferErrorReconnect, DefaultHost.TransferErrorReconnect); | |
717 | + CloseSubKey(hKey5); | |
718 | + } | |
719 | + | |
660 | 720 | /* ホストの設定を保存 */ |
661 | 721 | CopyDefaultHost(&DefaultHost); |
662 | 722 | i = 0; |
@@ -1159,6 +1219,72 @@ int LoadRegistry(void) | ||
1159 | 1219 | } |
1160 | 1220 | } |
1161 | 1221 | |
1222 | + // ホスト共通設定機能 | |
1223 | + if(OpenSubKey(hKey4, "DefaultHost", &hKey5) == FFFTP_SUCCESS) | |
1224 | + { | |
1225 | + CopyDefaultDefaultHost(&Host); | |
1226 | + ReadIntValueFromReg(hKey5, "Set", &Host.Level); | |
1227 | + ReadStringFromReg(hKey5, "HostName", Host.HostName, HOST_NAME_LEN+1); | |
1228 | + ReadStringFromReg(hKey5, "HostAdrs", Host.HostAdrs, HOST_ADRS_LEN+1); | |
1229 | + ReadStringFromReg(hKey5, "UserName", Host.UserName, USER_NAME_LEN+1); | |
1230 | + ReadStringFromReg(hKey5, "Account", Host.Account, ACCOUNT_LEN+1); | |
1231 | + ReadStringFromReg(hKey5, "LocalDir", Host.LocalInitDir, INIT_DIR_LEN+1); | |
1232 | + ReadStringFromReg(hKey5, "RemoteDir", Host.RemoteInitDir, INIT_DIR_LEN+1); | |
1233 | + ReadStringFromReg(hKey5, "Chmod", Host.ChmodCmd, CHMOD_CMD_LEN+1); | |
1234 | + ReadStringFromReg(hKey5, "Nlst", Host.LsName, NLST_NAME_LEN+1); | |
1235 | + ReadStringFromReg(hKey5, "Init", Host.InitCmd, INITCMD_LEN+1); | |
1236 | + ReadIntValueFromReg(hKey5, "Port", &Host.Port); | |
1237 | + ReadIntValueFromReg(hKey5, "Anonymous", &Host.Anonymous); | |
1238 | + ReadIntValueFromReg(hKey5, "Kanji", &Host.KanjiCode); | |
1239 | + ReadIntValueFromReg(hKey5, "KanaCnv", &Host.KanaCnv); | |
1240 | + ReadIntValueFromReg(hKey5, "NameKanji", &Host.NameKanjiCode); | |
1241 | + ReadIntValueFromReg(hKey5, "NameKana", &Host.NameKanaCnv); | |
1242 | + ReadIntValueFromReg(hKey5, "Pasv", &Host.Pasv); | |
1243 | + ReadIntValueFromReg(hKey5, "Fwall", &Host.FireWall); | |
1244 | + ReadIntValueFromReg(hKey5, "List", &Host.ListCmdOnly); | |
1245 | + ReadIntValueFromReg(hKey5, "NLST-R", &Host.UseNLST_R); | |
1246 | + ReadIntValueFromReg(hKey5, "Last", &Host.LastDir); | |
1247 | + ReadIntValueFromReg(hKey5, "Tzone", &Host.TimeZone); | |
1248 | + ReadIntValueFromReg(hKey5, "Type", &Host.HostType); | |
1249 | + ReadIntValueFromReg(hKey5, "Sync", &Host.SyncMove); | |
1250 | + ReadIntValueFromReg(hKey5, "Fpath", &Host.NoFullPath); | |
1251 | + ReadBinaryFromReg(hKey5, "Sort", &Host.Sort, sizeof(Host.Sort)); | |
1252 | + ReadIntValueFromReg(hKey5, "Secu", &Host.Security); | |
1253 | + if(Host.Anonymous != YES) | |
1254 | + { | |
1255 | + strcpy(Str, ""); | |
1256 | + ReadStringFromReg(hKey5, "Password", Str, 255); | |
1257 | + DecodePassword(Str, Host.PassWord); | |
1258 | + } | |
1259 | + else | |
1260 | + strcpy(Host.PassWord, UserMailAdrs); | |
1261 | + ReadMultiStringFromReg(hKey5, "Bmarks", Host.BookMark, BOOKMARK_SIZE); | |
1262 | + ReadIntValueFromReg(hKey5, "Dial", &Host.Dialup); | |
1263 | + ReadIntValueFromReg(hKey5, "UseIt", &Host.DialupAlways); | |
1264 | + ReadIntValueFromReg(hKey5, "Notify", &Host.DialupNotify); | |
1265 | + ReadStringFromReg(hKey5, "DialTo", Host.DialEntry, RAS_NAME_LEN+1); | |
1266 | + ReadIntValueFromReg(hKey5, "NoEncryption", &Host.UseNoEncryption); | |
1267 | + ReadIntValueFromReg(hKey5, "FTPES", &Host.UseFTPES); | |
1268 | + ReadIntValueFromReg(hKey5, "FTPIS", &Host.UseFTPIS); | |
1269 | + ReadIntValueFromReg(hKey5, "SFTP", &Host.UseSFTP); | |
1270 | + strcpy(Str, ""); | |
1271 | + ReadStringFromReg(hKey5, "PKey", Str, PRIVATE_KEY_LEN*4+1); | |
1272 | + DecodePassword(Str, Host.PrivateKey); | |
1273 | + ReadIntValueFromReg(hKey5, "NoWeak", &Host.NoWeakEncryption); | |
1274 | + ReadIntValueFromReg(hKey5, "ThreadCount", &Host.MaxThreadCount); | |
1275 | + ReadIntValueFromReg(hKey5, "ReuseCmdSkt", &Host.ReuseCmdSkt); | |
1276 | + ReadIntValueFromReg(hKey5, "MLSD", &Host.UseMLSD); | |
1277 | + ReadIntValueFromReg(hKey5, "NetType", &Host.NetType); | |
1278 | + ReadIntValueFromReg(hKey5, "Noop", &Host.NoopInterval); | |
1279 | + ReadIntValueFromReg(hKey5, "ErrMode", &Host.TransferErrorMode); | |
1280 | + ReadIntValueFromReg(hKey5, "ErrNotify", &Host.TransferErrorNotify); | |
1281 | + ReadIntValueFromReg(hKey5, "ErrReconnect", &Host.TransferErrorReconnect); | |
1282 | + | |
1283 | + CloseSubKey(hKey5); | |
1284 | + | |
1285 | + SetDefaultHost(&Host); | |
1286 | + } | |
1287 | + | |
1162 | 1288 | /* ホストの設定を読み込む */ |
1163 | 1289 | Sets = 0; |
1164 | 1290 | ReadIntValueFromReg(hKey4, "SetNum", &Sets); |