mirror of
https://github.com/edubart/otclient.git
synced 2025-10-21 23:05:54 +02:00
render do main menu
This commit is contained in:
@@ -24,7 +24,7 @@
|
||||
|
||||
#include "uicontainer.h"
|
||||
|
||||
UIContainer g_gui;
|
||||
UIContainerPtr g_gui(new UIContainer);
|
||||
|
||||
void UIContainer::addChild(UIElementPtr child)
|
||||
{
|
||||
@@ -60,7 +60,7 @@ void UIContainer::setRect(const Rect& rect)
|
||||
{
|
||||
// update children rect
|
||||
for(auto it = m_children.begin(); it != m_children.end(); ++it) {
|
||||
UIElementPtr child = (*it)->asUIElement();
|
||||
const UIElementPtr& child = (*it);
|
||||
|
||||
// transforme child rect
|
||||
Rect childRect = child->getRect();
|
||||
@@ -94,6 +94,24 @@ void UIContainer::moveTo(const Point& pos)
|
||||
|
||||
}
|
||||
|
||||
void UIContainer::render()
|
||||
{
|
||||
for(auto it = m_children.begin(); it != m_children.end(); ++it) {
|
||||
const UIElementPtr& child = (*it);
|
||||
child->render();
|
||||
}
|
||||
}
|
||||
|
||||
void UIContainer::update(int ticks, int elapsedTicks)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
bool UIContainer::onInputEvent(InputEvent* event)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
void UIContainer::setActiveElement(UIElementPtr activeElement)
|
||||
{
|
||||
|
||||
|
Reference in New Issue
Block a user