decord/source/modules/auth/native/useOrientationLock.tsx

39 lines
1 KiB
TypeScript
Raw Normal View History

2026-07-27 11:26:19 +00:00
// Module ID: 14845
// Function ID: 113231
2026-07-20 16:05:17 +00:00
// Name: usePortraitOrientationOnly
2026-07-25 08:10:48 +00:00
// Dependencies: [31, 4111, 1553, 9125, 8105, 2]
2026-07-20 16:05:17 +00:00
// Exports: default
2026-07-27 11:26:19 +00:00
// Module 14845 (usePortraitOrientationOnly)
2026-07-23 10:11:24 +00:00
import result from "result";
let require = arg1;
const result = require("isMetaQuest").fileFinishedImporting("modules/auth/native/useOrientationLock.tsx");
2026-07-20 16:05:17 +00:00
export default function usePortraitOrientationOnly() {
2026-07-25 08:10:48 +00:00
let tmp = importDefault(9125)();
2026-07-23 10:11:24 +00:00
const require = tmp;
2026-07-20 16:05:17 +00:00
const items = [tmp];
const effect = React.useEffect(() => {
2026-07-23 10:11:24 +00:00
tmp = !tmp(outer1_2[1]).isIpadOS();
2026-07-20 16:05:17 +00:00
if (tmp) {
2026-07-23 10:11:24 +00:00
tmp = !tmp(outer1_2[2]).isMetaQuest();
const obj2 = tmp(outer1_2[2]);
2026-07-20 16:05:17 +00:00
}
if (tmp) {
tmp = !tmp;
}
if (tmp) {
2026-07-23 10:11:24 +00:00
tmp(outer1_2[4]).lockOrientation("PORTRAIT", false);
const obj3 = tmp(outer1_2[4]);
2026-07-20 16:05:17 +00:00
}
return () => {
if (tmp) {
2026-07-23 10:11:24 +00:00
let obj = tmp(outer2_2[4]);
2026-07-20 16:05:17 +00:00
obj = { unlockAfterRotatingToPreviousLock: false };
obj.unlockOrientation(obj);
}
};
}, items);
};