Skip to content

Commit

Permalink
Add big5 phonetic databases
Browse files Browse the repository at this point in the history
  • Loading branch information
hosoyu committed Mar 4, 2016
1 parent edd159f commit 7a9651e
Show file tree
Hide file tree
Showing 8 changed files with 37 additions and 6 deletions.
Binary file added Database/phoneticbig5.db
Binary file not shown.
Binary file added Database/phoneticbig5.zip
Binary file not shown.
Binary file added Database/phoneticcompletebig5.db
Binary file not shown.
Binary file added Database/phoneticcompletebig5.zip
Binary file not shown.
9 changes: 8 additions & 1 deletion LimeStudio/app/src/main/java/net/toload/main/hd/Lime.java
Expand Up @@ -71,9 +71,14 @@ public class Lime {
public static final String DATABASE_OPENFOUNDRY_IM_PINYIN = DATABASE_OPENFOUNDRY_URL_BASED + "pinyin.zip";
public static final String DATABASE_CLOUD_IM_PINYIN_KEYBOARD = "lime";

public static final String DATABASE_CLOUD_IM_PHONETICCOMPLETE_BIG5 = DATABASE_CLOUD_URL_BASED + "phoneticcompletebig5.zip";
public static final String DATABASE_OPENFOUNDRY_IM_PHONETICCOMPLETE_BIG5 = DATABASE_OPENFOUNDRY_URL_BASED + "phoneticcompletebig5.zip";

public static final String DATABASE_CLOUD_IM_PHONETICCOMPLETE = DATABASE_CLOUD_URL_BASED + "phoneticcomplete.zip";
public static final String DATABASE_OPENFOUNDRY_IM_PHONETICCOMPLETE = DATABASE_OPENFOUNDRY_URL_BASED + "phoneticcomplete.zip";
public static final String DATABASE_CLOUD_IM_PHONETICCOMPLETE_KEYBOARD = "phonetic";

public static final String DATABASE_CLOUD_IM_PHONETIC_BIG5 = DATABASE_CLOUD_URL_BASED + "phoneticbig5.zip";
public static final String DATABASE_OPENFOUNDRY_IM_PHONETIC_BIG5 = DATABASE_OPENFOUNDRY_URL_BASED + "phoneticbig5.zip";

public static final String DATABASE_CLOUD_IM_PHONETIC = DATABASE_CLOUD_URL_BASED + "phonetic.zip";
public static final String DATABASE_OPENFOUNDRY_IM_PHONETIC = DATABASE_OPENFOUNDRY_URL_BASED + "phonetic.zip";
Expand Down Expand Up @@ -177,6 +182,8 @@ public class Lime {
public static final String IM_HS_V3 = "hs3";
public static final String IM_PHONETIC = "phonetic";
public static final String IM_PHONETIC_ADV = "phoneticadv";
public static final String IM_PHONETIC_BIG5 = "phoneticbig5";
public static final String IM_PHONETIC_ADV_BIG5 = "phoneticadvbig5";
public static final String IM_PINYIN = "pinyin";
public static final String IM_PINYINGB = "pinyin";
public static final String IM_SCJ = "scj";
Expand Down
Expand Up @@ -306,22 +306,34 @@ public void onClick(View v) {

if (imtype.equals(Lime.DB_TABLE_PHONETIC)) {

btnSetupImDialogLoad1.setText(getResources().getString(R.string.l3_im_download_from_phonetic) + " (34,838)");
btnSetupImDialogLoad1.setText(getResources().getString(R.string.l3_im_download_from_phonetic_big5) + " (34,838)");
btnSetupImDialogLoad1.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
downloadAndLoadIm(Lime.DB_TABLE_PHONETIC, Lime.IM_PHONETIC);
downloadAndLoadIm(Lime.DB_TABLE_PHONETIC, Lime.IM_PHONETIC_BIG5);
}
});
btnSetupImDialogLoad2.setText(getResources().getString(R.string.l3_im_download_from_phonetic_adv) + " (95,029)");
btnSetupImDialogLoad2.setText(getResources().getString(R.string.l3_im_download_from_phonetic) + " (34,838)");
btnSetupImDialogLoad2.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
downloadAndLoadIm(Lime.DB_TABLE_PHONETIC, Lime.IM_PHONETIC_ADV);
}
});
btnSetupImDialogLoad3.setVisibility(View.GONE);
btnSetupImDialogLoad4.setVisibility(View.GONE);
btnSetupImDialogLoad3.setText(getResources().getString(R.string.l3_im_download_from_phonetic_adv_big5) + " (95,029)");
btnSetupImDialogLoad3.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
downloadAndLoadIm(Lime.DB_TABLE_PHONETIC, Lime.IM_PHONETIC_ADV_BIG5);
}
});
btnSetupImDialogLoad4.setText(getResources().getString(R.string.l3_im_download_from_phonetic_adv) + " (95,029)");
btnSetupImDialogLoad4.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
downloadAndLoadIm(Lime.DB_TABLE_PHONETIC, Lime.IM_PHONETIC_ADV);
}
});

} else if (imtype.equals(Lime.DB_TABLE_CJ)) {

Expand Down Expand Up @@ -664,6 +676,10 @@ public void downloadAndLoadIm(String code, String type){
url = Lime.DATABASE_CLOUD_IM_ECJHK;
}else if(type.equals(Lime.IM_EZ )){
url = Lime.DATABASE_CLOUD_IM_EZ;
}else if(type.equals(Lime.IM_PHONETIC_BIG5)){
url = Lime.DATABASE_CLOUD_IM_PHONETIC_BIG5;
}else if(type.equals(Lime.IM_PHONETIC_ADV_BIG5)){
url = Lime.DATABASE_CLOUD_IM_PHONETICCOMPLETE_BIG5;
}else if(type.equals(Lime.IM_PHONETIC )){
url = Lime.DATABASE_CLOUD_IM_PHONETIC;
}else if(type.equals(Lime.IM_PHONETIC_ADV )){
Expand Down
Expand Up @@ -508,10 +508,14 @@
<string name="l3_im_download_from_dayi_start">开始下载 OpenVanilla 大易字根</string>
<string name="l3_im_download_from_dayi_install">开始安装 OpenVanilla 大易字根</string>

<string name="l3_im_download_from_phonetic_big5">安装 OpenVanilla 注音字根 (BIG5字集)</string>

<string name="l3_im_download_from_phonetic">安装 OpenVanilla 注音字根</string>
<string name="l3_im_download_from_phonetic_start">开始下载 OpenVanilla 注音字根</string>
<string name="l3_im_download_from_phonetic_install">开始安装 OpenVanilla 注音字根</string>

<string name="l3_im_download_from_phonetic_adv_big5">安装注音连打字根 (BIG5字集)</string>

<string name="l3_im_download_from_phonetic_adv">安装注音连打字根</string>
<string name="l3_im_download_from_phonetic_adv_start">开始下载注音连打字根</string>
<string name="l3_im_download_from_phonetic_adv_install">开始安装注音连打字根</string>
Expand Down
4 changes: 4 additions & 0 deletions LimeStudio/app/src/main/res/values/strings_settings.xml
Expand Up @@ -508,10 +508,14 @@
<string name="l3_im_download_from_dayi_start">開始下載 OpenVanilla 大易字根</string>
<string name="l3_im_download_from_dayi_install">開始安裝 OpenVanilla 大易字根</string>

<string name="l3_im_download_from_phonetic_big5">安裝 OpenVanilla 注音字根 (BIG5字集)</string>

<string name="l3_im_download_from_phonetic">安裝 OpenVanilla 注音字根</string>
<string name="l3_im_download_from_phonetic_start">開始下載 OpenVanilla 注音字根</string>
<string name="l3_im_download_from_phonetic_install">開始安裝 OpenVanilla 注音字根</string>

<string name="l3_im_download_from_phonetic_adv_big5">安裝注音連打字根 (BIG5字集)</string>

<string name="l3_im_download_from_phonetic_adv">安裝注音連打字根</string>
<string name="l3_im_download_from_phonetic_adv_start">開始下載注音連打字根</string>
<string name="l3_im_download_from_phonetic_adv_install">開始安裝注音連打字根</string>
Expand Down

0 comments on commit 7a9651e

Please sign in to comment.