More cleaning
This commit is contained in:
parent
02ebb9a54b
commit
6adc441e6f
37 changed files with 213 additions and 181 deletions
|
@ -10,9 +10,9 @@ namespace mt
|
|||
{
|
||||
|
||||
Window::Window()
|
||||
:mWidth(400),
|
||||
mHeight(300),
|
||||
mWidget()
|
||||
:mWidth(800),
|
||||
mHeight(600),
|
||||
mWidget(Widget::Create())
|
||||
{
|
||||
|
||||
}
|
||||
|
@ -50,6 +50,10 @@ void Window::OnPaint(const PaintEvent* event)
|
|||
|
||||
void Window::AddWidget(WidgetUPtr widget)
|
||||
{
|
||||
if (mWidget)
|
||||
{
|
||||
mWidget.reset();
|
||||
}
|
||||
mWidget = std::move(widget);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue