diff options
author | sje <sje@4f64403b-2f21-0410-a795-97e2b3489a10> | 2007-10-04 17:14:42 +0000 |
---|---|---|
committer | sje <sje@4f64403b-2f21-0410-a795-97e2b3489a10> | 2007-10-04 17:14:42 +0000 |
commit | df1c8cf224cee0c442a9f6b438b2c767326e4059 (patch) | |
tree | 311a0059e3087510b199e90dcc3b62ecfdedd31b /meta2/common.cpp | |
parent | 573e3c67a9f113b2bd101c669b1b86615356fc13 (diff) |
implementation of red-black tree, backing Map template class :)
git-svn-id: https://server.scottellis.com.au/svn/mim_plugs@353 4f64403b-2f21-0410-a795-97e2b3489a10
Diffstat (limited to 'meta2/common.cpp')
-rw-r--r-- | meta2/common.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/meta2/common.cpp b/meta2/common.cpp index fe22092..17418fd 100644 --- a/meta2/common.cpp +++ b/meta2/common.cpp @@ -5,7 +5,11 @@ bool ContactHandle::operator==(const ContactHandle &other) const { }
bool ContactHandle::operator<(const ContactHandle &other) const {
+ // these don't work, 'cause the comparison is not constant
//return CallService(MS_CLIST_CONTACTSCOMPARE, (WPARAM)hContact, (LPARAM)other.handle()) < 0;
+ //return _tcscmp(ContactName(hContact), ContactName(other.handle()));
+
+ // will produce a *very* unbalanced binary tree (metaMap) when contacts are added in order of handle - which they most likely are
return hContact < other.handle();
}
|