Skip to content

Commit

Permalink
fix: add autolaunch text after the language loads
Browse files Browse the repository at this point in the history
This also caused many other buttons to not register.
  • Loading branch information
reisxd committed Sep 28, 2024
1 parent 2d15e7e commit 0f76231
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion tizenbrew-app/TizenBrew/config.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<widget xmlns:tizen="http://tizen.org/ns/widgets" xmlns="http://www.w3.org/ns/widgets" id="https://tizentube.vercel.app" version="1.4.0" viewmodes="maximized">
<widget xmlns:tizen="http://tizen.org/ns/widgets" xmlns="http://www.w3.org/ns/widgets" id="https://tizentube.vercel.app" version="1.4.1" viewmodes="maximized">
<access origin="*" subdomains="true"></access>
<tizen:app-control>
<tizen:src name="index.html" reload="disable"/>
Expand Down
11 changes: 8 additions & 3 deletions tizenbrew-app/TizenBrew/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -196,21 +196,26 @@
</script>

<script>
function translateAutolaunch() {
if (localStorage.getItem('autoLaunch') != null) {
document.getElementsByClassName('subtitle')[0].innerHTML += window.i18n.t('mainMenu.autoLaunch');
}
}

if (translationLoaded) {
window.i18n.updateTranslations();
translateAutolaunch();
} else {
window.addEventListener('translationLoaded', () => {
window.i18n.updateTranslations();
translateAutolaunch();
});
}

if (localStorage.getItem('userAgent') != null) {
tizen.websetting.setUserAgentString(localStorage.getItem('userAgent'));
}

if (localStorage.getItem('autoLaunch') != null) {
document.getElementsByClassName('subtitle')[0].innerHTML += window.i18n.t('mainMenu.autoLaunch');
}
tizen.tvinputdevice.registerKey("ColorF1Green");

tizen.tvinputdevice.registerKey("ColorF3Blue");
Expand Down

0 comments on commit 0f76231

Please sign in to comment.