mirror of
https://github.com/switchbrew/libnx.git
synced 2025-07-06 11:22:15 +02:00
FsSaveDataMeta: proper naming convention + FsSaveDataMetaType enum.
This commit is contained in:
parent
8f064f7985
commit
139cb1e99c
@ -88,12 +88,12 @@ typedef struct {
|
|||||||
u8 unused[0x190]; ///< Uninitialized.
|
u8 unused[0x190]; ///< Uninitialized.
|
||||||
} FsSaveDataExtraData;
|
} FsSaveDataExtraData;
|
||||||
|
|
||||||
/// FsSaveMeta
|
/// SaveDataMetaInfo
|
||||||
typedef struct {
|
typedef struct {
|
||||||
u32 meta_file_size;
|
u32 size;
|
||||||
u8 meta_index;
|
u8 type; ///< \ref FsSaveDataMetaType
|
||||||
u8 unk[0x0B];
|
u8 reserved[0x0B];
|
||||||
} FsSaveMeta;
|
} FsSaveDataMetaInfo;
|
||||||
|
|
||||||
/// SaveDataCreationInfo
|
/// SaveDataCreationInfo
|
||||||
typedef struct {
|
typedef struct {
|
||||||
@ -226,6 +226,13 @@ typedef enum {
|
|||||||
FsSaveDataFlags_NeedsSecureDelete = BIT(3),
|
FsSaveDataFlags_NeedsSecureDelete = BIT(3),
|
||||||
} FsSaveDataFlags;
|
} FsSaveDataFlags;
|
||||||
|
|
||||||
|
/// SaveDataMetaType
|
||||||
|
typedef enum {
|
||||||
|
FsSaveDataMetaType_None = 0,
|
||||||
|
FsSaveDataMetaType_Thumbnail = 1,
|
||||||
|
FsSaveDataMetaType_ExtensionContext = 2,
|
||||||
|
} FsSaveDataMetaType;
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
FsGameCardAttribute_AutoBootFlag = BIT(0), ///< Causes the cartridge to automatically start on bootup
|
FsGameCardAttribute_AutoBootFlag = BIT(0), ///< Causes the cartridge to automatically start on bootup
|
||||||
FsGameCardAttribute_HistoryEraseFlag = BIT(1), ///< Causes NS to throw an error on attempt to load the cartridge
|
FsGameCardAttribute_HistoryEraseFlag = BIT(1), ///< Causes NS to throw an error on attempt to load the cartridge
|
||||||
@ -331,7 +338,7 @@ Result fsOpenBisStorage(FsStorage* out, FsBisPartitionId partitionId);
|
|||||||
Result fsOpenSdCardFileSystem(FsFileSystem* out);
|
Result fsOpenSdCardFileSystem(FsFileSystem* out);
|
||||||
|
|
||||||
Result fsDeleteSaveDataFileSystem(u64 application_id);
|
Result fsDeleteSaveDataFileSystem(u64 application_id);
|
||||||
Result fsCreateSaveDataFileSystem(const FsSaveDataAttribute* attr, const FsSaveDataCreationInfo* creation_info, const FsSaveMeta* meta);
|
Result fsCreateSaveDataFileSystem(const FsSaveDataAttribute* attr, const FsSaveDataCreationInfo* creation_info, const FsSaveDataMetaInfo* meta);
|
||||||
Result fsCreateSaveDataFileSystemBySystemSaveDataId(const FsSaveDataAttribute* attr, const FsSaveDataCreationInfo* creation_info);
|
Result fsCreateSaveDataFileSystemBySystemSaveDataId(const FsSaveDataAttribute* attr, const FsSaveDataCreationInfo* creation_info);
|
||||||
Result fsDeleteSaveDataFileSystemBySaveDataSpaceId(FsSaveDataSpaceId save_data_space_id, u64 saveID); ///< [2.0.0+]
|
Result fsDeleteSaveDataFileSystemBySaveDataSpaceId(FsSaveDataSpaceId save_data_space_id, u64 saveID); ///< [2.0.0+]
|
||||||
|
|
||||||
|
@ -228,11 +228,11 @@ Result fsDeleteSaveDataFileSystem(u64 application_id) {
|
|||||||
return _fsObjectDispatchIn(&g_fsSrv, 21, application_id);
|
return _fsObjectDispatchIn(&g_fsSrv, 21, application_id);
|
||||||
}
|
}
|
||||||
|
|
||||||
Result fsCreateSaveDataFileSystem(const FsSaveDataAttribute* attr, const FsSaveDataCreationInfo* creation_info, const FsSaveMeta* meta) {
|
Result fsCreateSaveDataFileSystem(const FsSaveDataAttribute* attr, const FsSaveDataCreationInfo* creation_info, const FsSaveDataMetaInfo* meta) {
|
||||||
const struct {
|
const struct {
|
||||||
FsSaveDataAttribute attr;
|
FsSaveDataAttribute attr;
|
||||||
FsSaveDataCreationInfo creation_info;
|
FsSaveDataCreationInfo creation_info;
|
||||||
FsSaveMeta meta;
|
FsSaveDataMetaInfo meta;
|
||||||
} in = { *attr, *creation_info, *meta };
|
} in = { *attr, *creation_info, *meta };
|
||||||
|
|
||||||
return _fsObjectDispatchIn(&g_fsSrv, 22, in);
|
return _fsObjectDispatchIn(&g_fsSrv, 22, in);
|
||||||
|
Loading…
Reference in New Issue
Block a user