project: added project skeleton
Skeleton includes emtpy implementations of application class structure. Source groups were added to CMakeLists to define filters in Visual Studio.
This commit is contained in:
@@ -1,4 +1,8 @@
|
||||
add_files(
|
||||
APP_FILES
|
||||
|
||||
qt/QtElementFactory.cpp
|
||||
qt/QtElementFactory.h
|
||||
|
||||
main.cpp
|
||||
)
|
||||
|
||||
+11
-6
@@ -1,16 +1,21 @@
|
||||
#include <memory>
|
||||
|
||||
#include <QApplication>
|
||||
#include <QTextEdit>
|
||||
|
||||
#include "utility.h"
|
||||
#include "Application.h"
|
||||
#include "qt/QtElementFactory.h"
|
||||
|
||||
int main(int argv, char **args)
|
||||
{
|
||||
hello();
|
||||
QApplication qtApp(argv, args);
|
||||
std::shared_ptr<GuiElementFactory> elementFactory = std::make_shared<QtElementFactory>();
|
||||
|
||||
QApplication app(argv, args);
|
||||
std::shared_ptr<Application> app = Application::create(elementFactory);
|
||||
app->loadProject();
|
||||
|
||||
QTextEdit textEdit;
|
||||
textEdit.show();
|
||||
QTextEdit textEdit;
|
||||
textEdit.show();
|
||||
|
||||
return app.exec();
|
||||
return qtApp.exec();
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
#include "qt/QtElementFactory.h"
|
||||
|
||||
QtElementFactory::QtElementFactory()
|
||||
{
|
||||
}
|
||||
|
||||
QtElementFactory::~QtElementFactory()
|
||||
{
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
#ifndef QT_ELEMENT_FACTORY_H
|
||||
#define QT_ELEMENT_FACTORY_H
|
||||
|
||||
#include "gui/GuiElementFactory.h"
|
||||
|
||||
class QtElementFactory: public GuiElementFactory
|
||||
{
|
||||
public:
|
||||
QtElementFactory();
|
||||
~QtElementFactory();
|
||||
};
|
||||
|
||||
# endif // QT_ELEMENT_FACTORY_H
|
||||
Reference in New Issue
Block a user