diff options
author | Igor Pavlov <ipavlov@users.sourceforge.net> | 2015-12-31 03:00:00 +0300 |
---|---|---|
committer | Kornel LesiĆski <kornel@geekhood.net> | 2016-05-28 02:16:58 +0300 |
commit | 9608215ad8deb58355bae27692669fda067c4f43 (patch) | |
tree | 1227131a3f19bc36e5da4ba11791154d05cc08af /CPP/7zip/UI/FileManager/LangUtils.cpp | |
parent | 5de23c1deb52b8be4c43ad9f694c64bbddd0c38a (diff) |
15.1315.13
Diffstat (limited to 'CPP/7zip/UI/FileManager/LangUtils.cpp')
-rw-r--r-- | CPP/7zip/UI/FileManager/LangUtils.cpp | 52 |
1 files changed, 42 insertions, 10 deletions
diff --git a/CPP/7zip/UI/FileManager/LangUtils.cpp b/CPP/7zip/UI/FileManager/LangUtils.cpp index 9723704a..761319b5 100644 --- a/CPP/7zip/UI/FileManager/LangUtils.cpp +++ b/CPP/7zip/UI/FileManager/LangUtils.cpp @@ -140,13 +140,18 @@ void LangString_OnlyFromLangFile(UInt32 langID, UString &dest) } static const char *kLangs = -"ar.bg.ca.zh.-tw.-cn.cs.da.de.el.en.es.fi.fr.he.hu.is.it.ja.ko.nl.no.=nb.=nn." -"pl.pt.-br.rm.ro.ru.sr.=hr.-spl.-spc.sk.sq.sv.th.tr.ur.id.uk.be.sl.et.lv.lt.tg." -"fa.vi.hy.az.eu.hsb.mk...tn..xh.zu.af.ka.fo.hi.mt.se.ga." -".ms.kk.ky.sw.tk.uz.tt.bn.pa.-in.gu.or.ta.te.kn.ml.as.mr.sa.mn.=mn.=mng" -"bo.cy.kh.lo..gl.kok..sd.syr.si..iu.am.tzm.ks.ne.fy.ps.fil." -"dv...ha..yo.quz.nso.ba.lb.kl.ig...ti.....ii." -".arn..moh..br..ug.mi.oc.co.gsw.sah.qut.rw.wo....prs."; + "ar.bg.ca.zh.-tw.-cn.cs.da.de.el.en.es.fi.fr.he.hu.is." + "it.ja.ko.nl.no.=nb.=nn.pl.pt.-br.rm.ro.ru.sr.=hr.-spl.-spc.sk.sq.sv.th.tr." + "ur.id.uk.be.sl.et.lv.lt.tg.fa.vi.hy.az.eu.hsb.mk." + "st.ts.tn.ve.xh.zu.af.ka.fo.hi.mt.se.ga.yi.ms.kk." + "ky.sw.tk.uz.tt.bn.pa.-in.gu.or.ta.te.kn.ml.as.mr.sa." + "mn.=mn.=mng.bo.cy.kh.lo.my.gl.kok..sd.syr.si..iu.am.tzm." + "ks.ne.fy.ps.tl.dv..ff.ha..yo.qu.st.ba.lb.kl." + "ig.kr.om.ti.gn..la.so.ii..arn..moh..br.." + "ug.mi.oc.co." + // "gsw.sah.qut.rw.wo....prs...." + // ".gd." + ; static void FindShortNames(UInt32 primeLang, UStringVector &names) { @@ -158,10 +163,10 @@ static void FindShortNames(UInt32 primeLang, UStringVector &names) bool isSub = (p[0] == '-' || p[0] == '='); if (!isSub) index++; - if (index > primeLang) - break; - if (index == primeLang) + if (index >= primeLang) { + if (index > primeLang) + break; UString s; if (isSub) { @@ -178,6 +183,33 @@ static void FindShortNames(UInt32 primeLang, UStringVector &names) } } +/* +#include "../../../Common/IntToString.h" + +static struct CC1Lang +{ + CC1Lang() + { + for (int i = 1; i < 150; i++) + { + UString s; + char ttt[32]; + ConvertUInt32ToHex(i, ttt); + s.AddAscii(ttt); + UStringVector names; + FindShortNames(i, names); + + FOR_VECTOR (k, names) + { + s.Add_Space(); + s += names[k]; + } + OutputDebugStringW(s); + } + } +} g_cc1; +*/ + // typedef LANGID (WINAPI *GetUserDefaultUILanguageP)(); static void OpenDefaultLang() |