mirror of
https://github.com/switchbrew/libnx.git
synced 2025-06-21 20:42:44 +02:00
Added setsysGetHomeMenuScheme and setsysGetHomeMenuSchemeModel. Added SetSysHomeMenuScheme. Minor adjustment.
This commit is contained in:
parent
ddafdbd2ac
commit
e5dd8a741d
@ -53,7 +53,13 @@ typedef enum {
|
||||
SetRegion_TWN = 6, ///< Taiwan
|
||||
} SetRegion;
|
||||
|
||||
/// Structure returned by \ref setsysGetFirmwareVersion
|
||||
/// PlatformRegion. Other values not listed here should be handled as "Unknown".
|
||||
typedef enum {
|
||||
SetSysPlatformRegion_Global = 1,
|
||||
SetSysPlatformRegion_China = 2,
|
||||
} SetSysPlatformRegion;
|
||||
|
||||
/// Structure returned by \ref setsysGetFirmwareVersion.
|
||||
typedef struct {
|
||||
u8 major;
|
||||
u8 minor;
|
||||
@ -69,11 +75,14 @@ typedef struct {
|
||||
char display_title[0x80];
|
||||
} SetSysFirmwareVersion;
|
||||
|
||||
/// PlatformRegion. Other values not listed here should be handled as "Unknown".
|
||||
typedef enum {
|
||||
SetSysPlatformRegion_Global = 1,
|
||||
SetSysPlatformRegion_China = 2,
|
||||
} SetSysPlatformRegion;
|
||||
/// Output from \ref setsysGetHomeMenuScheme. This contains RGBA8 colors which correspond with the physical shell of the system.
|
||||
typedef struct {
|
||||
u32 main_color; ///< Main Color.
|
||||
u32 back_color; ///< Back Color.
|
||||
u32 sub_color; ///< Sub Color.
|
||||
u32 bezel_color; ///< Bezel Color.
|
||||
u32 extra_color; ///< Extra Color.
|
||||
} SetSysHomeMenuScheme;
|
||||
|
||||
/// Initialize set.
|
||||
Result setInitialize(void);
|
||||
@ -394,6 +403,13 @@ Result setsysSetHeadphoneVolumeUpdateFlag(bool flag);
|
||||
*/
|
||||
Result setsysGetRequiresRunRepairTimeReviser(bool *out);
|
||||
|
||||
/**
|
||||
* @brief Gets the \ref SetSysHomeMenuScheme.
|
||||
* @note Only available on [9.0.0+].
|
||||
* @param[out] out \ref SetSysHomeMenuScheme
|
||||
*/
|
||||
Result setsysGetHomeMenuScheme(SetSysHomeMenuScheme *out);
|
||||
|
||||
/**
|
||||
* @brief SetRequiresRunRepairTimeReviser
|
||||
* @note Only available on [5.0.0+].
|
||||
@ -414,3 +430,11 @@ Result setsysGetPlatformRegion(SetSysPlatformRegion *region);
|
||||
* @param[in] region \ref SetSysPlatformRegion
|
||||
*/
|
||||
Result setsysSetPlatformRegion(SetSysPlatformRegion region);
|
||||
|
||||
/**
|
||||
* @brief GetHomeMenuSchemeModel
|
||||
* @note This will throw an error when loading the "settings_debug!{...}" system-setting which is used with this fails.
|
||||
* @note Only available on [9.0.0+].
|
||||
* @param[out] out HomeMenuSchemeModel.
|
||||
*/
|
||||
Result setsysGetHomeMenuSchemeModel(u32 *out);
|
||||
|
@ -491,6 +491,13 @@ Result setsysSetRequiresRunRepairTimeReviser(bool flag) {
|
||||
return _setCmdInBoolNoOut(&g_setsysSrv, flag, 142);
|
||||
}
|
||||
|
||||
Result setsysGetHomeMenuScheme(SetSysHomeMenuScheme *out) {
|
||||
if (hosversionBefore(9,0,0))
|
||||
return MAKERESULT(Module_Libnx, LibnxError_IncompatSysVer);
|
||||
|
||||
return serviceDispatchOut(&g_setsysSrv, 174, *out);
|
||||
}
|
||||
|
||||
Result setsysGetPlatformRegion(SetSysPlatformRegion *region) {
|
||||
if (hosversionBefore(9,0,0))
|
||||
return MAKERESULT(Module_Libnx, LibnxError_IncompatSysVer);
|
||||
@ -507,3 +514,10 @@ Result setsysSetPlatformRegion(SetSysPlatformRegion region) {
|
||||
|
||||
return _setCmdInU32NoOut(&g_setsysSrv, region, 184);
|
||||
}
|
||||
|
||||
Result setsysGetHomeMenuSchemeModel(u32 *out) {
|
||||
if (hosversionBefore(9,0,0))
|
||||
return MAKERESULT(Module_Libnx, LibnxError_IncompatSysVer);
|
||||
|
||||
return _setCmdNoInOutU32(&g_setsysSrv, out, 185);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user