Changeset 319 for trunk/src/helpers/nls.c
- Timestamp:
- May 31, 2006, 12:18:22 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/helpers/nls.c
r304 r319 22 22 23 23 /* 24 * Copyright (C) 1997-200 2Ulrich Mller.24 * Copyright (C) 1997-2006 Ulrich Mller. 25 25 * This file is part of the "XWorkplace helpers" source package. 26 26 * This is free software; you can redistribute it and/or modify … … 379 379 *@@added V1.0.1 (2003-01-17) [umoeller] 380 380 *@@changed V1.0.4 (2005-10-15) [pr]: Added support for Locale object settings on MCP systems @@fixes 614 381 *@@changed V1.0.5 (2006-05-29) [pr]: Read Country rather than Locale settings on Warp 4 FP13+ @@fixes 614 381 382 */ 382 383 383 384 VOID nlsGetAMPM(PCOUNTRYAMPM pampm) 384 385 { 385 PrfQueryProfileString(HINI_USER, 386 "PM_National", 387 "s2359", // key 388 "PM", // default 389 pampm->sz2359, 390 sizeof(pampm->sz2359)); 391 392 PrfQueryProfileString(HINI_USER, 393 "PM_National", 394 "s1159", // key 395 "AM", // default 396 pampm->sz1159, 397 sizeof(pampm->sz1159)); 398 if (doshIsWarp4()==2) 386 if (doshIsWarp4()==3) // V1.0.5 (2006-05-29) [pr] 399 387 { 400 388 UconvObject uconv_object; … … 465 453 } 466 454 } 455 else 456 { 457 PrfQueryProfileString(HINI_USER, 458 "PM_National", 459 "s2359", // key 460 "PM", // default 461 pampm->sz2359, 462 sizeof(pampm->sz2359)); 463 464 PrfQueryProfileString(HINI_USER, 465 "PM_National", 466 "s1159", // key 467 "AM", // default 468 pampm->sz1159, 469 sizeof(pampm->sz1159)); 470 } 467 471 } 468 472 … … 488 492 *@@changed V1.0.4 (2005-10-15) [bvl]: Added support for Locale object settings on MCP systems @@fixes 614 489 493 *@@changed V1.0.4 (2005-10-29) [pr]: Rewritten to prevent memory leaks and errors 494 *@@changed V1.0.5 (2006-05-29) [pr]: Read Country rather than Locale settings on Warp 4 FP13+ @@fixes 614 490 495 */ 491 496 … … 495 500 { 496 501 PCOUNTRYSETTINGS pcs = &pcs2->cs; 497 pcs->ulDateFormat = PrfQueryProfileInt(HINI_USER, 498 (PSZ)PMINIAPP_NATIONAL, 499 "iDate", 500 0); 501 pcs->ulTimeFormat = PrfQueryProfileInt(HINI_USER, 502 (PSZ)PMINIAPP_NATIONAL, 503 "iTime", 504 0); 505 pcs->cDateSep = prfhQueryProfileChar(HINI_USER, 506 (PSZ)PMINIAPP_NATIONAL, 507 "sDate", 508 '/'); 509 pcs->cTimeSep = prfhQueryProfileChar(HINI_USER, 510 (PSZ)PMINIAPP_NATIONAL, 511 "sTime", 512 ':'); 513 pcs->cDecimal = prfhQueryProfileChar(HINI_USER, 514 (PSZ)PMINIAPP_NATIONAL, 515 "sDecimal", 516 '.'); 517 pcs->cThousands = prfhQueryProfileChar(HINI_USER, 518 (PSZ)PMINIAPP_NATIONAL, 519 "sThousand", 520 ','); 521 if (doshIsWarp4()==2) 502 503 if (doshIsWarp4()==3) // V1.0.5 (2006-05-29) [pr] 522 504 { 523 505 UconvObject uconv_object; … … 591 573 UniFreeUconvObject(uconv_object); 592 574 } 575 } 576 else 577 { 578 pcs->ulDateFormat = PrfQueryProfileInt(HINI_USER, 579 (PSZ)PMINIAPP_NATIONAL, 580 "iDate", 581 0); 582 pcs->ulTimeFormat = PrfQueryProfileInt(HINI_USER, 583 (PSZ)PMINIAPP_NATIONAL, 584 "iTime", 585 0); 586 pcs->cDateSep = prfhQueryProfileChar(HINI_USER, 587 (PSZ)PMINIAPP_NATIONAL, 588 "sDate", 589 '/'); 590 pcs->cTimeSep = prfhQueryProfileChar(HINI_USER, 591 (PSZ)PMINIAPP_NATIONAL, 592 "sTime", 593 ':'); 594 pcs->cDecimal = prfhQueryProfileChar(HINI_USER, 595 (PSZ)PMINIAPP_NATIONAL, 596 "sDecimal", 597 '.'); 598 pcs->cThousands = prfhQueryProfileChar(HINI_USER, 599 (PSZ)PMINIAPP_NATIONAL, 600 "sThousand", 601 ','); 593 602 } 594 603
Note:
See TracChangeset
for help on using the changeset viewer.