MCPcopy Create free account
hub / github.com/Scobalula/Greyhound / GetDefaultLocaleByRegion

Function GetDefaultLocaleByRegion

src/External/CascLib/src/CascFiles.cpp:567–582  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

565}
566
567static DWORD GetDefaultLocaleByRegion(LPCSTR szRegion)
568{
569 #define CASC_REGION_INT(hi, lo) (((DWORD)(hi) << 0x08) | lo)
570
571 // Setup the default locale
572 switch(CASC_REGION_INT(szRegion[0], szRegion[1]))
573 {
574 case CASC_REGION_INT('u', 's'): return CASC_LOCALE_ENUS;
575 case CASC_REGION_INT('e', 'u'): return CASC_LOCALE_ENGB;
576 case CASC_REGION_INT('c', 'n'): return CASC_LOCALE_ZHCN;
577 case CASC_REGION_INT('k', 'r'): return CASC_LOCALE_KOKR;
578 case CASC_REGION_INT('t', 'w'): return CASC_LOCALE_ZHTW;
579// case CASC_REGION_INT('s', 'g'): return CASC_LOCALE_????;
580 default: return CASC_LOCALE_ENUS;
581 }
582}
583
584static DWORD GetDefaultLocaleMask(const CASC_CSV_COLUMN & Column)
585{

Callers 1

ParseRegionLine_VersionsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected