summaryrefslogtreecommitdiff
path: root/plugins/MyDetails/src/data.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2018-11-12 21:44:56 +0300
committerGeorge Hazan <ghazan@miranda.im>2018-11-12 21:44:56 +0300
commit53fe3e46177d17b4941610de19f5cc6210700cb4 (patch)
treeb67a6bc208dad141f9db14035cd7e42ff2a51872 /plugins/MyDetails/src/data.cpp
parent488214ac8af0c4aeb1a5c1d8fd48368daaf4c4c7 (diff)
db_* functions replaced with g_plugin calls
Diffstat (limited to 'plugins/MyDetails/src/data.cpp')
-rw-r--r--plugins/MyDetails/src/data.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/plugins/MyDetails/src/data.cpp b/plugins/MyDetails/src/data.cpp
index 1e2d693278..6038f89487 100644
--- a/plugins/MyDetails/src/data.cpp
+++ b/plugins/MyDetails/src/data.cpp
@@ -442,7 +442,7 @@ void ProtocolArray::SetNicks(const wchar_t *nick)
mir_wstrncpy(default_nick, nick, _countof(default_nick));
- db_set_ws(0, MODULENAME, SETTING_DEFAULT_NICK, nick);
+ g_plugin.setWString(SETTING_DEFAULT_NICK, nick);
for (int i = 0; i < buffer_len; i++)
buffer[i]->SetNick(default_nick);
@@ -462,11 +462,11 @@ void ProtocolArray::SetStatusMsgs(const wchar_t *message)
void ProtocolArray::SetStatusMsgs(int status, const wchar_t *message)
{
- db_set_ws(NULL, "SRAway", StatusModeToDbSetting(status, "Msg"), message);
+ db_set_ws(0, "SRAway", StatusModeToDbSetting(status, "Msg"), message);
// Save default also
- if (!db_get_b(NULL, "SRAway", StatusModeToDbSetting(status, "UsePrev"), 0))
- db_set_ws(NULL, "SRAway", StatusModeToDbSetting(status, "Default"), message);
+ if (!db_get_b(0, "SRAway", StatusModeToDbSetting(status, "UsePrev"), 0))
+ db_set_ws(0, "SRAway", StatusModeToDbSetting(status, "Default"), message);
for (int i = 0; i < buffer_len; i++)
if (buffer[i]->status == status)
@@ -475,7 +475,7 @@ void ProtocolArray::SetStatusMsgs(int status, const wchar_t *message)
void ProtocolArray::GetDefaultNick()
{
- ptrW tszNick(db_get_wsa(0, MODULENAME, SETTING_DEFAULT_NICK));
+ ptrW tszNick(g_plugin.getWStringA(SETTING_DEFAULT_NICK));
if (tszNick)
mir_wstrncpy(default_nick, tszNick, _countof(default_nick));
else