This commit is contained in:
janisslsm committed 2026-11-01 12:12:55 +02:00
1 parent 1781d25a15
commit 732c0ad767
33051 files changed
+2591613 -3019689

No files matched your search

@@ -0,0 +1,30 @@
// Metro module 14603 (f14604).
import { useRef, useEffect } from "react";
import { isMetaQuest } from "../../device/MetaQuestUtils.android";
import { lockOrientation, unlockOrientation } from "../../device/native/DeviceOrientation";
let c10295_3 = 0;
export function useShopOrientationLock() {
const ref = useRef(false);
useEffect(() => {
if (isMetaQuest()) {
return void 0;
}
if (c10295_3 === 0) {
lockOrientation("PORTRAIT", true);
}
ref.current = true;
c10295_3 = c10295_3 + 1;
return () => {
if (ref.current) {
const r0 = c10295_3 - 1;
c10295_3 = r0;
if (r0 === 0) {
unlockOrientation({
unlockAfterRotatingToPreviousLock: false
});
}
ref.current = false;
}
};
}, []);
}