From b638838fd6ec1eb32d096e0244e8e0d2a8196c73 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Fri, 17 Jan 2014 14:41:49 +0000 Subject: - kernel chat module loads automatically, not on request; - the special structure, CHAT_MANAGER_INITDATA, is used to customize chats; - fix for fonts group for all plugins; - fix for options in tabSRMM git-svn-id: http://svn.miranda-ng.org/main/trunk@7688 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- include/m_chat_int.h | 27 +++++++++++++++++++-------- 1 file changed, 19 insertions(+), 8 deletions(-) (limited to 'include') diff --git a/include/m_chat_int.h b/include/m_chat_int.h index 550b4fcdaa..747c734067 100644 --- a/include/m_chat_int.h +++ b/include/m_chat_int.h @@ -26,7 +26,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include -#define OPTIONS_FONTCOUNT 17 +#define OPTIONS_FONTCOUNT 20 #define STATUSICONCOUNT 6 #define GC_UPDATETITLE (WM_USER+100) @@ -288,6 +288,13 @@ struct GlobalLogSettingsBase ///////////////////////////////////////////////////////////////////////////////////////// +struct CHAT_MANAGER_INITDATA +{ + GlobalLogSettingsBase *pSettings; + int cbModuleInfo, cbSession; + TCHAR *szFontGroup; +}; + struct CHAT_MANAGER { void (*SetActiveSession)(const TCHAR *pszID, const char *pszModule); @@ -363,12 +370,20 @@ struct CHAT_MANAGER HANDLE (*FindRoom)(const char *pszModule, const TCHAR *pszRoom); char* (*Log_CreateRTF)(LOGSTREAMDATA *streamData); + char* (*Log_CreateRtfHeader)(MODULEINFO *mi); void (*LoadMsgDlgFont)(int i, LOGFONT *lf, COLORREF *color); TCHAR* (*MakeTimeStamp)(TCHAR *pszStamp, time_t time); + + BOOL (*DoEventHook)(const TCHAR *pszID, const char *pszModule, int iType, const TCHAR *pszUID, const TCHAR* pszText, INT_PTR dwItem); + BOOL (*DoEventHookAsync)(HWND hwnd, const TCHAR *pszID, const char *pszModule, int iType, TCHAR* pszUID, TCHAR* pszText, INT_PTR dwItem); + + BOOL (*DoSoundsFlashPopupTrayStuff)(SESSION_INFO *si, GCEVENT *gce, BOOL bHighlight, int bManyFix); BOOL (*DoPopup)(SESSION_INFO *si, GCEVENT *gce); int (*ShowPopup)(HANDLE hContact, SESSION_INFO *si, HICON hIcon, char* pszProtoName, TCHAR* pszRoomName, COLORREF crBkg, const TCHAR* fmt, ...); + BOOL (*LogToFile)(SESSION_INFO *si, GCEVENT *gce); + TCHAR* (*RemoveFormatting)(const TCHAR *pszText); - BOOL (*DoSoundsFlashPopupTrayStuff)(SESSION_INFO *si, GCEVENT *gce, BOOL bHighlight, int bManyFix); + void (*ReloadSettings)(void); int logPixelSY, logPixelSX; char *szActiveWndModule; @@ -407,17 +422,13 @@ struct CHAT_MANAGER void (*OnLoadSettings)(void); void (*OnFlashWindow)(SESSION_INFO *si, int); - - // data - GlobalLogSettingsBase *pSettings; - int cbModuleInfo, cbSession; }; extern CHAT_MANAGER ci, *pci; -__forceinline void mir_getCI(GlobalLogSettingsBase *pSettings) +__forceinline void mir_getCI(CHAT_MANAGER_INITDATA *pData) { - pci = (CHAT_MANAGER*)CallService("GChat/GetInterface", 0, (LPARAM)pSettings); + pci = (CHAT_MANAGER*)CallService("GChat/GetInterface", 0, (LPARAM)pData); } #endif // M_CHAT_INT_H__ -- cgit v1.2.3