APCJSA enabling dialog added
This commit is contained in:
@@ -143,6 +143,30 @@ class MainActivity : AppCompatActivity() {
|
||||
|
||||
preference.edit().putBoolean("https_block_alert", true).apply()
|
||||
}
|
||||
|
||||
if (!preference.getBoolean("apcjsa_option", false)) {
|
||||
android.app.AlertDialog.Builder(this).apply {
|
||||
setTitle(R.string.apcjsa_option_title)
|
||||
setMessage(R.string.apcjsa_option_message)
|
||||
setPositiveButton(android.R.string.yes) { _, _ ->
|
||||
val tags = Tags.parse(
|
||||
preference.getString("default_query", "") ?: ""
|
||||
)
|
||||
|
||||
tags.add("-female:loli")
|
||||
tags.add("-male:shota")
|
||||
|
||||
preference.edit()
|
||||
.putString("default_query", tags.toString())
|
||||
.putBoolean("cache_disable", true)
|
||||
.putBoolean("apcjsa_option", true)
|
||||
.apply()
|
||||
}
|
||||
setNegativeButton(android.R.string.no) { _, _ -> }
|
||||
}.show()
|
||||
|
||||
preference.edit().putBoolean("apcjsa_option", true).apply()
|
||||
}
|
||||
}
|
||||
|
||||
with(application as Pupil) {
|
||||
|
||||
@@ -147,4 +147,6 @@
|
||||
<string name="default_query_dialog_filter_loli">登場人物を全て18歳以上にする</string>
|
||||
<string name="settings_cache_disable">キャッシュを使用しない</string>
|
||||
<string name="settings_download_when_cache_disable_warning">キャッシュを使用しないため、ダウンロードできません</string>
|
||||
<string name="apcjsa_option_title">(Korean only)</string>
|
||||
<string name="apcjsa_option_message">(Korean only)</string>
|
||||
</resources>
|
||||
@@ -147,4 +147,6 @@
|
||||
<string name="default_query_dialog_filter_loli">히익 페도</string>
|
||||
<string name="settings_cache_disable">캐시 비활성화</string>
|
||||
<string name="settings_download_when_cache_disable_warning">캐시를 활성화 해야 다운로드를 진행할 수 있습니다</string>
|
||||
<string name="apcjsa_option_title">아청법 대응 옵션 추가</string>
|
||||
<string name="apcjsa_option_message">경찰서 정모 확률을 줄여보고자 캐시 비활성화/태그 필터를 추가하였습니다. 적용하시겠습니까?</string>
|
||||
</resources>
|
||||
@@ -27,6 +27,9 @@
|
||||
<string name="https_block_alert_title">(Korean only)</string>
|
||||
<string name="https_block_alert">(Korean only)</string>
|
||||
|
||||
<string name="apcjsa_option_title">(Korean only)</string>
|
||||
<string name="apcjsa_option_message">(Korean only)</string>
|
||||
|
||||
<string name="update_failed">Update failed</string>
|
||||
<string name="update_failed_message">Please install manually by visiting github release page :{ (or try again!)</string>
|
||||
<string name="update_no_permission">Cannot auto update because permission is denied. Please download manually from the webpage.</string>
|
||||
|
||||
Reference in New Issue
Block a user