FFFTPのソースコードです。
Revisión | 5054213b0bcac27cf73d6dd5fa7bf1d58c03d819 (tree) |
---|---|
Tiempo | 2012-12-22 16:58:58 |
Autor | s_kawamoto <s_kawamoto@user...> |
Commiter | s_kawamoto |
Add options for displaying file permissions in numbers.
@@ -1283,7 +1283,7 @@ BEGIN | ||
1283 | 1283 | PUSHBUTTON "キャンセル",IDCANCEL,96,72,50,14 |
1284 | 1284 | END |
1285 | 1285 | |
1286 | -opt_disp_dlg DIALOG 0, 0, 211, 155 | |
1286 | +opt_disp1_dlg DIALOG 0, 0, 211, 155 | |
1287 | 1287 | STYLE DS_SETFONT | WS_CHILD | WS_DISABLED | WS_CAPTION |
1288 | 1288 | FONT 9, "MS Shell Dlg" |
1289 | 1289 | BEGIN |
@@ -1449,6 +1449,13 @@ BEGIN | ||
1449 | 1449 | CONTROL "UTF-8 BOM",TRMODE4_UTF8BOM_CNV,"Button",BS_AUTORADIOBUTTON,12,69,81,10 |
1450 | 1450 | END |
1451 | 1451 | |
1452 | +opt_disp2_dlg DIALOG 0, 0, 211, 155 | |
1453 | +STYLE DS_SETFONT | WS_CHILD | WS_DISABLED | WS_CAPTION | |
1454 | +FONT 9, "MS Shell Dlg" | |
1455 | +BEGIN | |
1456 | + CONTROL "ファイルの属性を数字で表示する(&P)",DISP2_PERMIT_NUM,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,7,196,10 | |
1457 | +END | |
1458 | + | |
1452 | 1459 | |
1453 | 1460 | ///////////////////////////////////////////////////////////////////////////// |
1454 | 1461 | // |
@@ -2017,7 +2024,7 @@ BEGIN | ||
2017 | 2024 | BOTTOMMARGIN, 86 |
2018 | 2025 | END |
2019 | 2026 | |
2020 | - opt_disp_dlg, DIALOG | |
2027 | + opt_disp1_dlg, DIALOG | |
2021 | 2028 | BEGIN |
2022 | 2029 | LEFTMARGIN, 7 |
2023 | 2030 | RIGHTMARGIN, 204 |
@@ -2120,6 +2127,14 @@ BEGIN | ||
2120 | 2127 | TOPMARGIN, 7 |
2121 | 2128 | BOTTOMMARGIN, 148 |
2122 | 2129 | END |
2130 | + | |
2131 | + opt_disp2_dlg, DIALOG | |
2132 | + BEGIN | |
2133 | + LEFTMARGIN, 7 | |
2134 | + RIGHTMARGIN, 204 | |
2135 | + TOPMARGIN, 7 | |
2136 | + BOTTOMMARGIN, 148 | |
2137 | + END | |
2123 | 2138 | END |
2124 | 2139 | #endif // APSTUDIO_INVOKED |
2125 | 2140 |
@@ -101,7 +101,7 @@ | ||
101 | 101 | #define rasreconnect_dlg 178 |
102 | 102 | #define dial_dlg 179 |
103 | 103 | #define dial_password_dlg 180 |
104 | -#define opt_disp_dlg 181 | |
104 | +#define opt_disp1_dlg 181 | |
105 | 105 | #define bmark_edit_dlg 182 |
106 | 106 | #define opt_tool_dlg1 183 |
107 | 107 | #define IDD_OLEDRAG 184 |
@@ -116,6 +116,7 @@ | ||
116 | 116 | #define updown_as_with_ext_dlg 193 |
117 | 117 | #define ini_from_reg_dlg 194 |
118 | 118 | #define opt_trmode4_dlg 195 |
119 | +#define opt_disp2_dlg 196 | |
119 | 120 | #define TRANS_TIME_BAR 1002 |
120 | 121 | #define TRANS_TEXT 1003 |
121 | 122 | #define TRANS_REMOTE 1003 |
@@ -224,6 +225,7 @@ | ||
224 | 225 | #define SOUND_TRNNG 1015 |
225 | 226 | #define TOOL_EDITOR1_BR 1015 |
226 | 227 | #define CONNECT_CLOSE_NOTIFY 1015 |
228 | +#define DISP2_PERMIT_NUM 1015 | |
227 | 229 | #define PERM_O_EXEC 1016 |
228 | 230 | #define TOOL_EDITOR2_BR 1016 |
229 | 231 | #define CONNECT_QUICK_ANONY 1016 |
@@ -639,7 +641,7 @@ | ||
639 | 641 | // |
640 | 642 | #ifdef APSTUDIO_INVOKED |
641 | 643 | #ifndef APSTUDIO_READONLY_SYMBOLS |
642 | -#define _APS_NEXT_RESOURCE_VALUE 196 | |
644 | +#define _APS_NEXT_RESOURCE_VALUE 197 | |
643 | 645 | #define _APS_NEXT_COMMAND_VALUE 40177 |
644 | 646 | #define _APS_NEXT_CONTROL_VALUE 1220 |
645 | 647 | #define _APS_NEXT_SYMED_VALUE 101 |
@@ -1309,7 +1309,7 @@ BEGIN | ||
1309 | 1309 | PUSHBUTTON "Cancel",IDCANCEL,96,63,50,14 |
1310 | 1310 | END |
1311 | 1311 | |
1312 | -opt_disp_dlg DIALOG 0, 0, 211, 155 | |
1312 | +opt_disp1_dlg DIALOG 0, 0, 211, 155 | |
1313 | 1313 | STYLE DS_SETFONT | WS_CHILD | WS_DISABLED | WS_CAPTION |
1314 | 1314 | FONT 9, "MS Shell Dlg" |
1315 | 1315 | BEGIN |
@@ -1479,6 +1479,13 @@ BEGIN | ||
1479 | 1479 | CONTROL "UTF-8 BOM",TRMODE4_UTF8BOM_CNV,"Button",BS_AUTORADIOBUTTON,12,69,81,10 |
1480 | 1480 | END |
1481 | 1481 | |
1482 | +opt_disp2_dlg DIALOG 0, 0, 211, 155 | |
1483 | +STYLE DS_SETFONT | WS_CHILD | WS_DISABLED | WS_CAPTION | |
1484 | +FONT 9, "MS Shell Dlg" | |
1485 | +BEGIN | |
1486 | + CONTROL "Display file &permissions in numbers",DISP2_PERMIT_NUM,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,7,196,10 | |
1487 | +END | |
1488 | + | |
1482 | 1489 | |
1483 | 1490 | ///////////////////////////////////////////////////////////////////////////// |
1484 | 1491 | // |
@@ -2047,7 +2054,7 @@ BEGIN | ||
2047 | 2054 | BOTTOMMARGIN, 78 |
2048 | 2055 | END |
2049 | 2056 | |
2050 | - opt_disp_dlg, DIALOG | |
2057 | + opt_disp1_dlg, DIALOG | |
2051 | 2058 | BEGIN |
2052 | 2059 | LEFTMARGIN, 7 |
2053 | 2060 | RIGHTMARGIN, 204 |
@@ -2147,6 +2154,14 @@ BEGIN | ||
2147 | 2154 | TOPMARGIN, 7 |
2148 | 2155 | BOTTOMMARGIN, 148 |
2149 | 2156 | END |
2157 | + | |
2158 | + opt_disp2_dlg, DIALOG | |
2159 | + BEGIN | |
2160 | + LEFTMARGIN, 7 | |
2161 | + RIGHTMARGIN, 204 | |
2162 | + TOPMARGIN, 7 | |
2163 | + BOTTOMMARGIN, 148 | |
2164 | + END | |
2150 | 2165 | END |
2151 | 2166 | #endif // APSTUDIO_INVOKED |
2152 | 2167 |
@@ -101,7 +101,7 @@ | ||
101 | 101 | #define rasreconnect_dlg 178 |
102 | 102 | #define dial_dlg 179 |
103 | 103 | #define dial_password_dlg 180 |
104 | -#define opt_disp_dlg 181 | |
104 | +#define opt_disp1_dlg 181 | |
105 | 105 | #define bmark_edit_dlg 182 |
106 | 106 | #define opt_tool_dlg1 183 |
107 | 107 | #define IDD_OLEDRAG 184 |
@@ -116,6 +116,7 @@ | ||
116 | 116 | #define updown_as_with_ext_dlg 193 |
117 | 117 | #define ini_from_reg_dlg 194 |
118 | 118 | #define opt_trmode4_dlg 195 |
119 | +#define opt_disp2_dlg 196 | |
119 | 120 | #define TRANS_TIME_BAR 1002 |
120 | 121 | #define TRANS_TEXT 1003 |
121 | 122 | #define TRANS_REMOTE 1003 |
@@ -224,6 +225,7 @@ | ||
224 | 225 | #define SOUND_TRNNG 1015 |
225 | 226 | #define TOOL_EDITOR1_BR 1015 |
226 | 227 | #define CONNECT_CLOSE_NOTIFY 1015 |
228 | +#define DISP2_PERMIT_NUM 1015 | |
227 | 229 | #define PERM_O_EXEC 1016 |
228 | 230 | #define TOOL_EDITOR2_BR 1016 |
229 | 231 | #define CONNECT_QUICK_ANONY 1016 |
@@ -639,7 +641,7 @@ | ||
639 | 641 | // |
640 | 642 | #ifdef APSTUDIO_INVOKED |
641 | 643 | #ifndef APSTUDIO_READONLY_SYMBOLS |
642 | -#define _APS_NEXT_RESOURCE_VALUE 196 | |
644 | +#define _APS_NEXT_RESOURCE_VALUE 197 | |
643 | 645 | #define _APS_NEXT_COMMAND_VALUE 40177 |
644 | 646 | #define _APS_NEXT_CONTROL_VALUE 1220 |
645 | 647 | #define _APS_NEXT_SYMED_VALUE 101 |
@@ -1830,7 +1830,9 @@ int TimeString2FileTime(char *Time, FILETIME *Buf); | ||
1830 | 1830 | void FileTime2TimeString(FILETIME *Time, char *Buf, int Mode, int InfoExist, int ShowSeconds); |
1831 | 1831 | void SpecificLocalFileTime2FileTime(FILETIME *Time, int TimeZone); |
1832 | 1832 | int AttrString2Value(char *Str); |
1833 | -void AttrValue2String(int Attr, char *Buf); | |
1833 | +// ファイルの属性を数字で表示 | |
1834 | +//void AttrValue2String(int Attr, char *Buf); | |
1835 | +void AttrValue2String(int Attr, char *Buf, int ShowNumber); | |
1834 | 1836 | void FormatIniString(char *Str); |
1835 | 1837 | int SelectFile(HWND hWnd, char *Fname, char *Title, char *Filters, char *Ext, int Flags, int Save); |
1836 | 1838 | int SelectDir(HWND hWnd, char *Buf, int MaxLen); |
@@ -146,6 +146,8 @@ extern int MoveMode; | ||
146 | 146 | extern int DispFileIcon; |
147 | 147 | // タイムスタンプのバグ修正 |
148 | 148 | extern int DispTimeSeconds; |
149 | +// ファイルの属性を数字で表示 | |
150 | +extern int DispPermissionsNumber; | |
149 | 151 | |
150 | 152 | /*===== ローカルなワーク =====*/ |
151 | 153 |
@@ -1820,7 +1822,9 @@ static void AddListView(HWND hWnd, int Pos, char *Name, int Type, LONGLONG Size, | ||
1820 | 1822 | #else |
1821 | 1823 | if(InfoExist & FINFO_ATTR) |
1822 | 1824 | #endif |
1823 | - AttrValue2String(Attr, Tmp); | |
1825 | + // ファイルの属性を数字で表示 | |
1826 | +// AttrValue2String(Attr, Tmp); | |
1827 | + AttrValue2String(Attr, Tmp, DispPermissionsNumber); | |
1824 | 1828 | LvItem.mask = LVIF_TEXT; |
1825 | 1829 | LvItem.iItem = Pos; |
1826 | 1830 | LvItem.iSubItem = 4; |
@@ -248,6 +248,8 @@ BYTE SSLRootCAFileHash[20]; | ||
248 | 248 | int DispFileIcon = NO; |
249 | 249 | // タイムスタンプのバグ修正 |
250 | 250 | int DispTimeSeconds = NO; |
251 | +// ファイルの属性を数字で表示 | |
252 | +int DispPermissionsNumber = NO; | |
251 | 253 | // ディレクトリ自動作成 |
252 | 254 | int MakeAllDir = YES; |
253 | 255 | // UTF-8対応 |
@@ -190,7 +190,7 @@ | ||
190 | 190 | #define MSGJPN189 _Tu8("Transfer3", "Transfer3") |
191 | 191 | #define MSGJPN190 _Tu8("Mirroring", "Mirroring") |
192 | 192 | #define MSGJPN191 _Tu8("Operation", "Operation") |
193 | -#define MSGJPN192 _Tu8("View", "View") | |
193 | +#define MSGJPN192 _Tu8("View1", "View1") | |
194 | 194 | #define MSGJPN193 _Tu8("Connecting", "Connecting") |
195 | 195 | #define MSGJPN194 _Tu8("Firewall", "Firewall") |
196 | 196 | #define MSGJPN195 _Tu8("Tool", "Tool") |
@@ -338,6 +338,7 @@ | ||
338 | 338 | #define MSGJPN337 _Tu8("Resume all later", "Resume all later") |
339 | 339 | #define MSGJPN338 _Tu8("Skip all", "Skip all") |
340 | 340 | #define MSGJPN339 _Tu8("Transfer4", "Transfer4") |
341 | +#define MSGJPN340 _Tu8("View2", "View2") | |
341 | 342 | #if defined(HAVE_TANDEM) |
342 | 343 | #define MSGJPN2000 _Tu8("NonStop Server", "NonStop Server") |
343 | 344 | #define MSGJPN2001 _Tu8("OSS<->GUARDIAN Switch(&O)", "OSS<->GUARDIAN Switch(&O)") |
@@ -190,7 +190,7 @@ | ||
190 | 190 | #define MSGJPN189 _Tu8("転送3", "\xE8\xBB\xA2\xE9\x80\x81\x33") |
191 | 191 | #define MSGJPN190 _Tu8("ミラーリング", "\xE3\x83\x9F\xE3\x83\xA9\xE3\x83\xBC\xE3\x83\xAA\xE3\x83\xB3\xE3\x82\xB0") |
192 | 192 | #define MSGJPN191 _Tu8("操作", "\xE6\x93\x8D\xE4\xBD\x9C") |
193 | -#define MSGJPN192 _Tu8("表示", "\xE8\xA1\xA8\xE7\xA4\xBA") | |
193 | +#define MSGJPN192 _Tu8("表示1", "\xE8\xA1\xA8\xE7\xA4\xBA\x31") | |
194 | 194 | #define MSGJPN193 _Tu8("接続/切断", "\xE6\x8E\xA5\xE7\xB6\x9A/\xE5\x88\x87\xE6\x96\xAD") |
195 | 195 | #define MSGJPN194 _Tu8("FireWall", "FireWall") |
196 | 196 | #define MSGJPN195 _Tu8("ツール", "\xE3\x83\x84\xE3\x83\xBC\xE3\x83\xAB") |
@@ -338,6 +338,7 @@ | ||
338 | 338 | #define MSGJPN337 _Tu8("全て後でリジューム", "\xE5\x85\xA8\xE3\x81\xA6\xE5\xBE\x8C\xE3\x81\xA7\xE3\x83\xAA\xE3\x82\xB8\xE3\x83\xA5\xE3\x83\xBC\xE3\x83\xA0") |
339 | 339 | #define MSGJPN338 _Tu8("全てスキップ", "\xE5\x85\xA8\xE3\x81\xA6\xE3\x82\xB9\xE3\x82\xAD\xE3\x83\x83\xE3\x83\x97") |
340 | 340 | #define MSGJPN339 _Tu8("転送4", "\xE8\xBB\xA2\xE9\x80\x81\x34") |
341 | +#define MSGJPN340 _Tu8("表示2", "\xE8\xA1\xA8\xE7\xA4\xBA\x32") | |
341 | 342 | #if defined(HAVE_TANDEM) |
342 | 343 | #define MSGJPN2000 _Tu8("NonStop Server", "NonStop Server") |
343 | 344 | #define MSGJPN2001 _Tu8("OSS<->GUARDIAN 切り替え(&O)", "OSS<->GUARDIAN \xE5\x88\x87\xE3\x82\x8A\xE6\x9B\xBF\xE3\x81\x88(&O)") |
@@ -1240,28 +1240,59 @@ int AttrString2Value(char *Str) | ||
1240 | 1240 | |
1241 | 1241 | Ret = 0; |
1242 | 1242 | memset(Tmp, 0, 10); |
1243 | - strncpy(Tmp, Str, 9); | |
1244 | - | |
1245 | - if(Tmp[0] != '-') | |
1246 | - Ret |= 0x400; | |
1247 | - if(Tmp[1] != '-') | |
1248 | - Ret |= 0x200; | |
1249 | - if(Tmp[2] != '-') | |
1250 | - Ret |= 0x100; | |
1251 | - | |
1252 | - if(Tmp[3] != '-') | |
1253 | - Ret |= 0x40; | |
1254 | - if(Tmp[4] != '-') | |
1255 | - Ret |= 0x20; | |
1256 | - if(Tmp[5] != '-') | |
1257 | - Ret |= 0x10; | |
1258 | - | |
1259 | - if(Tmp[6] != '-') | |
1260 | - Ret |= 0x4; | |
1261 | - if(Tmp[7] != '-') | |
1262 | - Ret |= 0x2; | |
1263 | - if(Tmp[8] != '-') | |
1264 | - Ret |= 0x1; | |
1243 | + // ファイルの属性を数字で表示 | |
1244 | +// strncpy(Tmp, Str, 9); | |
1245 | +// | |
1246 | +// if(Tmp[0] != '-') | |
1247 | +// Ret |= 0x400; | |
1248 | +// if(Tmp[1] != '-') | |
1249 | +// Ret |= 0x200; | |
1250 | +// if(Tmp[2] != '-') | |
1251 | +// Ret |= 0x100; | |
1252 | +// | |
1253 | +// if(Tmp[3] != '-') | |
1254 | +// Ret |= 0x40; | |
1255 | +// if(Tmp[4] != '-') | |
1256 | +// Ret |= 0x20; | |
1257 | +// if(Tmp[5] != '-') | |
1258 | +// Ret |= 0x10; | |
1259 | +// | |
1260 | +// if(Tmp[6] != '-') | |
1261 | +// Ret |= 0x4; | |
1262 | +// if(Tmp[7] != '-') | |
1263 | +// Ret |= 0x2; | |
1264 | +// if(Tmp[8] != '-') | |
1265 | +// Ret |= 0x1; | |
1266 | + if(strlen(Str) >= 9) | |
1267 | + { | |
1268 | + strncpy(Tmp, Str, 9); | |
1269 | + | |
1270 | + if(Tmp[0] != '-') | |
1271 | + Ret |= 0x400; | |
1272 | + if(Tmp[1] != '-') | |
1273 | + Ret |= 0x200; | |
1274 | + if(Tmp[2] != '-') | |
1275 | + Ret |= 0x100; | |
1276 | + | |
1277 | + if(Tmp[3] != '-') | |
1278 | + Ret |= 0x40; | |
1279 | + if(Tmp[4] != '-') | |
1280 | + Ret |= 0x20; | |
1281 | + if(Tmp[5] != '-') | |
1282 | + Ret |= 0x10; | |
1283 | + | |
1284 | + if(Tmp[6] != '-') | |
1285 | + Ret |= 0x4; | |
1286 | + if(Tmp[7] != '-') | |
1287 | + Ret |= 0x2; | |
1288 | + if(Tmp[8] != '-') | |
1289 | + Ret |= 0x1; | |
1290 | + } | |
1291 | + else if(strlen(Str) >= 3) | |
1292 | + { | |
1293 | + strncpy(Tmp, Str, 3); | |
1294 | + Ret = strtol(Tmp, NULL, 16); | |
1295 | + } | |
1265 | 1296 | |
1266 | 1297 | return(Ret); |
1267 | 1298 | } |
@@ -1277,30 +1308,62 @@ int AttrString2Value(char *Str) | ||
1277 | 1308 | * int 値 |
1278 | 1309 | *----------------------------------------------------------------------------*/ |
1279 | 1310 | |
1280 | -void AttrValue2String(int Attr, char *Buf) | |
1311 | +// ファイルの属性を数字で表示 | |
1312 | +//void AttrValue2String(int Attr, char *Buf) | |
1313 | +void AttrValue2String(int Attr, char *Buf, int ShowNumber) | |
1281 | 1314 | { |
1282 | - strcpy(Buf, "---------"); | |
1283 | - | |
1284 | - if(Attr & 0x400) | |
1285 | - Buf[0] = 'r'; | |
1286 | - if(Attr & 0x200) | |
1287 | - Buf[1] = 'w'; | |
1288 | - if(Attr & 0x100) | |
1289 | - Buf[2] = 'x'; | |
1290 | - | |
1291 | - if(Attr & 0x40) | |
1292 | - Buf[3] = 'r'; | |
1293 | - if(Attr & 0x20) | |
1294 | - Buf[4] = 'w'; | |
1295 | - if(Attr & 0x10) | |
1296 | - Buf[5] = 'x'; | |
1297 | - | |
1298 | - if(Attr & 0x4) | |
1299 | - Buf[6] = 'r'; | |
1300 | - if(Attr & 0x2) | |
1301 | - Buf[7] = 'w'; | |
1302 | - if(Attr & 0x1) | |
1303 | - Buf[8] = 'x'; | |
1315 | + // ファイルの属性を数字で表示 | |
1316 | +// strcpy(Buf, "---------"); | |
1317 | +// | |
1318 | +// if(Attr & 0x400) | |
1319 | +// Buf[0] = 'r'; | |
1320 | +// if(Attr & 0x200) | |
1321 | +// Buf[1] = 'w'; | |
1322 | +// if(Attr & 0x100) | |
1323 | +// Buf[2] = 'x'; | |
1324 | +// | |
1325 | +// if(Attr & 0x40) | |
1326 | +// Buf[3] = 'r'; | |
1327 | +// if(Attr & 0x20) | |
1328 | +// Buf[4] = 'w'; | |
1329 | +// if(Attr & 0x10) | |
1330 | +// Buf[5] = 'x'; | |
1331 | +// | |
1332 | +// if(Attr & 0x4) | |
1333 | +// Buf[6] = 'r'; | |
1334 | +// if(Attr & 0x2) | |
1335 | +// Buf[7] = 'w'; | |
1336 | +// if(Attr & 0x1) | |
1337 | +// Buf[8] = 'x'; | |
1338 | + if(ShowNumber == YES) | |
1339 | + { | |
1340 | + sprintf(Buf, "%03x", Attr); | |
1341 | + } | |
1342 | + else | |
1343 | + { | |
1344 | + strcpy(Buf, "---------"); | |
1345 | + | |
1346 | + if(Attr & 0x400) | |
1347 | + Buf[0] = 'r'; | |
1348 | + if(Attr & 0x200) | |
1349 | + Buf[1] = 'w'; | |
1350 | + if(Attr & 0x100) | |
1351 | + Buf[2] = 'x'; | |
1352 | + | |
1353 | + if(Attr & 0x40) | |
1354 | + Buf[3] = 'r'; | |
1355 | + if(Attr & 0x20) | |
1356 | + Buf[4] = 'w'; | |
1357 | + if(Attr & 0x10) | |
1358 | + Buf[5] = 'x'; | |
1359 | + | |
1360 | + if(Attr & 0x4) | |
1361 | + Buf[6] = 'r'; | |
1362 | + if(Attr & 0x2) | |
1363 | + Buf[7] = 'w'; | |
1364 | + if(Attr & 0x1) | |
1365 | + Buf[8] = 'x'; | |
1366 | + } | |
1304 | 1367 | |
1305 | 1368 | return; |
1306 | 1369 | } |
@@ -66,12 +66,14 @@ static INT_PTR CALLBACK DefAttrDlgProc(HWND hDlg, UINT message, WPARAM wParam, L | ||
66 | 66 | static void AddFnameAttrToListView(HWND hDlg, char *Fname, char *Attr); |
67 | 67 | static void GetFnameAttrFromListView(HWND hDlg, char *Buf); |
68 | 68 | // 64ビット対応 |
69 | +// ファイルの属性を数字で表示 | |
69 | 70 | //static BOOL CALLBACK MirrorSettingProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam); |
70 | 71 | //static BOOL CALLBACK NotifySettingProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam); |
71 | 72 | //static BOOL CALLBACK DispSettingProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam); |
72 | 73 | static INT_PTR CALLBACK MirrorSettingProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam); |
73 | 74 | static INT_PTR CALLBACK NotifySettingProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam); |
74 | -static INT_PTR CALLBACK DispSettingProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam); | |
75 | +static INT_PTR CALLBACK Disp1SettingProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam); | |
76 | +static INT_PTR CALLBACK Disp2SettingProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam); | |
75 | 77 | static int SelectListFont(HWND hWnd, LOGFONT *lFont); |
76 | 78 | // 64ビット対応 |
77 | 79 | //static BOOL CALLBACK ConnectSettingProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam); |
@@ -172,6 +174,8 @@ extern int FolderAttrNum; | ||
172 | 174 | extern int DispFileIcon; |
173 | 175 | // タイムスタンプのバグ修正 |
174 | 176 | extern int DispTimeSeconds; |
177 | +// ファイルの属性を数字で表示 | |
178 | +extern int DispPermissionsNumber; | |
175 | 179 | // ディレクトリ自動作成 |
176 | 180 | extern int MakeAllDir; |
177 | 181 |
@@ -189,7 +193,7 @@ void SetOption(int Start) | ||
189 | 193 | { |
190 | 194 | // UTF-8対応 |
191 | 195 | // PROPSHEETPAGE psp[12]; |
192 | - PROPSHEETPAGE psp[13]; | |
196 | + PROPSHEETPAGE psp[14]; | |
193 | 197 | PROPSHEETHEADER psh; |
194 | 198 | |
195 | 199 | // 変数が未初期化のバグ修正 |
@@ -350,9 +354,9 @@ void SetOption(int Start) | ||
350 | 354 | psp[7].dwSize = sizeof(PROPSHEETPAGE); |
351 | 355 | psp[7].dwFlags = PSP_USETITLE | PSP_HASHELP; |
352 | 356 | psp[7].hInstance = GetFtpInst(); |
353 | - psp[7].pszTemplate = MAKEINTRESOURCE(opt_disp_dlg); | |
357 | + psp[7].pszTemplate = MAKEINTRESOURCE(opt_disp1_dlg); | |
354 | 358 | psp[7].pszIcon = NULL; |
355 | - psp[7].pfnDlgProc = DispSettingProc; | |
359 | + psp[7].pfnDlgProc = Disp1SettingProc; | |
356 | 360 | psp[7].pszTitle = MSGJPN192; |
357 | 361 | psp[7].lParam = 0; |
358 | 362 | psp[7].pfnCallback = NULL; |
@@ -360,53 +364,63 @@ void SetOption(int Start) | ||
360 | 364 | psp[8].dwSize = sizeof(PROPSHEETPAGE); |
361 | 365 | psp[8].dwFlags = PSP_USETITLE | PSP_HASHELP; |
362 | 366 | psp[8].hInstance = GetFtpInst(); |
363 | - psp[8].pszTemplate = MAKEINTRESOURCE(opt_connect_dlg); | |
367 | + psp[8].pszTemplate = MAKEINTRESOURCE(opt_disp2_dlg); | |
364 | 368 | psp[8].pszIcon = NULL; |
365 | - psp[8].pfnDlgProc = ConnectSettingProc; | |
366 | - psp[8].pszTitle = MSGJPN193; | |
369 | + psp[8].pfnDlgProc = Disp2SettingProc; | |
370 | + psp[8].pszTitle = MSGJPN340; | |
367 | 371 | psp[8].lParam = 0; |
368 | 372 | psp[8].pfnCallback = NULL; |
369 | 373 | |
370 | 374 | psp[9].dwSize = sizeof(PROPSHEETPAGE); |
371 | 375 | psp[9].dwFlags = PSP_USETITLE | PSP_HASHELP; |
372 | 376 | psp[9].hInstance = GetFtpInst(); |
373 | - psp[9].pszTemplate = MAKEINTRESOURCE(opt_fire_dlg); | |
377 | + psp[9].pszTemplate = MAKEINTRESOURCE(opt_connect_dlg); | |
374 | 378 | psp[9].pszIcon = NULL; |
375 | - psp[9].pfnDlgProc = FireSettingProc; | |
376 | - psp[9].pszTitle = MSGJPN194; | |
379 | + psp[9].pfnDlgProc = ConnectSettingProc; | |
380 | + psp[9].pszTitle = MSGJPN193; | |
377 | 381 | psp[9].lParam = 0; |
378 | 382 | psp[9].pfnCallback = NULL; |
379 | 383 | |
380 | 384 | psp[10].dwSize = sizeof(PROPSHEETPAGE); |
381 | 385 | psp[10].dwFlags = PSP_USETITLE | PSP_HASHELP; |
382 | 386 | psp[10].hInstance = GetFtpInst(); |
383 | - psp[10].pszTemplate = MAKEINTRESOURCE(opt_tool_dlg); | |
387 | + psp[10].pszTemplate = MAKEINTRESOURCE(opt_fire_dlg); | |
384 | 388 | psp[10].pszIcon = NULL; |
385 | - psp[10].pfnDlgProc = ToolSettingProc; | |
386 | - psp[10].pszTitle = MSGJPN195; | |
389 | + psp[10].pfnDlgProc = FireSettingProc; | |
390 | + psp[10].pszTitle = MSGJPN194; | |
387 | 391 | psp[10].lParam = 0; |
388 | 392 | psp[10].pfnCallback = NULL; |
389 | 393 | |
390 | 394 | psp[11].dwSize = sizeof(PROPSHEETPAGE); |
391 | 395 | psp[11].dwFlags = PSP_USETITLE | PSP_HASHELP; |
392 | 396 | psp[11].hInstance = GetFtpInst(); |
393 | - psp[11].pszTemplate = MAKEINTRESOURCE(opt_sound_dlg); | |
397 | + psp[11].pszTemplate = MAKEINTRESOURCE(opt_tool_dlg); | |
394 | 398 | psp[11].pszIcon = NULL; |
395 | - psp[11].pfnDlgProc = SoundSettingProc; | |
396 | - psp[11].pszTitle = MSGJPN196; | |
399 | + psp[11].pfnDlgProc = ToolSettingProc; | |
400 | + psp[11].pszTitle = MSGJPN195; | |
397 | 401 | psp[11].lParam = 0; |
398 | 402 | psp[11].pfnCallback = NULL; |
399 | 403 | |
400 | 404 | psp[12].dwSize = sizeof(PROPSHEETPAGE); |
401 | 405 | psp[12].dwFlags = PSP_USETITLE | PSP_HASHELP; |
402 | 406 | psp[12].hInstance = GetFtpInst(); |
403 | - psp[12].pszTemplate = MAKEINTRESOURCE(opt_misc_dlg); | |
407 | + psp[12].pszTemplate = MAKEINTRESOURCE(opt_sound_dlg); | |
404 | 408 | psp[12].pszIcon = NULL; |
405 | - psp[12].pfnDlgProc = MiscSettingProc; | |
406 | - psp[12].pszTitle = MSGJPN197; | |
409 | + psp[12].pfnDlgProc = SoundSettingProc; | |
410 | + psp[12].pszTitle = MSGJPN196; | |
407 | 411 | psp[12].lParam = 0; |
408 | 412 | psp[12].pfnCallback = NULL; |
409 | 413 | |
414 | + psp[13].dwSize = sizeof(PROPSHEETPAGE); | |
415 | + psp[13].dwFlags = PSP_USETITLE | PSP_HASHELP; | |
416 | + psp[13].hInstance = GetFtpInst(); | |
417 | + psp[13].pszTemplate = MAKEINTRESOURCE(opt_misc_dlg); | |
418 | + psp[13].pszIcon = NULL; | |
419 | + psp[13].pfnDlgProc = MiscSettingProc; | |
420 | + psp[13].pszTitle = MSGJPN197; | |
421 | + psp[13].lParam = 0; | |
422 | + psp[13].pfnCallback = NULL; | |
423 | + | |
410 | 424 | psh.dwSize = sizeof(PROPSHEETHEADER); |
411 | 425 | psh.dwFlags = PSH_HASHELP | PSH_NOAPPLYNOW | PSH_PROPSHEETPAGE; |
412 | 426 | psh.hwndParent = GetMainHwnd(); |
@@ -1111,8 +1125,9 @@ static INT_PTR CALLBACK NotifySettingProc(HWND hDlg, UINT message, WPARAM wParam | ||
1111 | 1125 | *----------------------------------------------------------------------------*/ |
1112 | 1126 | |
1113 | 1127 | // 64ビット対応 |
1128 | +// ファイルの属性を数字で表示 | |
1114 | 1129 | //static BOOL CALLBACK DispSettingProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) |
1115 | -static INT_PTR CALLBACK DispSettingProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) | |
1130 | +static INT_PTR CALLBACK Disp1SettingProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) | |
1116 | 1131 | { |
1117 | 1132 | NMHDR *pnmhdr; |
1118 | 1133 | static LOGFONT TmpFont; |
@@ -1172,6 +1187,40 @@ static INT_PTR CALLBACK DispSettingProc(HWND hDlg, UINT message, WPARAM wParam, | ||
1172 | 1187 | } |
1173 | 1188 | |
1174 | 1189 | |
1190 | +// ファイルの属性を数字で表示 | |
1191 | +static INT_PTR CALLBACK Disp2SettingProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) | |
1192 | +{ | |
1193 | + NMHDR *pnmhdr; | |
1194 | + static LOGFONT TmpFont; | |
1195 | + | |
1196 | + switch (message) | |
1197 | + { | |
1198 | + case WM_INITDIALOG : | |
1199 | + SendDlgItemMessage(hDlg, DISP2_PERMIT_NUM, BM_SETCHECK, DispPermissionsNumber, 0); | |
1200 | + return(TRUE); | |
1201 | + | |
1202 | + case WM_NOTIFY: | |
1203 | + pnmhdr = (NMHDR FAR *)lParam; | |
1204 | + switch(pnmhdr->code) | |
1205 | + { | |
1206 | + case PSN_APPLY : | |
1207 | + DispPermissionsNumber = SendDlgItemMessage(hDlg, DISP2_PERMIT_NUM, BM_GETCHECK, 0, 0); | |
1208 | + break; | |
1209 | + | |
1210 | + case PSN_RESET : | |
1211 | + break; | |
1212 | + | |
1213 | + case PSN_HELP : | |
1214 | + // TODO: | |
1215 | +// hHelpWin = HtmlHelp(NULL, AskHelpFilePath(), HH_HELP_CONTEXT, IDH_HELP_TOPIC_0000047); | |
1216 | + break; | |
1217 | + } | |
1218 | + break; | |
1219 | + } | |
1220 | + return(FALSE); | |
1221 | +} | |
1222 | + | |
1223 | + | |
1175 | 1224 | /*----- フォントを選ぶ -------------------------------------------------------- |
1176 | 1225 | * |
1177 | 1226 | * Parameter |
@@ -197,6 +197,8 @@ extern BYTE SSLRootCAFileHash[20]; | ||
197 | 197 | extern int DispFileIcon; |
198 | 198 | // タイムスタンプのバグ修正 |
199 | 199 | extern int DispTimeSeconds; |
200 | +// ファイルの属性を数字で表示 | |
201 | +extern int DispPermissionsNumber; | |
200 | 202 | // ディレクトリ自動作成 |
201 | 203 | extern int MakeAllDir; |
202 | 204 | // UTF-8対応 |
@@ -629,6 +631,8 @@ void SaveRegistry(void) | ||
629 | 631 | WriteIntValueToReg(hKey4, "ListIcon", DispFileIcon); |
630 | 632 | // タイムスタンプのバグ修正 |
631 | 633 | WriteIntValueToReg(hKey4, "ListSecond", DispTimeSeconds); |
634 | + // ファイルの属性を数字で表示 | |
635 | + WriteIntValueToReg(hKey4, "ListPermitNum", DispPermissionsNumber); | |
632 | 636 | // ディレクトリ自動作成 |
633 | 637 | WriteIntValueToReg(hKey4, "MakeDir", MakeAllDir); |
634 | 638 | // UTF-8対応 |
@@ -1037,6 +1041,8 @@ int LoadRegistry(void) | ||
1037 | 1041 | ReadIntValueFromReg(hKey4, "ListIcon", &DispFileIcon); |
1038 | 1042 | // タイムスタンプのバグ修正 |
1039 | 1043 | ReadIntValueFromReg(hKey4, "ListSecond", &DispTimeSeconds); |
1044 | + // ファイルの属性を数字で表示 | |
1045 | + ReadIntValueFromReg(hKey4, "ListPermitNum", &DispPermissionsNumber); | |
1040 | 1046 | // ディレクトリ自動作成 |
1041 | 1047 | ReadIntValueFromReg(hKey4, "MakeDir", &MakeAllDir); |
1042 | 1048 | // UTF-8対応 |