From 2d737d50469b965c2787823a94757f4c9f0a7107 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 9 Mar 2017 17:28:47 +0300 Subject: chat API: - SESSION_INFO now addresses an instance of CChatRoomDlg instead of HWND; - linked list of sessions replaced with the usual LIST<>; - saveCI removed everywhere --- include/m_chat_int.h | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) (limited to 'include/m_chat_int.h') diff --git a/include/m_chat_int.h b/include/m_chat_int.h index 7b2b0c35b1..c8d9c9bc27 100644 --- a/include/m_chat_int.h +++ b/include/m_chat_int.h @@ -24,6 +24,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #ifndef M_CHAT_INT_H__ #define M_CHAT_INT_H__ 1 +#pragma warning(disable:4512) + #include #include #include @@ -101,6 +103,8 @@ struct SESSION_INFO; struct MODULEINFO; struct LOGSTREAMDATA; +class CChatRoomDlg; + struct GCModuleInfoBase { char* pszModule; @@ -172,7 +176,7 @@ struct USERINFO struct GCSessionInfoBase { - HWND hWnd; + MCONTACT hContact; bool bFGSet; bool bBGSet; @@ -202,11 +206,11 @@ struct GCSessionInfoBase WORD wState; WORD wCommandsNum; void* pItemData; - MCONTACT hContact; time_t LastTime; int currentHovered; + CChatRoomDlg *pDlg; COMMANDINFO* lpCommands; COMMANDINFO* lpCurrentCommand; LOGINFO* pLog; @@ -216,7 +220,6 @@ struct GCSessionInfoBase STATUSINFO* pStatuses; wchar_t pszLogFileName[MAX_PATH]; - SESSION_INFO *next; }; struct GCLogStreamDataBase @@ -290,8 +293,13 @@ struct CHAT_MANAGER_INITDATA int iFontMode; }; +typedef BOOL (*pfnDoTrayIcon)(SESSION_INFO *si, GCEVENT *gce); +typedef BOOL (*pfnDoPopup)(SESSION_INFO *si, GCEVENT *gce); + struct CHAT_MANAGER { + CHAT_MANAGER(); + void (*SetActiveSession)(const wchar_t *pszID, const char *pszModule); void (*SetActiveSessionEx)(SESSION_INFO *si); SESSION_INFO* (*GetActiveSession)(void); @@ -373,7 +381,7 @@ struct CHAT_MANAGER HBRUSH hListBkgBrush, hListSelectedBkgBrush; HANDLE hBuildMenuEvent, hSendEvent; FONTINFO aFonts[OPTIONS_FONTCOUNT]; - SESSION_INFO *wndList; + LIST &arSessions; char **pLogIconBmpBits; MWindowList hWindowList; -- cgit v1.2.3