src: replaced gui wording with view wording
Changed gui wording in lib and app to view wording, since MVC views do not necessarily deal with GUIs. And moved files so structure is similar in lib and app.
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
#include "component/view/ViewLayout.h"
|
||||
#include "utility/math/Vector2.h"
|
||||
|
||||
class GuiWidgetWrapper;
|
||||
class ViewWidgetWrapper;
|
||||
|
||||
class View
|
||||
{
|
||||
@@ -20,15 +20,14 @@ public:
|
||||
virtual ~View();
|
||||
|
||||
virtual std::string getName() const = 0;
|
||||
|
||||
virtual void createWidgetWrapper() = 0;
|
||||
void setWidgetWrapper(std::shared_ptr<GuiWidgetWrapper> widgetWrapper);
|
||||
GuiWidgetWrapper* getWidgetWrapper();
|
||||
|
||||
virtual void initGui() = 0;
|
||||
virtual void initView() = 0;
|
||||
|
||||
void setComponent(Component* component);
|
||||
|
||||
void setWidgetWrapper(std::shared_ptr<ViewWidgetWrapper> widgetWrapper);
|
||||
ViewWidgetWrapper* getWidgetWrapper();
|
||||
|
||||
int getMinWidth() const;
|
||||
int getMinHeight() const;
|
||||
Vec2i getMinSize() const;
|
||||
@@ -42,7 +41,7 @@ protected:
|
||||
private:
|
||||
Component* m_component;
|
||||
ViewLayout* const m_viewLayout;
|
||||
std::shared_ptr<GuiWidgetWrapper> m_widgetWrapper;
|
||||
std::shared_ptr<ViewWidgetWrapper> m_widgetWrapper;
|
||||
Vec2i m_minSize;
|
||||
};
|
||||
|
||||
@@ -52,7 +51,7 @@ std::shared_ptr<T> View::create(ViewLayout* viewLayout)
|
||||
std::shared_ptr<T> ptr = std::make_shared<T>(viewLayout);
|
||||
|
||||
ptr->createWidgetWrapper();
|
||||
ptr->initGui();
|
||||
ptr->initView();
|
||||
|
||||
viewLayout->addView(ptr.get());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user