From 78a7d1cf713a7aa4ed541323bf53230d5322ac55 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Mon, 20 Jan 2014 22:10:45 +0000 Subject: - MessageBoxFont setting moved from kernel to StdChat; - tabSRMM default settings restored git-svn-id: http://svn.miranda-ng.org/main/trunk@7807 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- src/core/stdchat/src/chat.h | 5 +++-- src/core/stdchat/src/main.cpp | 8 ++++++++ 2 files changed, 11 insertions(+), 2 deletions(-) (limited to 'src/core') diff --git a/src/core/stdchat/src/chat.h b/src/core/stdchat/src/chat.h index cf157efb7d..83421a44d5 100644 --- a/src/core/stdchat/src/chat.h +++ b/src/core/stdchat/src/chat.h @@ -96,8 +96,9 @@ struct LOGSTREAMDATA : public GCLogStreamDataBase {}; struct GlobalLogSettings : public GlobalLogSettingsBase { - int iX, iY; - bool bTabsEnable, TabsAtBottom, TabCloseOnDblClick, TabRestore; + int iX, iY; + bool bTabsEnable, TabsAtBottom, TabCloseOnDblClick, TabRestore; + HFONT MessageBoxFont; }; extern GlobalLogSettings g_Settings; diff --git a/src/core/stdchat/src/main.cpp b/src/core/stdchat/src/main.cpp index 63688d51cf..61be5168ad 100644 --- a/src/core/stdchat/src/main.cpp +++ b/src/core/stdchat/src/main.cpp @@ -256,6 +256,12 @@ static BOOL DoPopup(SESSION_INFO *si, GCEVENT *gce) static void OnLoadSettings() { + LOGFONT lf; + if (g_Settings.MessageBoxFont) + DeleteObject(g_Settings.MessageBoxFont); + pci->LoadMsgDlgFont(17, &lf, NULL); + g_Settings.MessageBoxFont = CreateFontIndirect(&lf); + g_Settings.iX = db_get_dw(NULL, CHAT_MODULE, "roomx", -1); g_Settings.iY = db_get_dw(NULL, CHAT_MODULE, "roomy", -1); @@ -366,6 +372,8 @@ extern "C" __declspec(dllexport) int Unload(void) db_set_dw(NULL, CHAT_MODULE, "roomwidth" , g_Settings.iWidth); db_set_dw(NULL, CHAT_MODULE, "roomheight", g_Settings.iHeight); + if (g_Settings.MessageBoxFont) + DeleteObject(g_Settings.MessageBoxFont); DestroyMenu(g_hMenu); return 0; } -- cgit v1.2.3