mirror of
https://github.com/switchbrew/libnx.git
synced 2025-06-21 20:42:44 +02:00
Verify that the version is 2.0.0+ in swkbdInlineCreate.
This commit is contained in:
parent
11b7bece4a
commit
e3f021bab3
@ -390,7 +390,7 @@ void swkbdConfigSetTextCheckCallback(SwkbdConfig* c, SwkbdTextCheckCb cb);
|
||||
Result swkbdShow(SwkbdConfig* c, char* out_string, size_t out_string_size);
|
||||
|
||||
/**
|
||||
* @brief Creates a SwkbdInline object.
|
||||
* @brief Creates a SwkbdInline object. Only available on 2.0.0+.
|
||||
* @note This is essentially an asynchronous version of the regular swkbd.
|
||||
* @note This calls \ref swkbdInlineSetUtf8Mode internally with flag=true.
|
||||
* @param s SwkbdInline object.
|
||||
|
@ -347,6 +347,9 @@ Result swkbdInlineCreate(SwkbdInline* s) {
|
||||
|
||||
_swkbdInitVersion(&s->version);
|
||||
|
||||
//swkbd-inline is only available on 2.0.0+.
|
||||
if (s->version < 0x10006) return MAKERESULT(Module_Libnx, LibnxError_IncompatSysVer);
|
||||
|
||||
s->calcArg.unk_x0 = 0x30000;
|
||||
s->calcArg.size = sizeof(s->calcArg);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user