mirror of
https://github.com/elasota/Aerofoil.git
synced 2025-12-14 12:09:36 +00:00
Most remaining level editor work
This commit is contained in:
@@ -91,6 +91,8 @@ namespace PortabilityLayer
|
||||
|
||||
int16_t ExecuteModal(DialogFilterFunc_t filterFunc) override;
|
||||
|
||||
bool ReplaceWidget(unsigned int itemIndex, Widget *widget) override;
|
||||
|
||||
bool Populate(DialogTemplate *tmpl, const DialogTextSubstitutions *substitutions);
|
||||
|
||||
void DrawControls(bool redraw);
|
||||
@@ -390,6 +392,19 @@ namespace PortabilityLayer
|
||||
}
|
||||
}
|
||||
|
||||
bool DialogImpl::ReplaceWidget(unsigned int itemIndex, Widget *widget)
|
||||
{
|
||||
DialogItem &item = m_items[itemIndex];
|
||||
Widget *oldWidget = item.GetWidget();
|
||||
|
||||
if (!m_window->ReplaceWidget(oldWidget, widget))
|
||||
return false;
|
||||
|
||||
m_items[itemIndex].m_widget = widget;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool DialogImpl::Populate(DialogTemplate *tmpl, const DialogTextSubstitutions *substitutions)
|
||||
{
|
||||
Window *window = this->GetWindow();
|
||||
|
||||
Reference in New Issue
Block a user