Sdk/BaseWidget: Fix compilation on Linux
This commit is contained in:
parent
55bbc282db
commit
14924f0e74
|
|
@ -24,6 +24,7 @@ Nazara Development Kit:
|
||||||
- ⚠️ Renamed BaseWidget::GrabKeyboard method to SetFocus
|
- ⚠️ Renamed BaseWidget::GrabKeyboard method to SetFocus
|
||||||
- Added BaseWidget::ClearFocus method and OnFocus[Lost|Received] virtual methods
|
- Added BaseWidget::ClearFocus method and OnFocus[Lost|Received] virtual methods
|
||||||
- TextAreaWidget will now show a cursor as long as it has focus
|
- TextAreaWidget will now show a cursor as long as it has focus
|
||||||
|
- Fix BaseWidget linking error on Linux
|
||||||
|
|
||||||
# 0.4:
|
# 0.4:
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -64,6 +64,18 @@ namespace Ndk
|
||||||
SetPosition(GetPosition(Nz::CoordSys_Local).x, (parentSize.y - mySize.y) / 2.f);
|
SetPosition(GetPosition(Nz::CoordSys_Local).x, (parentSize.y - mySize.y) / 2.f);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* \brief Destroy the widget, deleting it in the process.
|
||||||
|
*
|
||||||
|
* Calling this function immediately destroys the widget, freeing its memory.
|
||||||
|
*/
|
||||||
|
inline void BaseWidget::Destroy()
|
||||||
|
{
|
||||||
|
NazaraAssert(this != m_canvas, "Canvas cannot be destroyed by calling Destroy()");
|
||||||
|
|
||||||
|
m_widgetParent->DestroyChild(this); //< This does delete us
|
||||||
|
}
|
||||||
|
|
||||||
inline const Nz::Color& BaseWidget::GetBackgroundColor() const
|
inline const Nz::Color& BaseWidget::GetBackgroundColor() const
|
||||||
{
|
{
|
||||||
return m_backgroundColor;
|
return m_backgroundColor;
|
||||||
|
|
|
||||||
|
|
@ -55,18 +55,6 @@ namespace Ndk
|
||||||
m_canvas->ClearKeyboardOwner(m_canvasIndex);
|
m_canvas->ClearKeyboardOwner(m_canvasIndex);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*!
|
|
||||||
* \brief Destroy the widget, deleting it in the process.
|
|
||||||
*
|
|
||||||
* Calling this function immediately destroys the widget, freeing its memory.
|
|
||||||
*/
|
|
||||||
void BaseWidget::Destroy()
|
|
||||||
{
|
|
||||||
NazaraAssert(this != m_canvas, "Canvas cannot be destroyed by calling Destroy()");
|
|
||||||
|
|
||||||
m_widgetParent->DestroyChild(this); //< This does delete us
|
|
||||||
}
|
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Enable or disables the widget background.
|
* \brief Enable or disables the widget background.
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue