From 932656527bdbf580335a082f8ecbaa888a710901 Mon Sep 17 00:00:00 2001 From: Sebastian Holtermann Date: Sun, 3 Sep 2017 21:31:11 +0200 Subject: Autogen: Tests: Add /ui_view.h AUTOUIC includes to sameName test --- Tests/QtAutogen/sameName/CMakeLists.txt | 5 ++++- Tests/QtAutogen/sameName/aaa/item.cpp | 2 ++ Tests/QtAutogen/sameName/aaa/item.hpp | 2 ++ Tests/QtAutogen/sameName/aaa/view.ui | 24 ++++++++++++++++++++++++ Tests/QtAutogen/sameName/bbb/item.cpp | 3 +++ Tests/QtAutogen/sameName/bbb/item.hpp | 1 + Tests/QtAutogen/sameName/bbb/view.ui | 24 ++++++++++++++++++++++++ Tests/QtAutogen/sameName/ccc/item.cpp | 3 +++ Tests/QtAutogen/sameName/ccc/item.hpp | 2 ++ Tests/QtAutogen/sameName/ccc/view.ui | 24 ++++++++++++++++++++++++ Tests/QtAutogen/sameName/item.cpp | 3 +++ Tests/QtAutogen/sameName/item.hpp | 2 ++ Tests/QtAutogen/sameName/view.ui | 24 ++++++++++++++++++++++++ 13 files changed, 118 insertions(+), 1 deletion(-) create mode 100644 Tests/QtAutogen/sameName/aaa/view.ui create mode 100644 Tests/QtAutogen/sameName/bbb/view.ui create mode 100644 Tests/QtAutogen/sameName/ccc/view.ui create mode 100644 Tests/QtAutogen/sameName/view.ui diff --git a/Tests/QtAutogen/sameName/CMakeLists.txt b/Tests/QtAutogen/sameName/CMakeLists.txt index 4d2dcd9..f695875 100644 --- a/Tests/QtAutogen/sameName/CMakeLists.txt +++ b/Tests/QtAutogen/sameName/CMakeLists.txt @@ -17,7 +17,10 @@ add_executable(sameName main.cpp ) target_link_libraries(sameName ${QT_LIBRARIES}) -set_target_properties(sameName PROPERTIES AUTOMOC TRUE AUTORCC TRUE) +set_target_properties(sameName PROPERTIES + AUTOMOC TRUE + AUTOUIC TRUE + AUTORCC TRUE) # Set different compression levels if (QT_TEST_VERSION STREQUAL 4) diff --git a/Tests/QtAutogen/sameName/aaa/item.cpp b/Tests/QtAutogen/sameName/aaa/item.cpp index 85312e9..e35d3d1 100644 --- a/Tests/QtAutogen/sameName/aaa/item.cpp +++ b/Tests/QtAutogen/sameName/aaa/item.cpp @@ -1,4 +1,5 @@ #include "item.hpp" +// Include ui_view.h only in header namespace aaa { @@ -13,6 +14,7 @@ public: void Item::go() { + Ui_ViewAAA ui; MocLocal obj; } } diff --git a/Tests/QtAutogen/sameName/aaa/item.hpp b/Tests/QtAutogen/sameName/aaa/item.hpp index b63466f..875f72f 100644 --- a/Tests/QtAutogen/sameName/aaa/item.hpp +++ b/Tests/QtAutogen/sameName/aaa/item.hpp @@ -2,6 +2,8 @@ #define AAA_ITEM_HPP #include +// Include ui_view.h only in header +#include namespace aaa { diff --git a/Tests/QtAutogen/sameName/aaa/view.ui b/Tests/QtAutogen/sameName/aaa/view.ui new file mode 100644 index 0000000..0f09980 --- /dev/null +++ b/Tests/QtAutogen/sameName/aaa/view.ui @@ -0,0 +1,24 @@ + + + ViewAAA + + + + 0 + 0 + 400 + 300 + + + + Form + + + + + + + + + + diff --git a/Tests/QtAutogen/sameName/bbb/item.cpp b/Tests/QtAutogen/sameName/bbb/item.cpp index b851bb6..9ef128e 100644 --- a/Tests/QtAutogen/sameName/bbb/item.cpp +++ b/Tests/QtAutogen/sameName/bbb/item.cpp @@ -1,4 +1,6 @@ #include "item.hpp" +// Include ui_view.h only in source +#include namespace bbb { @@ -13,6 +15,7 @@ public: void Item::go() { + Ui_ViewBBB ui; MocLocal obj; } } diff --git a/Tests/QtAutogen/sameName/bbb/item.hpp b/Tests/QtAutogen/sameName/bbb/item.hpp index 5b7f985..d39a9d7 100644 --- a/Tests/QtAutogen/sameName/bbb/item.hpp +++ b/Tests/QtAutogen/sameName/bbb/item.hpp @@ -2,6 +2,7 @@ #define BBB_ITEM_HPP #include +// Include ui_view.h only in source namespace bbb { diff --git a/Tests/QtAutogen/sameName/bbb/view.ui b/Tests/QtAutogen/sameName/bbb/view.ui new file mode 100644 index 0000000..a8f506e --- /dev/null +++ b/Tests/QtAutogen/sameName/bbb/view.ui @@ -0,0 +1,24 @@ + + + ViewBBB + + + + 0 + 0 + 400 + 300 + + + + Form + + + + + + + + + + diff --git a/Tests/QtAutogen/sameName/ccc/item.cpp b/Tests/QtAutogen/sameName/ccc/item.cpp index e27a784..ab8a281 100644 --- a/Tests/QtAutogen/sameName/ccc/item.cpp +++ b/Tests/QtAutogen/sameName/ccc/item.cpp @@ -1,4 +1,6 @@ #include "item.hpp" +// Include ui_view.h in source and header +#include namespace ccc { @@ -13,6 +15,7 @@ public: void Item::go() { + Ui_ViewCCC ui; MocLocal obj; } } diff --git a/Tests/QtAutogen/sameName/ccc/item.hpp b/Tests/QtAutogen/sameName/ccc/item.hpp index 96fcc24..20d9dd9 100644 --- a/Tests/QtAutogen/sameName/ccc/item.hpp +++ b/Tests/QtAutogen/sameName/ccc/item.hpp @@ -2,6 +2,8 @@ #define CCC_ITEM_HPP #include +// Include ui_view.h in source and header +#include namespace ccc { diff --git a/Tests/QtAutogen/sameName/ccc/view.ui b/Tests/QtAutogen/sameName/ccc/view.ui new file mode 100644 index 0000000..7989c69 --- /dev/null +++ b/Tests/QtAutogen/sameName/ccc/view.ui @@ -0,0 +1,24 @@ + + + ViewCCC + + + + 0 + 0 + 400 + 300 + + + + Form + + + + + + + + + + diff --git a/Tests/QtAutogen/sameName/item.cpp b/Tests/QtAutogen/sameName/item.cpp index c614a84..3d1fbe7 100644 --- a/Tests/QtAutogen/sameName/item.cpp +++ b/Tests/QtAutogen/sameName/item.cpp @@ -1,4 +1,6 @@ #include "item.hpp" +// Include ui_view.h in source and header +#include class MocLocal : public QObject { @@ -11,6 +13,7 @@ public: void Item::go() { + Ui_View ui; MocLocal obj; } diff --git a/Tests/QtAutogen/sameName/item.hpp b/Tests/QtAutogen/sameName/item.hpp index 91bba3b..75e83f4 100644 --- a/Tests/QtAutogen/sameName/item.hpp +++ b/Tests/QtAutogen/sameName/item.hpp @@ -2,6 +2,8 @@ #define ITEM_HPP #include +// Include ui_view.h in source and header +#include class Item : public QObject { diff --git a/Tests/QtAutogen/sameName/view.ui b/Tests/QtAutogen/sameName/view.ui new file mode 100644 index 0000000..2ffe734 --- /dev/null +++ b/Tests/QtAutogen/sameName/view.ui @@ -0,0 +1,24 @@ + + + View + + + + 0 + 0 + 400 + 300 + + + + Form + + + + + + + + + + -- cgit v0.12