Commit 8e1303d4 authored by fallenstardust's avatar fallenstardust

更新日志的教程按钮改为打开用户隐私政策

parent 14095533
......@@ -41,8 +41,9 @@
</pre>
<h3 style="color:#ff0000">注意</h3>
<pre>
①:目前32位CPU的手机不能使用单机人机,可以打在线人机。
②:安装本软件时会根据系统语言来设置ygopro的语言,如果觉得不便可以在"我的"里修改资料语言;
①:请注意阅读用户隐私政策;
②:安装本软件时会根据系统语言来设置ygopro的语言,
如果觉得不便可以在"我的"里修改资料语言;
③:卸载本软件将删除包含卡组在内的重要文件,卸载前请慎重;
</pre>
</body>
......
......@@ -86,24 +86,32 @@ public class MainActivity extends HomeActivity implements BottomNavigationBar.On
dialog.showTitleBar();
dialog.setTitle(getString(R.string.settings_about_change_log));
dialog.loadUrl("file:///android_asset/changelog.html", Color.TRANSPARENT);
dialog.setLeftButtonText(R.string.help);
dialog.setLeftButtonText(R.string.user_privacy_policy);
dialog.setLeftButtonListener((dlg, i) -> {
dialog.setContentView(R.layout.dialog_help);
dialog.setTitle(R.string.question);
dialog.hideButton();
dialog.show();
View viewDialog = dialog.getContentView();
Button btnMasterRule = viewDialog.findViewById(R.id.masterrule);
Button btnTutorial = viewDialog.findViewById(R.id.tutorial);
btnMasterRule.setOnClickListener((v) -> {
WebActivity.open(this, getString(R.string.masterrule), Constants.URL_MASTER_RULE_CN);
dialog.dismiss();
});
btnTutorial.setOnClickListener((v) -> {
WebActivity.open(this, getString(R.string.help), Constants.URL_HELP);
dialog.dismiss();
final DialogPlus dialogPlus = new DialogPlus(this);
dialogPlus.setTitle(R.string.user_privacy_policy);
//根据系统语言复制特定资料文件
String language = getContext().getResources().getConfiguration().locale.getLanguage();
String fileaddr = "";
if (!language.isEmpty()) {
if (language.equals(AppsSettings.languageEnum.Chinese.name)) {
fileaddr = "file:///android_asset/user_Privacy_Policy_CN.html";
} else if (language.equals(AppsSettings.languageEnum.Korean.name)) {
fileaddr = "file:///android_asset/user_Privacy_Policy_KO.html";
} else if (language.equals(AppsSettings.languageEnum.Spanish.name)) {
fileaddr = "file:///android_asset/user_Privacy_Policy_ES.html";
} else if (language.equals(AppsSettings.languageEnum.Japanese)) {
fileaddr = "file:///android_asset/user_Privacy_Policy_JP.html";
} else {
fileaddr = "file:///android_asset/user_Privacy_Policy_EN.html";
}
}
dialogPlus.loadUrl(fileaddr, Color.TRANSPARENT);
dialogPlus.setRightButtonListener((dialogInterface, ii) -> {
dialogPlus.dismiss();
});
dialogPlus.show();
});
dialog.setRightButtonText(R.string.OK);
dialog.setRightButtonListener((dlg, i) -> {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment