diff options
author | George Hazan <ghazan@miranda.im> | 2021-03-28 19:54:39 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2021-03-28 19:54:39 +0300 |
commit | 6ece128aa05aa29700bed8a4ddf2890eaf4d19eb (patch) | |
tree | 769f333d7b9a8916f2aaf431fb95a8446af80370 /plugins/TabSRMM/src | |
parent | 5b178c09df63446cf810d5de801ce8f00e2f2885 (diff) |
code cleaning
Diffstat (limited to 'plugins/TabSRMM/src')
-rw-r--r-- | plugins/TabSRMM/src/msgdialog.cpp | 2 | ||||
-rw-r--r-- | plugins/TabSRMM/src/msgs.h | 1 | ||||
-rw-r--r-- | plugins/TabSRMM/src/srmm.cpp | 13 |
3 files changed, 5 insertions, 11 deletions
diff --git a/plugins/TabSRMM/src/msgdialog.cpp b/plugins/TabSRMM/src/msgdialog.cpp index b7072842e3..9c5e2a4cc6 100644 --- a/plugins/TabSRMM/src/msgdialog.cpp +++ b/plugins/TabSRMM/src/msgdialog.cpp @@ -710,7 +710,7 @@ void CMsgDialog::OnDestroy() if (!m_bEditNotesActive) {
char *msg = m_message.GetRichTextRtf(true);
if (msg) {
- db_set_utf(m_hContact, SRMSGMOD, "SavedMsg", msg);
+ g_plugin.setUString(m_hContact, "SavedMsg", msg);
mir_free(msg);
}
else g_plugin.delSetting(m_hContact, "SavedMsg");
diff --git a/plugins/TabSRMM/src/msgs.h b/plugins/TabSRMM/src/msgs.h index 8e852a8368..07ddeb7e1f 100644 --- a/plugins/TabSRMM/src/msgs.h +++ b/plugins/TabSRMM/src/msgs.h @@ -856,7 +856,6 @@ struct TIconDescW #define TIMERID_HOVER 10
#define TIMERID_HOVER_T 11
-#define SRMSGMOD "SRMsg"
#define SRMSGMOD_T "Tab_SRMsg"
#define FONTMODULE "TabSRMM_Fonts"
#define CHAT_OLDFONTMODULE "TabSRMM_chat_Fonts"
diff --git a/plugins/TabSRMM/src/srmm.cpp b/plugins/TabSRMM/src/srmm.cpp index 1fdc0d416b..fd910be91c 100644 --- a/plugins/TabSRMM/src/srmm.cpp +++ b/plugins/TabSRMM/src/srmm.cpp @@ -52,8 +52,10 @@ PLUGININFOEX pluginInfoEx = { }; CMPlugin::CMPlugin() : - PLUGIN<CMPlugin>(SRMSGMOD, pluginInfoEx) -{} + PLUGIN<CMPlugin>("SRMsg", pluginInfoEx), + hLogger(RegisterSrmmLog("built-in", L"tabSRMM internal log", &logBuilder)) +{ +} ///////////////////////////////////////////////////////////////////////////////////////// @@ -63,15 +65,8 @@ extern "C" __declspec(dllexport) const MUUID MirandaInterfaces[] = { MIID_SRMM, int CMPlugin::Load() { - if (WinVerMajor() < 5) { - MessageBox(nullptr, TranslateT("This version of TabSRMM requires Windows 2000 or later."), L"tabSRMM", MB_OK | MB_ICONERROR); - return 1; - } - SystemParametersInfo(SPI_GETICONTITLELOGFONT, sizeof(lfDefault), &lfDefault, FALSE); - hLogger = RegisterSrmmLog("built-in", L"tabSRMM internal log", &logBuilder); - Chat_Load(); return LoadSendRecvMessageModule(); |