From f4ecb2c0dfb21b0566e15efdae5b4f4069a274c9 Mon Sep 17 00:00:00 2001 From: carols Date: Tue, 7 Apr 2020 06:14:45 +0800 Subject: fix with_private name --- tests/projects/qt/with_private/src/main.cpp | 11 +++++++++++ tests/projects/qt/with_private/src/mainwindow.cpp | 16 +++++++++++++++ tests/projects/qt/with_private/src/mainwindow.h | 22 +++++++++++++++++++++ tests/projects/qt/with_private/src/mainwindow.ui | 24 +++++++++++++++++++++++ tests/projects/qt/with_private/xmake.lua | 22 +++++++++++++++++++++ tests/projects/qt/with_privete/src/main.cpp | 11 ----------- tests/projects/qt/with_privete/src/mainwindow.cpp | 16 --------------- tests/projects/qt/with_privete/src/mainwindow.h | 22 --------------------- tests/projects/qt/with_privete/src/mainwindow.ui | 24 ----------------------- tests/projects/qt/with_privete/xmake.lua | 22 --------------------- 10 files changed, 95 insertions(+), 95 deletions(-) create mode 100644 tests/projects/qt/with_private/src/main.cpp create mode 100644 tests/projects/qt/with_private/src/mainwindow.cpp create mode 100644 tests/projects/qt/with_private/src/mainwindow.h create mode 100644 tests/projects/qt/with_private/src/mainwindow.ui create mode 100644 tests/projects/qt/with_private/xmake.lua delete mode 100644 tests/projects/qt/with_privete/src/main.cpp delete mode 100644 tests/projects/qt/with_privete/src/mainwindow.cpp delete mode 100644 tests/projects/qt/with_privete/src/mainwindow.h delete mode 100644 tests/projects/qt/with_privete/src/mainwindow.ui delete mode 100644 tests/projects/qt/with_privete/xmake.lua diff --git a/tests/projects/qt/with_private/src/main.cpp b/tests/projects/qt/with_private/src/main.cpp new file mode 100644 index 000000000..b48f94ec8 --- /dev/null +++ b/tests/projects/qt/with_private/src/main.cpp @@ -0,0 +1,11 @@ +#include "mainwindow.h" +#include + +int main(int argc, char *argv[]) +{ + QApplication a(argc, argv); + MainWindow w; + w.show(); + + return a.exec(); +} diff --git a/tests/projects/qt/with_private/src/mainwindow.cpp b/tests/projects/qt/with_private/src/mainwindow.cpp new file mode 100644 index 000000000..4d9a6bcae --- /dev/null +++ b/tests/projects/qt/with_private/src/mainwindow.cpp @@ -0,0 +1,16 @@ +#include "mainwindow.h" +#include "ui_mainwindow.h" +#include +MainWindow::MainWindow(QWidget *parent) : + QMainWindow(parent), + ui(new Ui::MainWindow) +{ + ui->setupUi(this); + QQuickText *text = new QQuickText(); + delete text; +} + +MainWindow::~MainWindow() +{ + delete ui; +} diff --git a/tests/projects/qt/with_private/src/mainwindow.h b/tests/projects/qt/with_private/src/mainwindow.h new file mode 100644 index 000000000..8e06f4918 --- /dev/null +++ b/tests/projects/qt/with_private/src/mainwindow.h @@ -0,0 +1,22 @@ +#ifndef MAINWINDOW_H +#define MAINWINDOW_H + +#include + +namespace Ui { +class MainWindow; +} + +class MainWindow : public QMainWindow +{ + Q_OBJECT + +public: + explicit MainWindow(QWidget *parent = 0); + ~MainWindow(); + +private: + Ui::MainWindow *ui; +}; + +#endif // MAINWINDOW_H diff --git a/tests/projects/qt/with_private/src/mainwindow.ui b/tests/projects/qt/with_private/src/mainwindow.ui new file mode 100644 index 000000000..1c59b695e --- /dev/null +++ b/tests/projects/qt/with_private/src/mainwindow.ui @@ -0,0 +1,24 @@ + + MainWindow + + + + 0 + 0 + 400 + 300 + + + + MainWindow + + + + + + + + + + + diff --git a/tests/projects/qt/with_private/xmake.lua b/tests/projects/qt/with_private/xmake.lua new file mode 100644 index 000000000..6cc6378e7 --- /dev/null +++ b/tests/projects/qt/with_private/xmake.lua @@ -0,0 +1,22 @@ + +-- add modes: debug and release +add_rules("mode.debug", "mode.release") + +-- add target +target("qt_demo") + + -- add rules + add_rules("qt.widgetapp") + add_frameworks("QtCore", "QtGui", "QtWidgets", "QtQuick", "QtQuickPrivate", "QtQml", "QtQmlPrivate", "QtCorePrivate", "QtGuiPrivate") + + -- add headers + add_headerfiles("src/*.h") + + -- add files + add_files("src/*.cpp") + add_files("src/mainwindow.ui") + + -- add files with Q_OBJECT meta (only for qt.moc) + add_files("src/mainwindow.h") + + diff --git a/tests/projects/qt/with_privete/src/main.cpp b/tests/projects/qt/with_privete/src/main.cpp deleted file mode 100644 index b48f94ec8..000000000 --- a/tests/projects/qt/with_privete/src/main.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include "mainwindow.h" -#include - -int main(int argc, char *argv[]) -{ - QApplication a(argc, argv); - MainWindow w; - w.show(); - - return a.exec(); -} diff --git a/tests/projects/qt/with_privete/src/mainwindow.cpp b/tests/projects/qt/with_privete/src/mainwindow.cpp deleted file mode 100644 index 4d9a6bcae..000000000 --- a/tests/projects/qt/with_privete/src/mainwindow.cpp +++ /dev/null @@ -1,16 +0,0 @@ -#include "mainwindow.h" -#include "ui_mainwindow.h" -#include -MainWindow::MainWindow(QWidget *parent) : - QMainWindow(parent), - ui(new Ui::MainWindow) -{ - ui->setupUi(this); - QQuickText *text = new QQuickText(); - delete text; -} - -MainWindow::~MainWindow() -{ - delete ui; -} diff --git a/tests/projects/qt/with_privete/src/mainwindow.h b/tests/projects/qt/with_privete/src/mainwindow.h deleted file mode 100644 index 8e06f4918..000000000 --- a/tests/projects/qt/with_privete/src/mainwindow.h +++ /dev/null @@ -1,22 +0,0 @@ -#ifndef MAINWINDOW_H -#define MAINWINDOW_H - -#include - -namespace Ui { -class MainWindow; -} - -class MainWindow : public QMainWindow -{ - Q_OBJECT - -public: - explicit MainWindow(QWidget *parent = 0); - ~MainWindow(); - -private: - Ui::MainWindow *ui; -}; - -#endif // MAINWINDOW_H diff --git a/tests/projects/qt/with_privete/src/mainwindow.ui b/tests/projects/qt/with_privete/src/mainwindow.ui deleted file mode 100644 index 1c59b695e..000000000 --- a/tests/projects/qt/with_privete/src/mainwindow.ui +++ /dev/null @@ -1,24 +0,0 @@ - - MainWindow - - - - 0 - 0 - 400 - 300 - - - - MainWindow - - - - - - - - - - - diff --git a/tests/projects/qt/with_privete/xmake.lua b/tests/projects/qt/with_privete/xmake.lua deleted file mode 100644 index 6cc6378e7..000000000 --- a/tests/projects/qt/with_privete/xmake.lua +++ /dev/null @@ -1,22 +0,0 @@ - --- add modes: debug and release -add_rules("mode.debug", "mode.release") - --- add target -target("qt_demo") - - -- add rules - add_rules("qt.widgetapp") - add_frameworks("QtCore", "QtGui", "QtWidgets", "QtQuick", "QtQuickPrivate", "QtQml", "QtQmlPrivate", "QtCorePrivate", "QtGuiPrivate") - - -- add headers - add_headerfiles("src/*.h") - - -- add files - add_files("src/*.cpp") - add_files("src/mainwindow.ui") - - -- add files with Q_OBJECT meta (only for qt.moc) - add_files("src/mainwindow.h") - - -- cgit v1.3.1