mirror of
https://gitlab.com/futo-org/fcast.git
synced 2025-06-24 21:25:23 +00:00
Initial TizenOS receiver commit
This commit is contained in:
parent
8c2eb78ef5
commit
2e5746645f
40 changed files with 9881 additions and 0 deletions
27
receivers/tizen/src/main/Renderer.ts
Normal file
27
receivers/tizen/src/main/Renderer.ts
Normal file
|
@ -0,0 +1,27 @@
|
|||
import 'common/main/Renderer';
|
||||
|
||||
const backgroundVideo = document.getElementById('video-player');
|
||||
const loadingScreen = document.getElementById('loading-screen');
|
||||
|
||||
// WebOS 6.0 requires global scope for access during callback invocation
|
||||
// eslint-disable-next-line no-var
|
||||
var backgroundVideoLoaded: boolean;
|
||||
// eslint-disable-next-line no-var
|
||||
var qrCodeRendered: boolean;
|
||||
|
||||
backgroundVideo.onplaying = () => {
|
||||
backgroundVideoLoaded = true;
|
||||
|
||||
if (backgroundVideoLoaded && qrCodeRendered) {
|
||||
loadingScreen.style.display = 'none';
|
||||
backgroundVideo.onplaying = null;
|
||||
}
|
||||
};
|
||||
|
||||
export function onQRCodeRendered() {
|
||||
qrCodeRendered = true;
|
||||
|
||||
if (backgroundVideoLoaded && qrCodeRendered) {
|
||||
loadingScreen.style.display = 'none';
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue