Own Apple storage paths in Apple platform state

This commit is contained in:
2026-06-17 10:22:02 +02:00
parent af2901e78a
commit 4bef707c81
6 changed files with 21 additions and 3 deletions

View File

@@ -28,6 +28,7 @@ struct RetainedLegacyAppleState final {
View* osx_view = nullptr;
AppOSX* osx_app = nullptr;
#endif
pp::platform::PlatformStoragePaths storage_paths;
};
struct AppleDocumentPickerBridge {
@@ -98,6 +99,7 @@ private:
[[nodiscard]] AppleDocumentPlatformServices&
active_legacy_apple_document_platform_services();
[[nodiscard]] pp::platform::PlatformStoragePaths prepare_legacy_apple_storage_paths();
void set_legacy_apple_storage_paths(pp::platform::PlatformStoragePaths paths);
void set_legacy_apple_state(
#if defined(__OBJC__) && defined(__IOS__)
GameViewController* ios_view,

View File

@@ -221,7 +221,12 @@ struct RetainedLegacyAppleDocumentPlatformState final {
#elif defined(__OSX__)
[apple_state.osx_app init_dirs];
#endif
return pp::platform::legacy::active_legacy_storage_paths();
return apple_state.storage_paths;
}
void set_legacy_apple_storage_paths(pp::platform::PlatformStoragePaths paths)
{
active_legacy_apple_state().storage_paths = std::move(paths);
}
void set_legacy_apple_state(