diff options
Diffstat (limited to 'src/namespacedef.cpp')
-rw-r--r-- | src/namespacedef.cpp | 52 |
1 files changed, 26 insertions, 26 deletions
diff --git a/src/namespacedef.cpp b/src/namespacedef.cpp index 58d0ff0..f3ec7ae 100644 --- a/src/namespacedef.cpp +++ b/src/namespacedef.cpp @@ -839,13 +839,20 @@ void NamespaceDefImpl::writeSummaryLinks(OutputList &ol) const ol.writeSummaryLink(QCString(),label,ls->title(lang),first); first=FALSE; } - else if (lde->kind()==LayoutDocEntry::NamespaceNestedNamespaces && namespaces.declVisible()) + else if (lde->kind()==LayoutDocEntry::NamespaceNestedNamespaces && namespaces.declVisible(false)) { const LayoutDocEntrySection *ls = (const LayoutDocEntrySection*)lde.get(); QCString label = "namespaces"; ol.writeSummaryLink(QCString(),label,ls->title(lang),first); first=FALSE; } + else if (lde->kind()==LayoutDocEntry::NamespaceNestedConstantGroups && namespaces.declVisible(true)) + { + const LayoutDocEntrySection *ls = (const LayoutDocEntrySection*)lde.get(); + QCString label = "constantgroups"; + ol.writeSummaryLink(QCString(),label,ls->title(lang),first); + first=FALSE; + } else if (lde->kind()==LayoutDocEntry::NamespaceConcepts && m_concepts.declVisible()) { const LayoutDocEntrySection *ls = (const LayoutDocEntrySection*)lde.get(); @@ -1270,28 +1277,9 @@ void NamespaceDefImpl::combineUsingRelations(NamespaceDefSet &visitedNamespaces) //------------------------------------------------------------------------------- -bool NamespaceLinkedRefMap::declVisible() const -{ - for (const auto &nd : *this) - { - if (nd->isLinkable()) - { - return TRUE; - } - } - return FALSE; -} - -void NamespaceLinkedRefMap::writeDeclaration(OutputList &ol,const QCString &title, - bool const isConstantGroup,bool localName) +bool NamespaceLinkedRefMap::declVisible(bool isConstantGroup) const { - - - if (empty()) return; // no namespaces in the list - - if (Config_getBool(OPTIMIZE_OUTPUT_VHDL)) return; - - bool found=FALSE; + bool found=false; for (const auto &nd : *this) { if (nd->isLinkable() && nd->hasDocumentation()) @@ -1301,7 +1289,7 @@ void NamespaceLinkedRefMap::writeDeclaration(OutputList &ol,const QCString &titl { if (isConstantGroup == nd->isConstantGroup()) { - found=TRUE; + found=true; break; } } @@ -1311,15 +1299,27 @@ void NamespaceLinkedRefMap::writeDeclaration(OutputList &ol,const QCString &titl { err("Internal inconsistency: constant group but not IDL?\n"); } - found=TRUE; + found=true; break; } } } - if (!found) return; // no linkable namespaces in the list + return found; +} + +void NamespaceLinkedRefMap::writeDeclaration(OutputList &ol,const QCString &title, + bool const isConstantGroup,bool localName) +{ + + + if (empty()) return; // no namespaces in the list + + if (Config_getBool(OPTIMIZE_OUTPUT_VHDL)) return; + + if (!declVisible(isConstantGroup)) return; // write list of namespaces - ol.startMemberHeader("namespaces"); + ol.startMemberHeader(isConstantGroup ? "constantgroups" : "namespaces"); //bool javaOpt = Config_getBool(OPTIMIZE_OUTPUT_JAVA); //bool fortranOpt = Config_getBool(OPTIMIZE_FOR_FORTRAN); ol.parseText(title); |