qdoc: Removed some obsolete ifdefs

Also removed a few useless comments.

Change-Id: I62a52bb826c1299ea9da3f0f3c23f267703c6509
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
This commit is contained in:
Martin Smith 2012-05-10 13:11:13 +02:00 committed by Qt by Nokia
parent 9ffd616332
commit d2456798c6
5 changed files with 4 additions and 20 deletions

View File

@ -132,7 +132,7 @@ private:
};
#define CONFIG_ALIAS "alias"
#define CONFIG_BASE "base" // ### don't document for now
#define CONFIG_BASE "base"
#define CONFIG_BASEDIR "basedir"
#define CONFIG_CODEINDENT "codeindent"
#define CONFIG_DEFINES "defines"
@ -184,17 +184,13 @@ private:
#define CONFIG_TEMPLATEDIR "templatedir"
#define CONFIG_TABSIZE "tabsize"
#define CONFIG_TAGFILE "tagfile"
#define CONFIG_TRANSLATORS "translators" // ### don't document for now
#define CONFIG_TRANSLATORS "translators"
#define CONFIG_URL "url"
#define CONFIG_VERSION "version"
#define CONFIG_VERSIONSYM "versionsym"
#define CONFIG_FILEEXTENSIONS "fileextensions"
#define CONFIG_IMAGEEXTENSIONS "imageextensions"
#ifdef QDOC_QML
#define CONFIG_QMLONLY "qmlonly"
#endif
QT_END_NAMESPACE

View File

@ -556,9 +556,7 @@ private:
NodeMap obsoleteClasses;
NodeMap namespaceIndex;
NodeMap serviceClasses;
#ifdef QDOC_QML
NodeMap qmlClasses;
#endif
QMap<QString, NodeMap > funcIndex;
QMap<Text, const Node*> legaleseTexts;
static int id;
@ -573,7 +571,7 @@ private:
#define DITAXMLGENERATOR_ADDRESS "address"
#define DITAXMLGENERATOR_FOOTER "footer"
#define DITAXMLGENERATOR_GENERATEMACREFS "generatemacrefs" // ### document me
#define DITAXMLGENERATOR_GENERATEMACREFS "generatemacrefs"
#define DITAXMLGENERATOR_POSTHEADER "postheader"
#define DITAXMLGENERATOR_POSTPOSTHEADER "postpostheader"
#define DITAXMLGENERATOR_STYLE "style"

View File

@ -2027,13 +2027,8 @@ void DocParser::appendWord(const QString &word)
void DocParser::appendToCode(const QString& markedCode)
{
Atom::Type lastType = priv->text.lastAtom()->type();
#ifdef QDOC_QML
if (lastType != Atom::Qml && lastType != Atom::Code && lastType != Atom::JavaScript)
append(Atom::Qml);
#else
if (lastType != Atom::Code)
append(Atom::Code);
#endif
priv->text.lastAtom()->appendString(markedCode);
}

View File

@ -408,7 +408,6 @@ int HtmlGenerator::generateAtom(const Atom *atom,
marker,relative))
<< "</pre>\n";
break;
#ifdef QDOC_QML
case Atom::Qml:
out() << "<pre class=\"qml\">"
<< trimmedTrailing(highlightedCode(indent(codeIndent,atom->string()),
@ -421,7 +420,6 @@ int HtmlGenerator::generateAtom(const Atom *atom,
marker,relative))
<< "</pre>\n";
break;
#endif
case Atom::CodeNew:
out() << "<p>you can rewrite it as</p>\n"
<< "<pre class=\"cpp\">"
@ -1149,12 +1147,10 @@ int HtmlGenerator::generateAtom(const Atom *atom,
out() << "<b class=\"redFont\"><code>\\" << protectEnc(atom->string())
<< "</code></b>";
break;
#ifdef QDOC_QML
case Atom::QmlText:
case Atom::EndQmlText:
// don't do anything with these. They are just tags.
break;
#endif
default:
unknownAtom(atom);
}

View File

@ -52,7 +52,7 @@
QT_BEGIN_NAMESPACE
#define COMMAND_DEPRECATED Doc::alias(QLatin1String("deprecated")) // ### don't document
#define COMMAND_DEPRECATED Doc::alias(QLatin1String("deprecated"))
#define COMMAND_INGROUP Doc::alias(QLatin1String("ingroup"))
#define COMMAND_INTERNAL Doc::alias(QLatin1String("internal"))
#define COMMAND_OBSOLETE Doc::alias(QLatin1String("obsolete"))
@ -488,7 +488,6 @@ bool QmlDocVisitor::visit(QQmlJS::AST::UiPublicMember *member)
if (qmlClass) {
QString name = member->name.toString();
QmlPropertyNode *qmlPropNode = new QmlPropertyNode(qmlClass, name, type, false);
//qmlPropNode->setLocation(doc.location());
qmlPropNode->setReadOnly(member->isReadonlyMember);
if (member->isDefaultMember)
qmlPropNode->setDefault();