mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Formspec: Fix bgcolor and set_focus checks
This commit is contained in:
parent
5eb45e1ea0
commit
8fab406c28
1 changed files with 2 additions and 2 deletions
|
@ -2250,7 +2250,7 @@ void GUIFormSpecMenu::parseBox(parserData* data, const std::string &element)
|
||||||
void GUIFormSpecMenu::parseBackgroundColor(parserData* data, const std::string &element)
|
void GUIFormSpecMenu::parseBackgroundColor(parserData* data, const std::string &element)
|
||||||
{
|
{
|
||||||
std::vector<std::string> parts;
|
std::vector<std::string> parts;
|
||||||
if (!precheckElement("bgcolor", element, 2, 3, parts))
|
if (!precheckElement("bgcolor", element, 1, 3, parts))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
const u32 parameter_count = parts.size();
|
const u32 parameter_count = parts.size();
|
||||||
|
@ -2705,7 +2705,7 @@ bool GUIFormSpecMenu::parseStyle(parserData *data, const std::string &element, b
|
||||||
void GUIFormSpecMenu::parseSetFocus(const std::string &element)
|
void GUIFormSpecMenu::parseSetFocus(const std::string &element)
|
||||||
{
|
{
|
||||||
std::vector<std::string> parts;
|
std::vector<std::string> parts;
|
||||||
if (!precheckElement("set_focus", element, 2, 2, parts))
|
if (!precheckElement("set_focus", element, 1, 2, parts))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (m_is_form_regenerated)
|
if (m_is_form_regenerated)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue