libui: Actually fill window backgrounds with the correct color
This commit is contained in:
parent
b2de0d2b84
commit
ca92ff9d96
@ -42,7 +42,7 @@ Result<int> luna_main(int argc, char** argv)
|
|||||||
ColorWidget blue(ui::BLUE);
|
ColorWidget blue(ui::BLUE);
|
||||||
layout.add_widget(blue);
|
layout.add_widget(blue);
|
||||||
|
|
||||||
ui::HorizontalLayout sublayout;
|
ui::HorizontalLayout sublayout(ui::AdjustHeight::No, ui::AdjustWidth::Yes);
|
||||||
layout.add_widget(sublayout);
|
layout.add_widget(sublayout);
|
||||||
|
|
||||||
ColorWidget red(ui::RED);
|
ColorWidget red(ui::RED);
|
||||||
|
@ -94,6 +94,7 @@ namespace ui
|
|||||||
|
|
||||||
Result<void> Window::draw()
|
Result<void> Window::draw()
|
||||||
{
|
{
|
||||||
|
m_canvas.fill(m_background);
|
||||||
if (m_main_widget) return m_main_widget->draw(m_canvas);
|
if (m_main_widget) return m_main_widget->draw(m_canvas);
|
||||||
update();
|
update();
|
||||||
return {};
|
return {};
|
||||||
|
Loading…
Reference in New Issue
Block a user