diff options
author | dimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7> | 2009-08-14 14:49:07 (GMT) |
---|---|---|
committer | dimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7> | 2009-08-14 14:49:07 (GMT) |
commit | 9e6be9a8ae24b788cf2463a703bda48cbd77c773 (patch) | |
tree | fed426d0d7216311cbd009a1fcd2786176478b5e /src/memberlist.cpp | |
parent | 6e28050ef5483e624122b0bacb998c40664f78ee (diff) | |
download | Doxygen-9e6be9a8ae24b788cf2463a703bda48cbd77c773.zip Doxygen-9e6be9a8ae24b788cf2463a703bda48cbd77c773.tar.gz Doxygen-9e6be9a8ae24b788cf2463a703bda48cbd77c773.tar.bz2 |
Release-1.5.9-20090814
Diffstat (limited to 'src/memberlist.cpp')
-rw-r--r-- | src/memberlist.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/memberlist.cpp b/src/memberlist.cpp index 8091362..a5d9fd8 100644 --- a/src/memberlist.cpp +++ b/src/memberlist.cpp @@ -48,8 +48,17 @@ MemberList::~MemberList() int MemberList::compareItems(GCI item1, GCI item2) { + static bool sortConstructorsFirst = Config_getBool("SORT_MEMBERS_CTORS_1ST"); MemberDef *c1=(MemberDef *)item1; MemberDef *c2=(MemberDef *)item2; + if (sortConstructorsFirst) { + int ord1 = c1->isConstructor() ? 2 : (c1->isDestructor() ? 1 : 0); + int ord2 = c2->isConstructor() ? 2 : (c2->isDestructor() ? 1 : 0); + if (ord1 > ord2) + return -1; + else if (ord2 > ord1) + return 1; + } return stricmp(c1->name(),c2->name()); } |