mirror of
https://github.com/tapframe/NuvioStreaming.git
synced 2026-04-21 00:32:04 +00:00
parent
0cd94da7ce
commit
54b51391ad
1 changed files with 3 additions and 7 deletions
|
|
@ -112,14 +112,10 @@ export const usePlayerSetup = (
|
||||||
subscription?.remove();
|
subscription?.remove();
|
||||||
disableImmersiveMode();
|
disableImmersiveMode();
|
||||||
|
|
||||||
async function restoreBrightness() {
|
|
||||||
logger.log('yobrrrrrrrrrrrrrr');
|
|
||||||
await Brightness.setBrightnessAsync(originalSystemBrightnessRef.current!).then();
|
|
||||||
setBrightness(originalSystemBrightnessRef.current!);
|
|
||||||
}
|
|
||||||
// Restore brightness on unmount
|
// Restore brightness on unmount
|
||||||
if (Platform.OS === 'android' && originalSystemBrightnessRef.current !== null)
|
if (Platform.OS === 'android' && originalSystemBrightnessRef.current !== null) {
|
||||||
restoreBrightness();
|
// restoration logic normally happens here or in a separate effect
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue