mirror of
https://github.com/streamyfin/streamyfin.git
synced 2026-01-15 23:59:08 +00:00
wip
This commit is contained in:
@@ -69,9 +69,9 @@ export default function index() {
|
|||||||
|
|
||||||
const insets = useSafeAreaInsets();
|
const insets = useSafeAreaInsets();
|
||||||
|
|
||||||
if (!Platform.isTV) {
|
const { downloadedFiles, cleanCacheDirectory } = useDownload();
|
||||||
const { downloadedFiles, cleanCacheDirectory } = useDownload();
|
|
||||||
|
|
||||||
|
if (!Platform.isTV) {
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const hasDownloads = downloadedFiles && downloadedFiles.length > 0;
|
const hasDownloads = downloadedFiles && downloadedFiles.length > 0;
|
||||||
navigation.setOptions({
|
navigation.setOptions({
|
||||||
@@ -91,6 +91,12 @@ export default function index() {
|
|||||||
),
|
),
|
||||||
});
|
});
|
||||||
}, [downloadedFiles, navigation, router]);
|
}, [downloadedFiles, navigation, router]);
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
cleanCacheDirectory().catch((e) =>
|
||||||
|
console.error("Something went wrong cleaning cache directory")
|
||||||
|
);
|
||||||
|
}, []);
|
||||||
}
|
}
|
||||||
|
|
||||||
const checkConnection = useCallback(async () => {
|
const checkConnection = useCallback(async () => {
|
||||||
@@ -111,11 +117,6 @@ export default function index() {
|
|||||||
setIsConnected(state.isConnected);
|
setIsConnected(state.isConnected);
|
||||||
});
|
});
|
||||||
|
|
||||||
if (!Platform.isTV) {
|
|
||||||
cleanCacheDirectory().catch((e) =>
|
|
||||||
console.error("Something went wrong cleaning cache directory")
|
|
||||||
);
|
|
||||||
}
|
|
||||||
return () => {
|
return () => {
|
||||||
unsubscribe();
|
unsubscribe();
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -1 +1,2 @@
|
|||||||
export * from "expo-screen-orientation";
|
export * from "expo-screen-orientation";
|
||||||
|
console.log("LOADED");
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
// export { Orientation, OrientationLock } from "expo-screen-orientation";
|
// export { Orientation, OrientationLock } from "expo-screen-orientation";
|
||||||
|
console.log("NOT");
|
||||||
export enum Orientation {
|
export enum Orientation {
|
||||||
/**
|
/**
|
||||||
* An unknown screen orientation. For example, the device is flat, perhaps on a table.
|
* An unknown screen orientation. For example, the device is flat, perhaps on a table.
|
||||||
Reference in New Issue
Block a user