summaryrefslogtreecommitdiffstats
path: root/src/namespacedef.cpp
diff options
context:
space:
mode:
authorDimitri van Heesch <dimitri@stack.nl>2005-02-10 18:38:13 (GMT)
committerDimitri van Heesch <dimitri@stack.nl>2005-02-10 18:38:13 (GMT)
commit2ed43d4c3890c98475d4deb87d4a14ab949f90c4 (patch)
tree654e62c3ea86e579f0642040b094a844d4e5223c /src/namespacedef.cpp
parentc00ba20bdfa987c9554d4068fc9ccf1a45fe28f8 (diff)
downloadDoxygen-2ed43d4c3890c98475d4deb87d4a14ab949f90c4.zip
Doxygen-2ed43d4c3890c98475d4deb87d4a14ab949f90c4.tar.gz
Doxygen-2ed43d4c3890c98475d4deb87d4a14ab949f90c4.tar.bz2
Release-1.4.1-20050210
Diffstat (limited to 'src/namespacedef.cpp')
-rw-r--r--src/namespacedef.cpp77
1 files changed, 44 insertions, 33 deletions
diff --git a/src/namespacedef.cpp b/src/namespacedef.cpp
index fab4850..8ced35a 100644
--- a/src/namespacedef.cpp
+++ b/src/namespacedef.cpp
@@ -516,7 +516,17 @@ void NamespaceDef::combineUsingRelations()
void NamespaceSDict::writeDeclaration(OutputList &ol,bool localName)
{
- if (count()==0) return;
+ if (count()==0) return; // no namespaces in the list
+
+ SDict<NamespaceDef>::Iterator ni(*this);
+ NamespaceDef *nd;
+ bool found=FALSE;
+ for (ni.toFirst();(nd=ni.current()) && !found;++ni)
+ {
+ if (nd->isLinkable()) found=TRUE;
+ }
+ if (!found) return; // no linkable namespaces in the list
+
// write list of namespaces
ol.startMemberHeader();
bool javaOpt = Config_getBool("OPTIMIZE_OUTPUT_JAVA");
@@ -530,41 +540,42 @@ void NamespaceSDict::writeDeclaration(OutputList &ol,bool localName)
}
ol.endMemberHeader();
ol.startMemberList();
- SDict<NamespaceDef>::Iterator ni(*this);
- NamespaceDef *nd;
for (ni.toFirst();(nd=ni.current());++ni)
{
- ol.startMemberItem(0);
- if (javaOpt)
- {
- ol.docify("package ");
- }
- else
- {
- ol.docify("namespace ");
- }
- ol.insertMemberAlign();
- QCString name;
- if (localName)
- {
- name = nd->localName();
- }
- else
- {
- name = nd->displayName();
- }
- ol.writeObjectLink(nd->getReference(),nd->getOutputFileBase(),0,name);
- if (!Config_getString("GENERATE_TAGFILE").isEmpty())
+ if (nd->isLinkable())
{
- Doxygen::tagFile << " <namespace>" << convertToXML(nd->name()) << "</namespace>" << endl;
- }
- ol.endMemberItem();
- if (!nd->briefDescription().isEmpty() && Config_getBool("BRIEF_MEMBER_DESC"))
- {
- ol.startMemberDescription();
- ol.parseDoc(nd->briefFile(),nd->briefLine(),nd,0,nd->briefDescription(),FALSE,FALSE);
- ol.endMemberDescription();
- ol.newParagraph();
+ ol.startMemberItem(0);
+ if (javaOpt)
+ {
+ ol.docify("package ");
+ }
+ else
+ {
+ ol.docify("namespace ");
+ }
+ ol.insertMemberAlign();
+ QCString name;
+ if (localName)
+ {
+ name = nd->localName();
+ }
+ else
+ {
+ name = nd->displayName();
+ }
+ ol.writeObjectLink(nd->getReference(),nd->getOutputFileBase(),0,name);
+ if (!Config_getString("GENERATE_TAGFILE").isEmpty())
+ {
+ Doxygen::tagFile << " <namespace>" << convertToXML(nd->name()) << "</namespace>" << endl;
+ }
+ ol.endMemberItem();
+ if (!nd->briefDescription().isEmpty() && Config_getBool("BRIEF_MEMBER_DESC"))
+ {
+ ol.startMemberDescription();
+ ol.parseDoc(nd->briefFile(),nd->briefLine(),nd,0,nd->briefDescription(),FALSE,FALSE);
+ ol.endMemberDescription();
+ ol.newParagraph();
+ }
}
}
ol.endMemberList();