summaryrefslogtreecommitdiffstats
path: root/generator.cpp
diff options
context:
space:
mode:
authorHugo Lima <hugo.lima@openbossa.org>2009-09-03 18:48:57 -0300
committerHugo Lima <hugo.lima@openbossa.org>2009-09-03 19:04:03 -0300
commit518028765c892b7a6a840cca92376ccc8b77b04c (patch)
treee2ad45d551fdecad26f4c3f3e50ec18b58ecb46c /generator.cpp
parentb811be1ce4aa832ed7aa8542da535000924effa3 (diff)
downloadgeneratorrunner-518028765c892b7a6a840cca92376ccc8b77b04c.tar.gz
generatorrunner-518028765c892b7a6a840cca92376ccc8b77b04c.tar.xz
generatorrunner-518028765c892b7a6a840cca92376ccc8b77b04c.zip
Fixed assert failure when using qtdocgenerator.
Added a default implementation for Generator::subDirectoryForClass. This breaks the binary compatibility but NOT the source compatibility.
Diffstat (limited to 'generator.cpp')
-rw-r--r--generator.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/generator.cpp b/generator.cpp
index dfcbcb8..274ccc7 100644
--- a/generator.cpp
+++ b/generator.cpp
@@ -420,3 +420,17 @@ QString Generator::translateType(const AbstractMetaType *cType,
return s;
}
+
+
+QString Generator::subDirectoryForClass(const AbstractMetaClass* clazz) const
+{
+ return subDirectoryForPackage(clazz->package());
+}
+
+QString Generator::subDirectoryForPackage(QString packageName) const
+{
+ if (packageName.isEmpty())
+ packageName = m_packageName;
+ return QString(packageName).replace(".", QDir::separator());
+}
+