mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-30 14:16:40 +00:00
locale addon: convert to new settings format
This commit is contained in:
parent
2125e240e2
commit
ef0be61a21
@ -34,10 +34,9 @@ addon() {
|
||||
if [ "${l}" = "POSIX" ]; then
|
||||
continue
|
||||
fi
|
||||
locales+="|${l}"
|
||||
locales+="$(echo -e '\\\n <option>'"${l}"'</option>')"
|
||||
done
|
||||
locales="${locales:1}"
|
||||
|
||||
sed -e "s/@LOCALES@/${locales}/" \
|
||||
sed -e "s|@LOCALES@|${locales}|" \
|
||||
-i ${ADDON_BUILD}/${PKG_ADDON_ID}/resources/settings.xml
|
||||
}
|
||||
|
@ -1,7 +1,37 @@
|
||||
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
|
||||
<settings>
|
||||
<category label="30000">
|
||||
<setting label="30001" id="charmap" type="select" default="UTF-8" values="UTF-8" enable="false" />
|
||||
<setting label="30002" id="locale" type="select" default="en_GB" values="@LOCALES@" />
|
||||
<?xml version="1.0" ?>
|
||||
<settings version="1">
|
||||
<section id="service.locale">
|
||||
<category id="configuration" label="30000" help="">
|
||||
<group id="1">
|
||||
<setting id="charmap" type="string" label="30001" help="">
|
||||
<level>0</level>
|
||||
<default>UTF-8</default>
|
||||
<constraints>
|
||||
<options>
|
||||
<option>UTF-8</option>
|
||||
</options>
|
||||
</constraints>
|
||||
<dependencies>
|
||||
<dependency type="enable">
|
||||
<condition on="property" name="InfoBool">false</condition>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<control type="list" format="string">
|
||||
<heading>30001</heading>
|
||||
</control>
|
||||
</setting>
|
||||
<setting id="locale" type="string" label="30002" help="">
|
||||
<level>0</level>
|
||||
<default>en_GB</default>
|
||||
<constraints>
|
||||
<options>@LOCALES@
|
||||
</options>
|
||||
</constraints>
|
||||
<control type="list" format="string">
|
||||
<heading>30002</heading>
|
||||
</control>
|
||||
</setting>
|
||||
</group>
|
||||
</category>
|
||||
</section>
|
||||
</settings>
|
||||
|
@ -1,4 +1,4 @@
|
||||
<settings>
|
||||
<setting id="charmap" value="UTF-8" />
|
||||
<setting id="locale" value="en_GB" />
|
||||
<settings version="2">
|
||||
<setting id="charmap" default="true">UTF-8</setting>
|
||||
<setting id="locale" default="true>en_GB</setting>
|
||||
</settings>
|
||||
|
Loading…
x
Reference in New Issue
Block a user