mirror of
https://github.com/Armored-Dragon/overte.git
synced 2025-03-11 16:13:16 +01:00
working on windows cmake version
This commit is contained in:
parent
06d3bb2a34
commit
0a2b546017
2 changed files with 25 additions and 6 deletions
|
@ -20,7 +20,7 @@ endforeach()
|
|||
set(src_files
|
||||
src/main.cpp)
|
||||
|
||||
add_executable(${PROJECT_NAME} ${src_file})
|
||||
add_executable(${PROJECT_NAME} ${src_files})
|
||||
|
||||
target_link_libraries(${PROJECT_NAME} PUBLIC
|
||||
Qt5::Core
|
||||
|
|
|
@ -1,7 +1,26 @@
|
|||
//main.cpp
|
||||
//#include <iostream>
|
||||
#include <iostream>
|
||||
#include <QGuiApplication>
|
||||
#include <QQuickView>
|
||||
#include <QString>
|
||||
#include <QtPlugin>
|
||||
/*Q_IMPORT_PLUGIN(QCocoaIntegrationPlugin);
|
||||
Q_IMPORT_PLUGIN(QtQuick2Plugin);
|
||||
Q_IMPORT_PLUGIN(QtQuickControls2Plugin);
|
||||
Q_IMPORT_PLUGIN(QtQuickTemplates2Plugin);*/
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
QString name { "QtExamples" };
|
||||
QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
|
||||
QCoreApplication::setOrganizationName(name);
|
||||
|
||||
int main(int argc, char *argv[]) {
|
||||
//std::cout << "Hello World \n";
|
||||
return 0;
|
||||
QGuiApplication app(argc, argv);
|
||||
|
||||
QQuickView view;
|
||||
view.setFlags(Qt::FramelessWindowHint);
|
||||
view.setSource(QUrl("/Users/danteruiz/github/test/qml/root.qml"));
|
||||
if (view.status() == QQuickView::Error)
|
||||
return -1;
|
||||
view.setResizeMode(QQuickView::SizeRootObjectToView);
|
||||
view.show();
|
||||
return app.exec();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue