mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-13 00:25:19 +02:00
Fix irrlicht version checking macro for tooltip_height calculation
This commit is contained in:
@@ -2265,10 +2265,10 @@ void GUIFormSpecMenu::drawList(const ListDrawSpec &s, int phase,
|
|||||||
this->bringToFront(m_tooltip_element);
|
this->bringToFront(m_tooltip_element);
|
||||||
m_tooltip_element->setText(tooltip_text.c_str());
|
m_tooltip_element->setText(tooltip_text.c_str());
|
||||||
s32 tooltip_width = m_tooltip_element->getTextWidth() + m_btn_height;
|
s32 tooltip_width = m_tooltip_element->getTextWidth() + m_btn_height;
|
||||||
#if IRRLICHT_VERSION_MAJOR >= 1 && IRRLICHT_VERSION_MINOR >= 8 && IRRLICHT_VERSION_REVISION >= 2
|
#if IRRLICHT_VERSION_MAJOR <= 1 && IRRLICHT_VERSION_MINOR <= 8 && IRRLICHT_VERSION_REVISION < 2
|
||||||
s32 tooltip_height = m_tooltip_element->getTextHeight() + 5;
|
|
||||||
#else
|
|
||||||
s32 tooltip_height = m_tooltip_element->getTextHeight() * tt_rows.size() + 5;
|
s32 tooltip_height = m_tooltip_element->getTextHeight() * tt_rows.size() + 5;
|
||||||
|
#else
|
||||||
|
s32 tooltip_height = m_tooltip_element->getTextHeight() + 5;
|
||||||
#endif
|
#endif
|
||||||
v2u32 screenSize = driver->getScreenSize();
|
v2u32 screenSize = driver->getScreenSize();
|
||||||
int tooltip_offset_x = m_btn_height;
|
int tooltip_offset_x = m_btn_height;
|
||||||
|
Reference in New Issue
Block a user