summaryrefslogtreecommitdiff
path: root/protocols/Skype/src/skype_subclassing.cpp
diff options
context:
space:
mode:
authorAlexander Lantsev <aunsane@gmail.com>2012-10-02 18:39:38 +0000
committerAlexander Lantsev <aunsane@gmail.com>2012-10-02 18:39:38 +0000
commita6175cc98ca2b8ca61faa927e934f49375cee685 (patch)
tree26006550a4bfa7c36846e3b32d3cab9425a4d686 /protocols/Skype/src/skype_subclassing.cpp
parentfa6e252a049cd32cbc9d2bf546b630f2178f6692 (diff)
- added simple contacts loading
- added contact status updating git-svn-id: http://svn.miranda-ng.org/main/trunk@1766 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Skype/src/skype_subclassing.cpp')
-rw-r--r--protocols/Skype/src/skype_subclassing.cpp23
1 files changed, 9 insertions, 14 deletions
diff --git a/protocols/Skype/src/skype_subclassing.cpp b/protocols/Skype/src/skype_subclassing.cpp
index c206f65ef5..bb943a708e 100644
--- a/protocols/Skype/src/skype_subclassing.cpp
+++ b/protocols/Skype/src/skype_subclassing.cpp
@@ -43,12 +43,6 @@ void CAccount::OnChange(int prop)
}
-void CContact::SetOnContactChangeCallback(OnContactChangeFunc callback, CSkypeProto* proto)
-{
- this->proto = proto;
- this->callback = callback;
-}
-
void CAccount::BlockWhileLoggingIn()
{
while (this->isLoggedOut)
@@ -72,17 +66,18 @@ void CContactGroup::OnChange(const ContactRef& contact)
CContact::CContact(unsigned int oid, SERootObject* root) : Contact(oid, root)
{
+ this->proto = NULL;
+ this->callback == NULL;
}
-//void CAccount::SetOnChangeCallback(OnContactChangeFunc callback, CSkypeProto* proto)
-//{
-// this->proto = proto;
-// this->callback = callback;
-//}
+void CContact::SetOnContactChangeCallback(OnContactChangeFunc callback, CSkypeProto* proto)
+{
+ this->proto = proto;
+ this->callback = callback;
+}
void CContact::OnChange(int prop)
{
- //SEString identity;
- //this->GetIdentity(identity);
- (proto->*callback)(this, prop);
+ if (this->callback && this->proto)
+ (proto->*callback)(this, prop);
} \ No newline at end of file