summaryrefslogtreecommitdiff
path: root/plugins/MirandaG15/src/CContactList.h
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2019-03-12 13:43:31 +0300
committerGeorge Hazan <ghazan@miranda.im>2019-03-12 13:43:31 +0300
commit8dd4143614ffa1a309f07f0b1a19921955f9c3f5 (patch)
treec99f5116020adb618d020fe4df7283fb5268d9ab /plugins/MirandaG15/src/CContactList.h
parent6312425c1ad093cad87a688497728fdb12e24385 (diff)
MirandaG15: warning fixes + massive code cleaning
Diffstat (limited to 'plugins/MirandaG15/src/CContactList.h')
-rw-r--r--plugins/MirandaG15/src/CContactList.h56
1 files changed, 28 insertions, 28 deletions
diff --git a/plugins/MirandaG15/src/CContactList.h b/plugins/MirandaG15/src/CContactList.h
index ed556ce872..ba60174b2c 100644
--- a/plugins/MirandaG15/src/CContactList.h
+++ b/plugins/MirandaG15/src/CContactList.h
@@ -29,19 +29,19 @@ public:
CContactListEntry *pContactListEntry;
};
-class CContactList : public CLCDList<CContactListEntry*,CContactListGroup*>
+class CContactList : public CLCDList<CContactListEntry*, CContactListGroup*>
{
public:
// constructor
CContactList();
// destructor
~CContactList();
-
+
// initializes the list
bool Initialize();
// deinitializes the list
bool Shutdown();
-
+
// called when a contact has been added
void OnContactAdded(MCONTACT hContact);
// called when a contact has been deleted
@@ -49,28 +49,28 @@ public:
// called when the configuration has changed
void OnConfigChanged();
// called when a contacts group has changed
- void OnContactGroupChanged(MCONTACT hContact,tstring strGroup);
+ void OnContactGroupChanged(MCONTACT hContact, tstring strGroup);
// called when a contacts hidden flag has changed
- void OnContactHiddenChanged(MCONTACT hContact, bool bVisibility);
+ void OnContactHiddenChanged(MCONTACT hContact, bool bVisibility);
// called when a contacts nickname has changed
void OnContactNickChanged(MCONTACT hContact, tstring strNick);
// called when a contacts status has changed
- void OnStatusChange(MCONTACT hContact,int iStatus);
+ void OnStatusChange(MCONTACT hContact, int iStatus);
// called when the contacts message count has changed
void OnMessageCountChanged(MCONTACT hContact);
// returns the contact's status
int GetContactStatus(MCONTACT hContact);
// Called to compare two entrys
- static bool CompareEntries(CListEntry<CContactListEntry*,CContactListGroup*> *pLeft,CListEntry<CContactListEntry*,CContactListGroup*> *pRight);
+ static bool CompareEntries(CListEntry<CContactListEntry*, CContactListGroup*> *pLeft, CListEntry<CContactListEntry*, CContactListGroup*> *pRight);
- void SetPosition(CListEntry<CContactListEntry*,CContactListGroup*> *pEntry);
+ void SetPosition(CListEntry<CContactListEntry*, CContactListGroup*> *pEntry);
bool ScrollUp();
bool ScrollDown();
void ShowSelection();
bool SetFont(LOGFONT &lf);
-protected:
+protected:
// returns the contacts group path
tstring GetContactGroupPath(MCONTACT hContact);
@@ -78,7 +78,7 @@ protected:
void AddContact(MCONTACT hContact);
// removes a contact from the list
void RemoveContact(MCONTACT hContact);
-
+
// uninitializes the group objects
void UninitializeGroupObjects();
@@ -92,52 +92,52 @@ protected:
void DeleteGroupObjectByPath(tstring strPath);
// changes the groups membercount
- void ChangeGroupObjectCounters(tstring strGroup,int iMembers,int iOnline=0,int iEvents=0);
+ void ChangeGroupObjectCounters(tstring strGroup, int iMembers, int iOnline = 0, int iEvents = 0);
// returns wether a contact should be listed or not
bool IsVisible(CContactListEntry *pEntry);
// sorts all entries of a group
- void SortGroup(CListContainer<CContactListEntry*,CContactListGroup*> *pGroup);
+ void SortGroup(CListContainer<CContactListEntry*, CContactListGroup*> *pGroup);
// tries to find a contact in the specified group
- CListEntry<CContactListEntry*,CContactListGroup*> *FindContactInGroup(MCONTACT hContact,CListContainer<CContactListEntry*,CContactListGroup*> *pGroup);
-
+ CListEntry<CContactListEntry*, CContactListGroup*> *FindContactInGroup(MCONTACT hContact, CListContainer<CContactListEntry*, CContactListGroup*> *pGroup);
+
// tries to find a group in the specified group
- CListContainer<CContactListEntry*,CContactListGroup*> *FindGroupInGroup(tstring strGroup,CListContainer<CContactListEntry*,CContactListGroup*> *pGroup);
+ CListContainer<CContactListEntry*, CContactListGroup*> *FindGroupInGroup(tstring strGroup, CListContainer<CContactListEntry*, CContactListGroup*> *pGroup);
// Adds a group
- CListContainer<CContactListEntry*,CContactListGroup*> *AddGroupByString(tstring strGroup);
+ CListContainer<CContactListEntry*, CContactListGroup*> *AddGroupByString(tstring strGroup);
// get group by string
- CListContainer<CContactListEntry*,CContactListGroup*> *GetGroupByString(tstring strGroup);
+ CListContainer<CContactListEntry*, CContactListGroup*> *GetGroupByString(tstring strGroup);
// updates the message counter for the specified entry
- void UpdateMessageCounter(CListEntry<CContactListEntry*,CContactListGroup*> *pContactEntry);
+ void UpdateMessageCounter(CListEntry<CContactListEntry*, CContactListGroup*> *pContactEntry);
// refreshes the list
void RefreshList();
// returns the entry for the specified handle
- CListEntry<CContactListEntry*,CContactListGroup*> *FindContact(MCONTACT hContact);
-
+ CListEntry<CContactListEntry*, CContactListGroup*> *FindContact(MCONTACT hContact);
+
// returns the entry for the specified group name
- CListContainer<CContactListEntry*,CContactListGroup*> *FindGroup(tstring strGroup);
+ CListContainer<CContactListEntry*, CContactListGroup*> *FindGroup(tstring strGroup);
// returns the contacts ccontactlistentry class
- static CContactListEntry *GetContactData(CListEntry<CContactListEntry*,CContactListGroup*> *pEntry);
+ static CContactListEntry *GetContactData(CListEntry<CContactListEntry*, CContactListGroup*> *pEntry);
// Called to delete the specified item
void DeleteItem(CContactListEntry *pEntry);
// Called to delete the specified group
void DeleteGroup(CContactListGroup* pGroup);
// Called to draw the specified group
- void DrawGroup(CLCDGfx *pGfx,CContactListGroup* pGroup,bool bOpen,bool bSelected);
+ void DrawGroup(CLCDGfx *pGfx, CContactListGroup* pGroup, bool bOpen, bool bSelected);
// Called to draw the specified entry
- void DrawEntry(CLCDGfx *pGfx,CContactListEntry *pEntry,bool bSelected);
-
- bool m_bUseGroups;
- bool m_bUseMetaContacts;
+ void DrawEntry(CLCDGfx *pGfx, CContactListEntry *pEntry, bool bSelected);
+
+ bool m_bUseGroups = false;
+ bool m_bUseMetaContacts = false;
vector<CContactListGroup*> m_Groups;
- DWORD m_dwLastScroll;
+ DWORD m_dwLastScroll = 0;
HBITMAP m_ahBitmaps[8];
};