Skip to content

Commit

Permalink
Bug 562091 - Remove the EUC-KR conveter and rename x-windows-949 to E…
Browse files Browse the repository at this point in the history
…UC-KR. r=smontagu
  • Loading branch information
vyv03354 committed Nov 13, 2012
1 parent 521b7c1 commit dc1a0b2
Show file tree
Hide file tree
Showing 20 changed files with 22 additions and 156 deletions.
4 changes: 2 additions & 2 deletions browser/components/migration/src/SafariProfileMigrator.js
Original file line number Diff line number Diff line change
Expand Up @@ -337,9 +337,9 @@ Preferences.prototype = {
this._set("WebKitDefaultTextEncodingName", "intl.charset.default",
function(webkitCharset) {
// We don't support x-mac-korean (see bug 713516), but it mostly matches
// x-windows-949.
// EUC-KR.
if (webkitCharset == "x-mac-korean")
return "x-windows-949";
return "EUC-KR";

// getCharsetAlias throws if an invalid value is passed in.
try {
Expand Down
7 changes: 0 additions & 7 deletions dom/encoding/TextDecoder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -206,13 +206,6 @@ TextDecoder::GetEncoding(nsAString& aEncoding)
return;
}

// Similarly, "x-windows-949" is used for the "euc-kr" family. Therefore, if
// the internal encoding name is "x-windows-949", "euc-kr" is returned.
if (mEncoding.EqualsLiteral("x-windows-949")) {
aEncoding.AssignLiteral("euc-kr");
return;
}

CopyASCIItoUTF16(mEncoding, aEncoding);
nsContentUtils::ASCIIToLower(aEncoding);
}
Expand Down
20 changes: 10 additions & 10 deletions dom/encoding/labelsencodings.properties
Original file line number Diff line number Diff line change
Expand Up @@ -205,16 +205,16 @@ shift_jis=Shift_JIS
sjis=Shift_JIS
windows-31j=Shift_JIS
x-sjis=Shift_JIS
cseuckr=x-windows-949
csksc56011987=x-windows-949
euc-kr=x-windows-949
iso-ir-149=x-windows-949
korean=x-windows-949
ks_c_5601-1987=x-windows-949
ks_c_5601-1989=x-windows-949
ksc5601=x-windows-949
ksc_5601=x-windows-949
windows-949=x-windows-949
cseuckr=EUC-KR
csksc56011987=EUC-KR
euc-kr=EUC-KR
iso-ir-149=EUC-KR
korean=EUC-KR
ks_c_5601-1987=EUC-KR
ks_c_5601-1989=EUC-KR
ksc5601=EUC-KR
ksc_5601=EUC-KR
windows-949=EUC-KR
csiso2022kr=ISO-2022-KR
iso-2022-kr=ISO-2022-KR
utf-16=UTF-16LE
Expand Down
1 change: 0 additions & 1 deletion dom/locales/en-US/chrome/charsetTitles.properties
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ gbk.title = Chinese Simplified (GBK)
iso-2022-cn.title = Chinese Simplified (ISO-2022-CN)
euc-kr.title = Korean (EUC-KR)
x-johab.title = Korean (JOHAB)
x-windows-949.title = Korean (UHC)
iso-2022-kr.title = Korean (ISO-2022-KR)
utf-7.title = Unicode (UTF-7)
utf-8.title = Unicode (UTF-8)
Expand Down
3 changes: 1 addition & 2 deletions dom/plugins/base/nsPluginInstanceOwner.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -964,7 +964,7 @@ static const moz2javaCharset charsets[] =
{"windows-1257", "Cp1257"},
{"windows-1258", "Cp1258"},
{"EUC-JP", "EUC_JP"},
{"EUC-KR", "EUC_KR"},
{"EUC-KR", "MS949"},
{"x-euc-tw", "EUC_TW"},
{"gb18030", "GB18030"},
{"gbk", "GBK"},
Expand All @@ -982,7 +982,6 @@ static const moz2javaCharset charsets[] =
{"x-johab", "Johab"},
{"KOI8-R", "KOI8_R"},
{"TIS-620", "MS874"},
{"x-windows-949", "MS949"},
{"x-mac-arabic", "MacArabic"},
{"x-mac-croatian", "MacCroatia"},
{"x-mac-cyrillic", "MacCyrillic"},
Expand Down
10 changes: 2 additions & 8 deletions intl/locale/src/charsetalias.properties
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,6 @@ x-iso-10646-ucs-2-be=UTF-16BE
x-iso-10646-ucs-2-le=UTF-16LE
x-user-defined=x-user-defined
x-johab=x-johab
x-windows-949=x-windows-949
#
# Aliases for ISO-8859-1
#
Expand Down Expand Up @@ -277,20 +276,15 @@ zh_tw-big5=Big5
# Aliases for EUC-KR
#
cseuckr=EUC-KR
# The following are really not aliases EUC-KR, add them only for MS FrontPage
#ks_c_5601-1987=EUC-KR
ks_c_5601-1987=EUC-KR
iso-ir-149=EUC-KR
ks_c_5601-1989=EUC-KR
ksc_5601=EUC-KR
ksc5601=EUC-KR
korean=EUC-KR
csksc56011987=EUC-KR
5601=EUC-KR
#
# Aliases for X-Windows-949, CP949, Unified Hangul Code (UHC)
#
# Microsoft uses ks_c_5601-1987 to mean Windows-949 or its subset EUC-KR.
ks_c_5601-1987=x-windows-949
windows-949=EUC-KR
#
# Aliases for GB2312
#
Expand Down
2 changes: 1 addition & 1 deletion intl/locale/src/windows/wincharset.properties
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
acp.874=TIS-620
acp.932=Shift_JIS
acp.936=gb18030
acp.949=x-windows-949
acp.949=EUC-KR
acp.950=Big5
acp.951=Big5-HKSCS
acp.1250=windows-1250
Expand Down
2 changes: 1 addition & 1 deletion intl/uconv/directory.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ The following directories contain different charset converters:
ucvcn - Simplified Chinese charsets - GB2312, HZ, ISO-2022-CN, GBK, GB18030
ucvibm - IBM charsets - CP850, 852, 855, 857, 862, 864, 869, 1125, 1131
ucvja - Japanese charsets - Shift-JIS, ISO-2022-JP, EUC-JP
ucvko - Korean charsets - ISO-2022-KR, EUC-KR, CP949
ucvko - Korean charsets - ISO-2022-KR, EUC-KR, Johab
ucvlatin - Latin charsets and others - ISO-8859-x, CP1250-1258
CP866, 874, ARMSCII, ISO-IR-111, KOI8,
Mac charsets, T61, TIS620, TCVN, VISCII, VPS
Expand Down
3 changes: 0 additions & 3 deletions intl/uconv/src/charsetData.properties
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ ibm1131.notForOutgoing = true
iso-8859-8-e.notForOutgoing = true
iso-8859-8.notForOutgoing = true
iso-2022-kr.notForOutgoing = true
x-windows-949.notForOutgoing = true
x-johab.notForOutgoing = true


Expand Down Expand Up @@ -186,7 +185,6 @@ x-mac-romanian.LangGroup = x-central-euro
x-user-defined.LangGroup = x-user-def
ks_c_5601-1987.LangGroup = ko
x-johab.LangGroup = ko
x-windows-949.LangGroup = ko
x-mac-hebrew.LangGroup = he
x-mac-arabic.LangGroup = ar
x-sun-unicode-india-0.LangGroup = x-devanagari
Expand All @@ -204,6 +202,5 @@ hz-gb-2312.isMultibyte = true
iso-2022-kr.isMultibyte = true
euc-kr.isMultibyte = true
x-johab.isMultibyte = true
x-windows-949.isMultibyte = true
utf-7.isMultibyte = true
utf-8.isMultibyte = true
13 changes: 2 additions & 11 deletions intl/uconv/src/nsUConvModule.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -210,8 +210,6 @@
// ucvko
#include "nsUCvKOCID.h"
#include "nsUCvKODll.h"
#include "nsEUCKRToUnicode.h"
#include "nsUnicodeToEUCKR.h"
#include "nsJohabToUnicode.h"
#include "nsUnicodeToJohab.h"
#include "nsCP949ToUnicode.h"
Expand Down Expand Up @@ -333,7 +331,6 @@ NS_UCONV_REG_UNREG_ENCODER("hkscs-1" , NS_UNICODETOHKSCS_CID)
// ucvko
NS_UCONV_REG_UNREG("EUC-KR", NS_EUCKRTOUNICODE_CID, NS_UNICODETOEUCKR_CID)
NS_UCONV_REG_UNREG("x-johab", NS_JOHABTOUNICODE_CID, NS_UNICODETOJOHAB_CID)
NS_UCONV_REG_UNREG("x-windows-949", NS_CP949TOUNICODE_CID, NS_UNICODETOCP949_CID)
NS_UCONV_REG_UNREG_DECODER("ISO-2022-KR", NS_ISO2022KRTOUNICODE_CID)

// ucvcn
Expand Down Expand Up @@ -687,8 +684,6 @@ NS_DEFINE_NAMED_CID(NS_EUCKRTOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOEUCKR_CID);
NS_DEFINE_NAMED_CID(NS_JOHABTOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOJOHAB_CID);
NS_DEFINE_NAMED_CID(NS_CP949TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOCP949_CID);
NS_DEFINE_NAMED_CID(NS_ISO2022KRTOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_GB2312TOUNICODE_CID);
NS_DEFINE_NAMED_CID(NS_UNICODETOGB2312_CID);
Expand Down Expand Up @@ -870,12 +865,10 @@ static const mozilla::Module::CIDEntry kUConvCIDs[] = {
{ &kNS_UNICODETOBIG5HKSCS_CID, false, nullptr, nsUnicodeToBIG5HKSCSConstructor },
{ &kNS_UNICODETOHKSCS_CID, false, nullptr, nsUnicodeToHKSCSConstructor },
{ &kNS_BIG5HKSCSTOUNICODE_CID, false, nullptr, nsBIG5HKSCSToUnicodeConstructor },
{ &kNS_EUCKRTOUNICODE_CID, false, nullptr, nsEUCKRToUnicodeConstructor },
{ &kNS_UNICODETOEUCKR_CID, false, nullptr, nsUnicodeToEUCKRConstructor },
{ &kNS_EUCKRTOUNICODE_CID, false, nullptr, nsCP949ToUnicodeConstructor },
{ &kNS_UNICODETOEUCKR_CID, false, nullptr, nsUnicodeToCP949Constructor },
{ &kNS_JOHABTOUNICODE_CID, false, nullptr, nsJohabToUnicodeConstructor },
{ &kNS_UNICODETOJOHAB_CID, false, nullptr, nsUnicodeToJohabConstructor },
{ &kNS_CP949TOUNICODE_CID, false, nullptr, nsCP949ToUnicodeConstructor },
{ &kNS_UNICODETOCP949_CID, false, nullptr, nsUnicodeToCP949Constructor },
{ &kNS_ISO2022KRTOUNICODE_CID, false, nullptr, nsISO2022KRToUnicodeConstructor },
{ &kNS_GB2312TOUNICODE_CID, false, nullptr, nsGB2312ToUnicodeV2Constructor },
{ &kNS_UNICODETOGB2312_CID, false, nullptr, nsUnicodeToGB2312V2Constructor },
Expand Down Expand Up @@ -1063,8 +1056,6 @@ static const mozilla::Module::ContractIDEntry kUConvContracts[] = {
{ NS_UNICODEENCODER_CONTRACTID_BASE "EUC-KR", &kNS_UNICODETOEUCKR_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "x-johab", &kNS_JOHABTOUNICODE_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "x-johab", &kNS_UNICODETOJOHAB_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "x-windows-949", &kNS_CP949TOUNICODE_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "x-windows-949", &kNS_UNICODETOCP949_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "ISO-2022-KR", &kNS_ISO2022KRTOUNICODE_CID },
{ NS_UNICODEDECODER_CONTRACTID_BASE "GB2312", &kNS_GB2312TOUNICODE_CID },
{ NS_UNICODEENCODER_CONTRACTID_BASE "GB2312", &kNS_UNICODETOGB2312_CID },
Expand Down
2 changes: 0 additions & 2 deletions intl/uconv/tests/unit/test_bug718500.js
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,6 @@ var encoderList = [
"hkscs-1",
"EUC-KR",
"x-johab",
"x-windows-949",
"GB2312",
"gbk",
"HZ-GB-2312",
Expand Down Expand Up @@ -178,7 +177,6 @@ var decoderList = [
"Big5-HKSCS",
"EUC-KR",
"x-johab",
"x-windows-949",
"GB2312",
"gbk",
"HZ-GB-2312",
Expand Down
2 changes: 1 addition & 1 deletion intl/uconv/tests/unit/test_decode_EUCKR_Hangul.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
load('CharsetConversionTests.js');
load('hangulTestStrings.js');

const aliases = [ "euc-kr", "EUC-KR", "iso-ir-149", "ks_c_5601-1989", "ksc_5601", "ksc5601", "korean", "csksc56011987", "5601", "x-windows-949", "ks_c_5601-1987", "cseuckr"];
const aliases = [ "euc-kr", "EUC-KR", "iso-ir-149", "ks_c_5601-1989", "ksc_5601", "ksc5601", "korean", "csksc56011987", "5601", "windows-949", "ks_c_5601-1987", "cseuckr"];

function to8byteHangul(byte3, byte5, byte7)
{
Expand Down
2 changes: 0 additions & 2 deletions intl/uconv/ucvko/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ LIBXUL_LIBRARY = 1


CPPSRCS = \
nsEUCKRToUnicode.cpp \
nsUnicodeToEUCKR.cpp \
nsISO2022KRToUnicode.cpp \
nsCP949ToUnicode.cpp \
nsUnicodeToCP949.cpp \
Expand Down
15 changes: 0 additions & 15 deletions intl/uconv/ucvko/nsEUCKRToUnicode.cpp

This file was deleted.

22 changes: 0 additions & 22 deletions intl/uconv/ucvko/nsEUCKRToUnicode.h

This file was deleted.

8 changes: 0 additions & 8 deletions intl/uconv/ucvko/nsUCvKOCID.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,6 @@
#define NS_UNICODETOISO2022KR_CID \
{ 0xba6151a0, 0x1dfa, 0x11d3, {0xb3, 0xbf, 0x0, 0x80, 0x5f, 0x8a, 0x66, 0x70}}

// Class ID for our UnicodeToCP949 charset converter
#define NS_UNICODETOCP949_CID \
{ 0x9416bfbe, 0x1f93, 0x11d3, {0xb3, 0xbf, 0x0, 0x80, 0x5f, 0x8a, 0x66, 0x70}}

// Class ID for our CP949ToUnicode charset converter
#define NS_CP949TOUNICODE_CID \
{ 0x9416bfbf, 0x1f93, 0x11d3, {0xb3, 0xbf, 0x0, 0x80, 0x5f, 0x8a, 0x66, 0x70}}

// Class ID for our UnicodeToJohab charset converter
// {D9B1F97E-CFA0-80b6-FB92-9972E48E3DCC}
#define NS_UNICODETOJOHAB_CID \
Expand Down
37 changes: 0 additions & 37 deletions intl/uconv/ucvko/nsUnicodeToEUCKR.cpp

This file was deleted.

21 changes: 0 additions & 21 deletions intl/uconv/ucvko/nsUnicodeToEUCKR.h

This file was deleted.

2 changes: 1 addition & 1 deletion modules/libpref/src/init/all.js
Original file line number Diff line number Diff line change
Expand Up @@ -1265,7 +1265,7 @@ pref("intl.menuitems.insertseparatorbeforeaccesskeys","chrome://global/locale/in
pref("intl.charsetmenu.browser.static", "chrome://global/locale/intl.properties");
pref("intl.charsetmenu.browser.more1", "ISO-8859-1, ISO-8859-15, IBM850, macintosh, windows-1252, ISO-8859-14, ISO-8859-7, x-mac-greek, windows-1253, x-mac-icelandic, ISO-8859-10, ISO-8859-3");
pref("intl.charsetmenu.browser.more2", "ISO-8859-4, ISO-8859-13, windows-1257, IBM852, ISO-8859-2, x-mac-ce, windows-1250, x-mac-croatian, IBM855, ISO-8859-5, ISO-IR-111, KOI8-R, x-mac-cyrillic, windows-1251, IBM866, KOI8-U, x-mac-ukrainian, ISO-8859-16, x-mac-romanian");
pref("intl.charsetmenu.browser.more3", "GB2312, gbk, gb18030, HZ-GB-2312, ISO-2022-CN, Big5, Big5-HKSCS, x-euc-tw, EUC-JP, ISO-2022-JP, Shift_JIS, EUC-KR, x-windows-949, x-johab, ISO-2022-KR");
pref("intl.charsetmenu.browser.more3", "GB2312, gbk, gb18030, HZ-GB-2312, ISO-2022-CN, Big5, Big5-HKSCS, x-euc-tw, EUC-JP, ISO-2022-JP, Shift_JIS, EUC-KR, x-johab, ISO-2022-KR");
pref("intl.charsetmenu.browser.more4", "armscii-8, TIS-620, ISO-8859-11, windows-874, IBM857, ISO-8859-9, x-mac-turkish, windows-1254, x-viet-tcvn5712, VISCII, x-viet-vps, windows-1258, x-mac-devanagari, x-mac-gujarati, x-mac-gurmukhi");
pref("intl.charsetmenu.browser.more5", "ISO-8859-6, windows-1256, ISO-8859-8-I, windows-1255, ISO-8859-8, IBM862");
pref("intl.charsetmenu.browser.unicode", "UTF-8, UTF-16LE, UTF-16BE");
Expand Down
2 changes: 1 addition & 1 deletion widget/os2/nsOS2Uni.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ ConverterInfo gConverterInfo[eCONVERTER_COUNT] =
{ 943, "Shift_JIS", nullptr, nullptr },
{ 1381, "GB2312", nullptr, nullptr },
{ 1386, "GB2312", nullptr, nullptr },
{ 949, "x-windows-949", nullptr, nullptr },
{ 949, "EUC-KR", nullptr, nullptr },
{ 950, "Big5", nullptr, nullptr },
{ 1361, "x-johab", nullptr, nullptr }
};
Expand Down

0 comments on commit dc1a0b2

Please sign in to comment.