@@ -286,6 +286,10 @@ if (NOT QT_TEST_VERSION STREQUAL 4)
endif()
+# -- Test
+# Tests various .ui include directories
+add_subdirectory(uicInclude)
+
# -- Test
# Complex test case
add_subdirectory(complex)
@@ -0,0 +1,8 @@
+# Test moc include patterns
+set(CMAKE_AUTOUIC_SEARCH_PATHS "dirA")
+add_executable(uicInclude main.cpp)
+target_link_libraries(uicInclude ${QT_LIBRARIES})
+set_target_properties(uicInclude PROPERTIES AUTOUIC ON)
+set_property(TARGET uicInclude APPEND PROPERTY AUTOUIC_SEARCH_PATHS "dirB")
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>PageC</class>
+ <widget class="QWidget" name="PageC">
+ <property name="geometry">
+ <rect>
+ <x>0</x>
+ <y>0</y>
+ <width>400</width>
+ <height>300</height>
+ </rect>
+ </property>
+ <property name="windowTitle">
+ <string>Form</string>
+ <layout class="QHBoxLayout" name="horizontalLayout">
+ <item>
+ <widget class="QTreeView" name="treeView"/>
+ </item>
+ </layout>
+ </widget>
+ <resources/>
+ <connections/>
+</ui>
+ <class>PageA</class>
+ <widget class="QWidget" name="PageA">
+ <class>PageB</class>
+ <widget class="QWidget" name="PageB">
@@ -0,0 +1,10 @@
+#include "main.hpp"
+int main(int argv, char** args)
+{
+ return 0;
+}
+#include "sub/ui_PageB.h"
+#include "ui_PageC.h"
@@ -0,0 +1,6 @@
+#ifndef MAIN_HPP
+#define MAIN_HPP
+#include "ui_PageA.h"
+#endif