mirror of
https://github.com/switchbrew/libnx.git
synced 2025-07-04 18:42:15 +02:00
Make use of NX_CONSTEXPR
This commit is contained in:
parent
304cbe735d
commit
0acbc22be0
@ -62,21 +62,29 @@ void pselUiAddInvalidUser(PselUiSettings *ui, AccountUid *user_id);
|
|||||||
* @param flag Flag value.
|
* @param flag Flag value.
|
||||||
* @note Only used for ::PselUiMode_SelectUser
|
* @note Only used for ::PselUiMode_SelectUser
|
||||||
*/
|
*/
|
||||||
void pselUiSetAllowUserCreation(PselUiSettings *ui, bool flag);
|
NX_CONSTEXPR void pselUiSetAllowUserCreation(PselUiSettings *ui, bool flag) {
|
||||||
|
if(ui->mode == PselUiMode_SelectUser) {
|
||||||
|
ui->allowUserCreation = flag;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Sets whether users need to be linked to a Nintendo account.
|
* @brief Sets whether users need to be linked to a Nintendo account.
|
||||||
* @param ui PselUiSettings struct.
|
* @param ui PselUiSettings struct.
|
||||||
* @param flag Flag value.
|
* @param flag Flag value.
|
||||||
*/
|
*/
|
||||||
void pselUiSetNetworkServiceRequired(PselUiSettings *ui, bool flag);
|
NX_CONSTEXPR void pselUiSetNetworkServiceRequired(PselUiSettings *ui, bool flag) {
|
||||||
|
ui->networkServiceRequired = flag;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Sets whether selection can be skipped (with a new button)
|
* @brief Sets whether selection can be skipped (with a new button)
|
||||||
* @param ui PselUiSettings struct.
|
* @param ui PselUiSettings struct.
|
||||||
* @param flag Flag value.
|
* @param flag Flag value.
|
||||||
*/
|
*/
|
||||||
void pselUiSetSkipEnabled(PselUiSettings *ui, bool flag);
|
NX_CONSTEXPR void pselUiSetSkipEnabled(PselUiSettings *ui, bool flag) {
|
||||||
|
ui->skipEnabled = flag;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Shows the applet with the specified UI settings.
|
* @brief Shows the applet with the specified UI settings.
|
||||||
|
@ -24,20 +24,6 @@ void pselUiAddInvalidUser(PselUiSettings *ui, AccountUid *user_id) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void pselUiSetAllowUserCreation(PselUiSettings *ui, bool flag) {
|
|
||||||
if(ui->mode == PselUiMode_SelectUser) {
|
|
||||||
ui->allowUserCreation = flag;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
void pselUiSetNetworkServiceRequired(PselUiSettings *ui, bool flag) {
|
|
||||||
ui->networkServiceRequired = flag;
|
|
||||||
}
|
|
||||||
|
|
||||||
void pselUiSetSkipEnabled(PselUiSettings *ui, bool flag) {
|
|
||||||
ui->skipEnabled = flag;
|
|
||||||
}
|
|
||||||
|
|
||||||
static u32 _pselGetLaVersion() {
|
static u32 _pselGetLaVersion() {
|
||||||
u32 ver = 0;
|
u32 ver = 0;
|
||||||
u32 hosver = hosversionGet();
|
u32 hosver = hosversionGet();
|
||||||
|
Loading…
Reference in New Issue
Block a user