diff options
author | Dimitri van Heesch <dimitri@stack.nl> | 2013-12-30 17:55:14 (GMT) |
---|---|---|
committer | Dimitri van Heesch <dimitri@stack.nl> | 2013-12-30 17:55:14 (GMT) |
commit | 6e51abf63021dc9fe32c05f003232fe68a08591d (patch) | |
tree | e9fe6f526e4a2b22b1a55659331c15750969a019 /src/membername.cpp | |
parent | 744d1ca52e25dfa9e3d656056d87ed7cb6320585 (diff) | |
download | Doxygen-6e51abf63021dc9fe32c05f003232fe68a08591d.zip Doxygen-6e51abf63021dc9fe32c05f003232fe68a08591d.tar.gz Doxygen-6e51abf63021dc9fe32c05f003232fe68a08591d.tar.bz2 |
Reduced and improved functionality of QList
- operations on current index and node (next(), prev(), last(), first()) have been removed.
- access to internal nodes has been removed.
- old QList has been renamed to QInternalList for use inside qtools only.
- added type safe compare, new, and delete operations (compareValues(), newValue(), deleteValue()).
- add compareValues also to QDict for consistency.
- changed doxygen's implementation to comply with the new QList and QDict interface.
Diffstat (limited to 'src/membername.cpp')
-rw-r--r-- | src/membername.cpp | 16 |
1 files changed, 5 insertions, 11 deletions
diff --git a/src/membername.cpp b/src/membername.cpp index 58eaf8c..946ce43 100644 --- a/src/membername.cpp +++ b/src/membername.cpp @@ -30,10 +30,8 @@ MemberName::~MemberName() { } -int MemberName::compareItems(QCollection::Item item1, QCollection::Item item2) +int MemberName::compareValues(const MemberDef *m1, const MemberDef *m2) const { - MemberDef *m1=(MemberDef *)item1; - MemberDef *m2=(MemberDef *)item2; ClassDef *c1=m1->getClassDef(); ClassDef *c2=m2->getClassDef(); FileDef *f1=m1->getFileDef(); @@ -52,10 +50,8 @@ MemberNameInfo::MemberNameInfo(const char *n) : QList<MemberInfo>() setAutoDelete(TRUE); } -int MemberNameInfo::compareItems(QCollection::Item item1, QCollection::Item item2) +int MemberNameInfo::compareValues(const MemberInfo *m1,const MemberInfo *m2) const { - MemberInfo *m1=(MemberInfo *)item1; - MemberInfo *m2=(MemberInfo *)item2; ClassDef *c1=m1->memberDef->getClassDef(); ClassDef *c2=m2->memberDef->getClassDef(); FileDef *f1=m1->memberDef->getFileDef(); @@ -72,12 +68,10 @@ MemberNameIterator::MemberNameIterator(const MemberName &mnlist) : { } -int MemberNameSDict::compareItems(QCollection::Item item1, QCollection::Item item2) +int MemberNameSDict::compareValues(const MemberName *n1,const MemberName *n2) const { - MemberName *n1=(MemberName *)item1; - MemberName *n2=(MemberName *)item2; return qstricmp(n1->memberName()+getPrefixIndex(n1->memberName()), - n2->memberName()+getPrefixIndex(n2->memberName()) - ); + n2->memberName()+getPrefixIndex(n2->memberName()) + ); } |