bSupportsITunesFileSharing
bSupportsITunesFileSharing
#Overview
name: bSupportsITunesFileSharing
The value of this variable can be defined or overridden in .ini config files. 1
.ini config file referencing this setting variable.
It is referenced in 3
C++ source files. Also referenced in 3
C# build files meaning it may affect the build system logic.
#Summary
#Usage in the C++ source code
The purpose of bSupportsITunesFileSharing is to control whether files created by the app will be accessible from the iTunes File Sharing feature on iOS devices.
This setting variable is primarily used in the iOS platform-specific modules of Unreal Engine 5. It is referenced in the IOSPlatformEditor and IOSRuntimeSettings modules, which are responsible for iOS-specific configurations and runtime settings.
The value of this variable is initially set to false in the IOSRuntimeSettings constructor (IOSRuntimeSettings.cpp). However, it can be modified through the Unreal Engine editor interface, as it is exposed as an editable property in the IOSRuntimeSettings class.
This variable interacts closely with the bSupportsFilesApp variable. The bSupportsFilesApp setting is dependent on bSupportsITunesFileSharing, as indicated by the EditCondition meta tag in the property declaration.
Developers must be aware that enabling this feature will make files created by the app accessible through iTunes File Sharing. This can have implications for data privacy and security, so it should be used judiciously.
Best practices when using this variable include:
- Only enable it if your app needs to share files with users through iTunes.
- Ensure that sensitive data is not inadvertently exposed through this feature.
- If enabling this feature, consider also enabling bSupportsFilesApp for better integration with the iOS Files app.
- Document the use of this feature in your app’s privacy policy and user guide.
- Test thoroughly to ensure that only intended files are shared and that the feature works as expected across different iOS versions.
#Usage in the C# source code and build system
The purpose of bSupportsITunesFileSharing is to enable or disable iTunes file sharing support for iOS applications built with Unreal Engine 5. This setting is specifically related to the iOS platform and affects how files can be shared between the app and iTunes on a connected computer.
This setting variable is primarily used by the iOS-specific subsystems of Unreal Engine 5. Based on the references in the C# build files, it is utilized in the iOS build process, specifically in the UEBuildIOS and UEDeployIOS classes.
The value of this variable is set in the Unreal Engine project settings, specifically in the iOS Runtime Settings section. It can be accessed and modified through the project’s configuration files or the Unreal Editor’s Project Settings menu.
There is an associated variable called bSupportsFilesApp, which is often read alongside bSupportsITunesFileSharing. This variable determines whether the app supports the iOS Files app for file management.
Developers must be aware that enabling iTunes file sharing allows users to access certain app files through iTunes when the device is connected to a computer. This can be useful for debugging or allowing users to easily transfer files, but it also exposes parts of the app’s file system.
Best practices when using this variable include:
- Only enable it when necessary, as it can potentially expose sensitive data.
- Ensure that any files that shouldn’t be accessible are properly secured or stored in locations not shared with iTunes.
- Consider the implications on app size and performance, as supporting file sharing may require additional resources.
- Test thoroughly to ensure that file sharing works as expected and doesn’t introduce any security vulnerabilities.
Regarding the associated variable bSupportsFilesApp:
The purpose of bSupportsFilesApp is to enable or disable support for the iOS Files app in the Unreal Engine iOS application. This setting determines whether the app can interact with the iOS Files app, allowing users to access and manage files within the app through the system-wide file management interface.
Like bSupportsITunesFileSharing, this variable is used in the iOS-specific subsystems of Unreal Engine 5, particularly in the deployment process handled by UEDeployIOS.
The value of bSupportsFilesApp is also set in the iOS Runtime Settings section of the project settings.
Developers should be aware that enabling Files app support allows users to access and manage app files through the iOS Files app, which can be beneficial for user experience but may also require additional considerations for file security and organization.
Best practices for using bSupportsFilesApp include:
- Carefully consider which files and directories should be exposed to the Files app.
- Implement proper file management within the app to handle potential changes made through the Files app.
- Test thoroughly to ensure that file access and modifications through the Files app don’t cause unexpected behavior in the application.
- Consider the impact on app performance and storage usage when enabling this feature.
Both of these variables work together to define how users can interact with files in your iOS application, so they should be configured thoughtfully based on the app’s requirements and intended user experience.
#Setting Variables
#References In INI files
Location: <Workspace>/Engine/Config/BaseEngine.ini:2980, section: [/Script/IOSRuntimeSettings.IOSRuntimeSettings]
- INI Section:
/Script/IOSRuntimeSettings.IOSRuntimeSettings
- Raw value:
False
- Is Array:
False
#References in C++ code
#Callsites
This variable is referenced in the following C++ source code:
#Loc: <Workspace>/Engine/Source/Developer/IOS/IOSPlatformEditor/Private/IOSTargetSettingsCustomization.cpp:806
Scope: file
Source code excerpt:
SETUP_PLIST_PROP(PreferredLandscapeOrientation, OrientationCategory);
SETUP_PLIST_PROP(bSupportsITunesFileSharing, FileSystemCategory);
SETUP_PLIST_PROP(bSupportsFilesApp, FileSystemCategory);
SETUP_PLIST_PROP(bSupportsMetal, RenderCategory);
MRTPropertyHandle = DetailLayout.GetProperty(GET_MEMBER_NAME_CHECKED(UIOSRuntimeSettings, bSupportsMetalMRT));
MRTPropertyHandle->SetOnPropertyValueChanged(OnEnableMetalMRT);
#Loc: <Workspace>/Engine/Source/Runtime/IOS/IOSRuntimeSettings/Classes/IOSRuntimeSettings.h:380
Scope (from outer to inner):
file
class class UIOSRuntimeSettings : public UObject
Source code excerpt:
// Whether files created by the app will be accessible from the iTunes File Sharing feature
UPROPERTY(GlobalConfig, EditAnywhere, Category = FileSystem, meta = (DisplayName = "Support iTunes File Sharing"))
uint32 bSupportsITunesFileSharing : 1;
// Whether files created by the app will be accessible from within the device's Files app (requires iTunes File Sharing)
UPROPERTY(GlobalConfig, EditAnywhere, Category = FileSystem, meta = (DisplayName = "Support Files App", EditCondition = "bSupportsITunesFileSharing"))
uint32 bSupportsFilesApp : 1;
// The Preferred Orientation will be used as the initial orientation at launch when both Landscape Left and Landscape Right orientations are to be supported.
#Loc: <Workspace>/Engine/Source/Runtime/IOS/IOSRuntimeSettings/Private/IOSRuntimeSettings.cpp:29
Scope (from outer to inner):
file
function UIOSRuntimeSettings::UIOSRuntimeSettings
Source code excerpt:
bUserSwitching = false;
bSupportsPortraitOrientation = true;
bSupportsITunesFileSharing = false;
bSupportsFilesApp = false;
BundleDisplayName = TEXT("UnrealGame");
BundleName = TEXT("MyUnrealGame");
BundleIdentifier = TEXT("com.YourCompany.GameNameNoSpaces");
VersionInfo = TEXT("1.0.0");
FrameRateLock = EPowerUsageFrameRateLock::PUFRL_30;
#References in C# build files
This variable is referenced in the following C# build files:
Location: <Workspace>/Engine/Source/Programs/UnrealBuildTool/Platform/IOS/UEBuildIOS.cs:302
/// true if iTunes file sharing support is enabled
/// </summary>
[ConfigFile(ConfigHierarchyType.Engine, "/Script/IOSRuntimeSettings.IOSRuntimeSettings", "bSupportsITunesFileSharing")]
public readonly bool bFileSharingEnabled = false;
/// <summary>
/// The bundle identifier
/// </summary>
[ConfigFile(ConfigHierarchyType.Engine, "/Script/IOSRuntimeSettings.IOSRuntimeSettings", "BundleIdentifier")]
Location: <Workspace>/Engine/Source/Programs/UnrealBuildTool/Platform/IOS/UEDeployIOS.cs:601
// ITunes file sharing
bool bSupportsITunesFileSharing = false;
Ini.GetBool("/Script/IOSRuntimeSettings.IOSRuntimeSettings", "bSupportsITunesFileSharing", out bSupportsITunesFileSharing);
bool bSupportsFilesApp = false;
Ini.GetBool("/Script/IOSRuntimeSettings.IOSRuntimeSettings", "bSupportsFilesApp", out bSupportsFilesApp);
// bundle display name
string BundleDisplayName;
Ini.GetString("/Script/IOSRuntimeSettings.IOSRuntimeSettings", "BundleDisplayName", out BundleDisplayName);
Location: <Workspace>/Engine/Source/Programs/UnrealBuildTool/Platform/IOS/UEDeployIOS.cs:268
// ITunes file sharing
bool bSupportsITunesFileSharing = false;
Ini.GetBool("/Script/IOSRuntimeSettings.IOSRuntimeSettings", "bSupportsITunesFileSharing", out bSupportsITunesFileSharing);
bool bSupportsFilesApp = false;
Ini.GetBool("/Script/IOSRuntimeSettings.IOSRuntimeSettings", "bSupportsFilesApp", out bSupportsFilesApp);
// disable https requirement
bool bDisableHTTPS;
Ini.GetBool("/Script/IOSRuntimeSettings.IOSRuntimeSettings", "bDisableHTTPS", out bDisableHTTPS);