summaryrefslogtreecommitdiff
path: root/plugins/StatusPlugins/StartupStatus
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/StatusPlugins/StartupStatus')
-rw-r--r--plugins/StatusPlugins/StartupStatus/options.cpp8
-rw-r--r--plugins/StatusPlugins/StartupStatus/profiles.cpp8
-rw-r--r--plugins/StatusPlugins/StartupStatus/startupstatus.cpp4
3 files changed, 10 insertions, 10 deletions
diff --git a/plugins/StatusPlugins/StartupStatus/options.cpp b/plugins/StatusPlugins/StartupStatus/options.cpp
index 31d8324e22..c53573bbf4 100644
--- a/plugins/StatusPlugins/StartupStatus/options.cpp
+++ b/plugins/StatusPlugins/StartupStatus/options.cpp
@@ -133,7 +133,7 @@ static wchar_t* GetLinkDescription(TSettingsList& protoSettings)
if ( protoSettings.getCount() == 0 )
return NULL;
- CMString result(SHORTCUT_DESC);
+ CMStringW result(SHORTCUT_DESC);
for (int i=0; i < protoSettings.getCount(); i++) {
TSSSetting &p = protoSettings[i];
@@ -538,7 +538,7 @@ static INT_PTR CALLBACK StatusProfilesOptDlgProc(HWND hwndDlg,UINT msg,WPARAM wP
if ( ar[j].szMsg != NULL)
ar[j].szMsg = wcsdup( ar[j].szMsg );
- ppo->tszName = db_get_tsa(NULL, MODULENAME, OptName(i, SETTING_PROFILENAME));
+ ppo->tszName = db_get_wsa(NULL, MODULENAME, OptName(i, SETTING_PROFILENAME));
if (ppo->tszName == NULL) {
if (i == defProfile)
ppo->tszName = mir_wstrdup( TranslateT("default"));
@@ -825,13 +825,13 @@ static INT_PTR CALLBACK StatusProfilesOptDlgProc(HWND hwndDlg,UINT msg,WPARAM wP
db_set_b(NULL, MODULENAME, OptName(i, SETTING_INSUBMENU), po.inSubMenu);
db_set_b(NULL, MODULENAME, OptName(i, SETTING_REGHOTKEY), po.regHotkey);
db_set_w(NULL, MODULENAME, OptName(i, SETTING_HOTKEY), po.hotKey);
- db_set_ts(NULL, MODULENAME, OptName(i, SETTING_PROFILENAME), po.tszName);
+ db_set_ws(NULL, MODULENAME, OptName(i, SETTING_PROFILENAME), po.tszName);
TSettingsList& ar = *po.ps;
for (int j=0; j < ar.getCount(); j++) {
if ( ar[j].szMsg != NULL ) {
mir_snprintf(setting, "%s_%s", ar[j].szName, SETTING_PROFILE_STSMSG);
- db_set_ts(NULL, MODULENAME, OptName(i, setting), ar[j].szMsg);
+ db_set_ws(NULL, MODULENAME, OptName(i, setting), ar[j].szMsg);
}
db_set_w(NULL, MODULENAME, OptName(i, ar[j].szName), ar[j].status);
}
diff --git a/plugins/StatusPlugins/StartupStatus/profiles.cpp b/plugins/StatusPlugins/StartupStatus/profiles.cpp
index 6cb631e3cb..03687e5834 100644
--- a/plugins/StatusPlugins/StartupStatus/profiles.cpp
+++ b/plugins/StatusPlugins/StartupStatus/profiles.cpp
@@ -61,7 +61,7 @@ static int CreateMainMenuItems(WPARAM, LPARAM)
{
CMenuItem mi;
mi.position = 2000100000;
- mi.flags = CMIF_TCHAR;
+ mi.flags = CMIF_UNICODE;
mcount = 0;
int count = GetProfileCount(0, 0);
for (int i = 0; i < count && mcount < MAX_MMITEMS; i++) {
@@ -109,7 +109,7 @@ INT_PTR GetProfileName(WPARAM wParam, LPARAM lParam)
DBVARIANT dbv;
char setting[80];
mir_snprintf(setting, "%d_%s", profile, SETTING_PROFILENAME);
- if (db_get_ts(NULL, MODULENAME, setting, &dbv))
+ if (db_get_ws(NULL, MODULENAME, setting, &dbv))
return -1;
wcsncpy(buf, dbv.ptszVal, 128 - 1); buf[127] = 0;
@@ -138,7 +138,7 @@ wchar_t *GetStatusMessage(int profile, char *szProto)
for (int i = 0; i < pceCount; i++) {
if ((pce[i].profile == profile) && (!mir_strcmp(pce[i].szProto, szProto))) {
mir_snprintf(dbSetting, "%d_%s_%s", profile, szProto, SETTING_PROFILE_STSMSG);
- if (!db_get_ts(NULL, MODULENAME, dbSetting, &dbv)) { // reload from db
+ if (!db_get_ws(NULL, MODULENAME, dbSetting, &dbv)) { // reload from db
pce[i].msg = (wchar_t*)realloc(pce[i].msg, sizeof(wchar_t)*(mir_wstrlen(dbv.ptszVal) + 1));
if (pce[i].msg != NULL) {
mir_wstrcpy(pce[i].msg, dbv.ptszVal);
@@ -162,7 +162,7 @@ wchar_t *GetStatusMessage(int profile, char *szProto)
pce[pceCount].szProto = _strdup(szProto);
pce[pceCount].msg = NULL;
mir_snprintf(dbSetting, "%d_%s_%s", profile, szProto, SETTING_PROFILE_STSMSG);
- if (!db_get_ts(NULL, MODULENAME, dbSetting, &dbv)) {
+ if (!db_get_ws(NULL, MODULENAME, dbSetting, &dbv)) {
pce[pceCount].msg = wcsdup(dbv.ptszVal);
db_free(&dbv);
}
diff --git a/plugins/StatusPlugins/StartupStatus/startupstatus.cpp b/plugins/StatusPlugins/StartupStatus/startupstatus.cpp
index 13d708f0de..959d0c71de 100644
--- a/plugins/StatusPlugins/StartupStatus/startupstatus.cpp
+++ b/plugins/StatusPlugins/StartupStatus/startupstatus.cpp
@@ -172,7 +172,7 @@ static void SetLastStatusMessages(TSettingsList &ps)
mir_snprintf(dbSetting, "%s%s", PREFIX_LASTMSG, ps[i].szName);
DBVARIANT dbv;
- if (ps[i].szMsg == NULL && !db_get_ts(NULL, MODULENAME, dbSetting, &dbv)) {
+ if (ps[i].szMsg == NULL && !db_get_ws(NULL, MODULENAME, dbSetting, &dbv)) {
ps[i].szMsg = wcsdup(dbv.ptszVal); // remember this won't be freed
db_free(&dbv);
}
@@ -325,7 +325,7 @@ static int OnOkToExit(WPARAM, LPARAM)
CallService(MS_NAS_GETSTATE, (WPARAM)&npi, 1);
}
if (npi.szMsg != NULL) {
- db_set_ts(NULL, MODULENAME, lastMsg, npi.tszMsg);
+ db_set_ws(NULL, MODULENAME, lastMsg, npi.tszMsg);
mir_free(npi.tszMsg);
}
}