フレニコのアンケート選択肢をHTMLとして解釈する

This commit is contained in:
tateisu 2019-01-05 19:43:17 +09:00
parent 71630b8841
commit 97147b6c86
2 changed files with 4 additions and 2 deletions

View File

@ -50,6 +50,7 @@
<w>navi</w> <w>navi</w>
<w>nicodic</w> <w>nicodic</w>
<w>nicoru</w> <w>nicoru</w>
<w>nicovideo</w>
<w>noto</w> <w>noto</w>
<w>nsfw</w> <w>nsfw</w>
<w>okhttp</w> <w>okhttp</w>

View File

@ -184,13 +184,14 @@ class NicoEnquete(
val options = DecodeOptions( val options = DecodeOptions(
context, context,
emojiMapCustom = status.custom_emojis, emojiMapCustom = status.custom_emojis,
emojiMapProfile = status.profile_emojis emojiMapProfile = status.profile_emojis,
decodeEmoji = true
) )
for(i in 0 until size) { for(i in 0 until size) {
val text = reWhitespace val text = reWhitespace
.matcher(stringArray[i].sanitizeBDI()) .matcher(stringArray[i].sanitizeBDI())
.replaceAll(" ") .replaceAll(" ")
val decoded_text = options.decodeEmoji(text) val decoded_text = options.decodeHTML(text)
items.add(Choice(text, decoded_text)) items.add(Choice(text, decoded_text))
} }