Get rid of private API on macos

This commit is contained in:
chrox
2024-11-11 02:23:06 +01:00
parent a059396008
commit 4e7dd9051b
12 changed files with 558 additions and 61 deletions
@@ -26,6 +26,7 @@ import {
export abstract class BaseAppService implements AppService {
localBooksDir: string = '';
abstract isAppDataSandbox: boolean;
abstract isNativeWindow: boolean;
abstract fs: FileSystem;
abstract resolvePath(fp: string, base: BaseDir): { baseDir: number; base: BaseDir; fp: string };
@@ -115,6 +115,7 @@ export const nativeFileSystem: FileSystem = {
export class NativeAppService extends BaseAppService {
fs = nativeFileSystem;
isAppDataSandbox = isMobile;
isNativeWindow = osType() === 'macos';
override resolvePath(fp: string, base: BaseDir): { baseDir: number; base: BaseDir; fp: string } {
return resolvePath(fp, base);