diff options
author | Kirill Volinsky <mataes2007@gmail.com> | 2017-09-11 23:49:15 +0300 |
---|---|---|
committer | Kirill Volinsky <mataes2007@gmail.com> | 2017-09-11 23:49:15 +0300 |
commit | e09448dd03e3647717166e92ee818e395041993a (patch) | |
tree | 2733f155bb5fd9313ea08255209da75f738bcedf /plugins | |
parent | b0f44b16bd1138de85a5d17bb42151742f9c8298 (diff) | |
parent | 9834746e6a7e5cf04a32273155265bc3a2f57180 (diff) |
Merge branch 'master' of https://github.com/miranda-ng/miranda-ng
Diffstat (limited to 'plugins')
69 files changed, 192 insertions, 222 deletions
diff --git a/plugins/Alarms/src/alarm_win.cpp b/plugins/Alarms/src/alarm_win.cpp index d419884193..f00893fbc9 100644 --- a/plugins/Alarms/src/alarm_win.cpp +++ b/plugins/Alarms/src/alarm_win.cpp @@ -178,7 +178,7 @@ INT_PTR CALLBACK DlgProcAlarm(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPar if (data->sound_num <= 3) {
char buff[128];
mir_snprintf(buff, "Triggered%d", data->sound_num);
- SkinPlaySound(buff);
+ Skin_PlaySound(buff);
}
else if (data->sound_num == 4) {
if (data->szTitle != NULL && data->szTitle[0] != '\0') {
diff --git a/plugins/Alarms/src/alarmlist.cpp b/plugins/Alarms/src/alarmlist.cpp index 254e5119fd..a8c04b7d42 100755 --- a/plugins/Alarms/src/alarmlist.cpp +++ b/plugins/Alarms/src/alarmlist.cpp @@ -648,7 +648,7 @@ void DoAlarm(ALARM *alarm) if (alarm->sound_num > 0 && alarm->sound_num <= 3) {
char buff[128];
mir_snprintf(buff, "Triggered%d", alarm->sound_num);
- SkinPlaySound(buff);
+ Skin_PlaySound(buff);
}
else if (alarm->sound_num == 4) {
if (alarm->szTitle != NULL && alarm->szTitle[0] != '\0') {
@@ -779,9 +779,9 @@ int IdleChanged(WPARAM, LPARAM lParam) void InitList()
{
- SkinAddNewSoundEx("Triggered1", LPGEN("Alarms"), LPGEN("Alert 1"));
- SkinAddNewSoundEx("Triggered2", LPGEN("Alarms"), LPGEN("Alert 2"));
- SkinAddNewSoundEx("Triggered3", LPGEN("Alarms"), LPGEN("Alert 3"));
+ Skin_AddSound("Triggered1", LPGENW("Alarms"), LPGENW("Alert 1"));
+ Skin_AddSound("Triggered2", LPGENW("Alarms"), LPGENW("Alert 2"));
+ Skin_AddSound("Triggered3", LPGENW("Alarms"), LPGENW("Alert 3"));
// load last checked time
DBVARIANT dbv;
diff --git a/plugins/AutoShutdown/src/shutdownsvc.cpp b/plugins/AutoShutdown/src/shutdownsvc.cpp index 553ec71f87..547efe82fa 100644 --- a/plugins/AutoShutdown/src/shutdownsvc.cpp +++ b/plugins/AutoShutdown/src/shutdownsvc.cpp @@ -328,7 +328,7 @@ static INT_PTR CALLBACK ShutdownDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, L SetWindowLongPtr(GetDlgItem(hwndDlg, IDC_TEXT_HEADER), GWLP_USERDATA, countdown);
SendMessage(hwndDlg, M_UPDATE_COUNTDOWN, 0, countdown);
}
- SkinPlaySound("AutoShutdown_Countdown");
+ Skin_PlaySound("AutoShutdown_Countdown");
if (!SetTimer(hwndDlg, 1, 1000, NULL))
PostMessage(hwndDlg, M_START_SHUTDOWN, 0, 0);
@@ -375,7 +375,7 @@ static INT_PTR CALLBACK ShutdownDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, L if (countdown == 27 || countdown == 24 || countdown == 21 || countdown == 19 ||
countdown == 17 || countdown == 15 || countdown == 13 || countdown == 11 ||
countdown <= 10)
- SkinPlaySound("AutoShutdown_Countdown");
+ Skin_PlaySound("AutoShutdown_Countdown");
}
else KillTimer(hwndDlg, wParam); /* countdown finished */
PostMessage(hwndDlg, M_UPDATE_COUNTDOWN, 0, countdown);
@@ -496,7 +496,7 @@ void InitShutdownSvc(void) {
/* Shutdown Dialog */
hwndShutdownDlg = NULL;
- SkinAddNewSoundExW("AutoShutdown_Countdown", LPGENW("Alerts"), LPGENW("Automatic shutdown countdown"));
+ Skin_AddSound("AutoShutdown_Countdown", LPGENW("Alerts"), LPGENW("Automatic shutdown countdown"));
/* Events */
hEventOkToShutdown = CreateHookableEvent(ME_AUTOSHUTDOWN_OKTOSHUTDOWN);
diff --git a/plugins/AvatarHistory/src/AvatarHistory.cpp b/plugins/AvatarHistory/src/AvatarHistory.cpp index 061060f306..0cc29ece82 100644 --- a/plugins/AvatarHistory/src/AvatarHistory.cpp +++ b/plugins/AvatarHistory/src/AvatarHistory.cpp @@ -127,7 +127,7 @@ static int AvatarChanged(WPARAM hContact, LPARAM lParam) db_free(&dbvOldHash);
return 0;
}
- SkinPlaySound("avatar_removed");
+ Skin_PlaySound("avatar_removed");
// Is a flash avatar or avs could not load it
db_set_ws(hContact, MODULE_NAME, "AvatarHash", L"-");
@@ -142,7 +142,7 @@ static int AvatarChanged(WPARAM hContact, LPARAM lParam) db_free(&dbvOldHash);
return 0;
}
- SkinPlaySound("avatar_changed");
+ Skin_PlaySound("avatar_changed");
db_set_ws(hContact, "AvatarHistory", "AvatarHash", avatar->hash);
wchar_t history_filename[MAX_PATH] = L"";
@@ -343,8 +343,8 @@ extern "C" __declspec(dllexport) int Load(void) Profile_GetPathW(MAX_PATH, profilePath);
- SkinAddNewSoundExW("avatar_changed", LPGENW("Avatar history"), LPGENW("Contact changed avatar"));
- SkinAddNewSoundExW("avatar_removed", LPGENW("Avatar history"), LPGENW("Contact removed avatar"));
+ Skin_AddSound("avatar_changed", LPGENW("Avatar history"), LPGENW("Contact changed avatar"));
+ Skin_AddSound("avatar_removed", LPGENW("Avatar history"), LPGENW("Contact removed avatar"));
hAvatarWindowsList = WindowList_Create();
diff --git a/plugins/BASS_interface/src/Main.cpp b/plugins/BASS_interface/src/Main.cpp index 5c770678b0..2630ff4e68 100644 --- a/plugins/BASS_interface/src/Main.cpp +++ b/plugins/BASS_interface/src/Main.cpp @@ -215,7 +215,7 @@ INT_PTR CALLBACK OptionsProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPara SendMessage(hwndSlider, TBM_SETPOS, TRUE, Volume);
Preview = TRUE;
if (EnPreview)
- SkinPlaySound("AlertMsg");
+ Skin_PlaySound("AlertMsg");
SendMessage(GetParent(hwndDlg), PSM_CHANGED, 0, 0);
}
break;
@@ -391,7 +391,7 @@ static LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPAR SendMessage(hwndOptSlider, TBM_SETPOS, TRUE, Volume);
Preview = TRUE;
if (EnPreview)
- SkinPlaySound("AlertMsg");
+ Skin_PlaySound("AlertMsg");
}
break;
diff --git a/plugins/BuddyExpectator/src/BuddyExpectator.cpp b/plugins/BuddyExpectator/src/BuddyExpectator.cpp index 83b36d2630..2b1b4ce00b 100644 --- a/plugins/BuddyExpectator/src/BuddyExpectator.cpp +++ b/plugins/BuddyExpectator/src/BuddyExpectator.cpp @@ -247,7 +247,7 @@ bool isContactGoneFor(MCONTACT hContact, int days) CallService(MS_POPUP_ADDPOPUPT, (WPARAM)&ppd, APF_NEWDATA);
- SkinPlaySound("buddyExpectatorHide");
+ Skin_PlaySound("buddyExpectatorHide");
}
return (daysSinceOnline >= days && (daysSinceMessage == -1 || daysSinceMessage >= days));
@@ -258,7 +258,7 @@ void ReturnNotify(MCONTACT hContact, wchar_t *message) if (db_get_b(hContact, "CList", "NotOnList", 0) == 1 || db_get_b(hContact, "CList", "Hidden", 0) == 1)
return;
- SkinPlaySound("buddyExpectatorReturn");
+ Skin_PlaySound("buddyExpectatorReturn");
if (options.iShowPopup > 0) {
// Display Popup
@@ -501,7 +501,7 @@ int SettingChanged(WPARAM hContact, LPARAM lParam) CallService(MS_POPUP_ADDPOPUPT, (WPARAM)&ppd, APF_NEWDATA);
- SkinPlaySound("buddyExpectatorMissYou");
+ Skin_PlaySound("buddyExpectatorMissYou");
}
}
@@ -549,7 +549,7 @@ void CALLBACK TimerProc(HWND, UINT, UINT_PTR, DWORD) if (proto && (db_get_b(hContact, proto, "ChatRoom", 0) == 0) && (CallProtoService(proto, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_IMSEND) && isContactGoneFor(hContact, options.iAbsencePeriod2) && (db_get_b(hContact, MODULE_NAME, "StillAbsentNotified", 0) == 0))
{
db_set_b(hContact, MODULE_NAME, "StillAbsentNotified", 1);
- SkinPlaySound("buddyExpectatorStillAbsent");
+ Skin_PlaySound("buddyExpectatorStillAbsent");
wchar_t* message = TranslateT("has not returned after a long absence.");
time_t tmpTime;
@@ -593,10 +593,10 @@ int ModulesLoaded(WPARAM, LPARAM) HookEvent(ME_USERINFO_INITIALISE, UserinfoInit);
// add sounds support
- SkinAddNewSoundExW("buddyExpectatorReturn", LPGENW("BuddyExpectator"), LPGENW("Contact returned"));
- SkinAddNewSoundExW("buddyExpectatorStillAbsent", LPGENW("BuddyExpectator"), LPGENW("Contact still absent"));
- SkinAddNewSoundExW("buddyExpectatorMissYou", LPGENW("BuddyExpectator"), LPGENW("Miss you event"));
- SkinAddNewSoundExW("buddyExpectatorHide", LPGENW("BuddyExpectator"), LPGENW("Hide contact event"));
+ Skin_AddSound("buddyExpectatorReturn", LPGENW("BuddyExpectator"), LPGENW("Contact returned"));
+ Skin_AddSound("buddyExpectatorStillAbsent", LPGENW("BuddyExpectator"), LPGENW("Contact still absent"));
+ Skin_AddSound("buddyExpectatorMissYou", LPGENW("BuddyExpectator"), LPGENW("Miss you event"));
+ Skin_AddSound("buddyExpectatorHide", LPGENW("BuddyExpectator"), LPGENW("Hide contact event"));
timer_id = SetTimer(0, 0, 1000 * 60 * 60 * 4, TimerProc); // check every 4 hours
diff --git a/plugins/ChangeKeyboardLayout/src/hook_events.cpp b/plugins/ChangeKeyboardLayout/src/hook_events.cpp index 4fb45f049e..6f1451a5bb 100644 --- a/plugins/ChangeKeyboardLayout/src/hook_events.cpp +++ b/plugins/ChangeKeyboardLayout/src/hook_events.cpp @@ -122,8 +122,8 @@ int ModulesLoaded(WPARAM, LPARAM) ReadPopupOptions();
// Зарегим звук
- SkinAddNewSoundEx(SND_ChangeLayout, ModuleName, LPGEN("Changing Layout"));
- SkinAddNewSoundEx(SND_ChangeCase, ModuleName, LPGEN("Changing Case"));
+ Skin_AddSound(SND_ChangeLayout, ModuleNameW, LPGENW("Changing Layout"));
+ Skin_AddSound(SND_ChangeCase, ModuleNameW, LPGENW("Changing Case"));
// Хук на нажатие клавиши
kbHook_All = SetWindowsHookEx(WH_KEYBOARD, (HOOKPROC)Keyboard_Hook, NULL, GetCurrentThreadId());
diff --git a/plugins/ChangeKeyboardLayout/src/stdafx.h b/plugins/ChangeKeyboardLayout/src/stdafx.h index 6eb9e0fadf..b1a3bac5f5 100644 --- a/plugins/ChangeKeyboardLayout/src/stdafx.h +++ b/plugins/ChangeKeyboardLayout/src/stdafx.h @@ -26,7 +26,8 @@ #include "version.h"
#define MaxTextSize 64000
-#define ModuleName LPGEN("ChangeKeyboardLayout")
+#define ModuleName LPGEN("ChangeKeyboardLayout")
+#define ModuleNameW LPGENW("ChangeKeyboardLayout")
// History++ API
#define MS_HPP_EG_WINDOW "History++/ExtGrid/NewWindow"
diff --git a/plugins/ChangeKeyboardLayout/src/text_operations.cpp b/plugins/ChangeKeyboardLayout/src/text_operations.cpp index c8c44b1042..7df6916a89 100644 --- a/plugins/ChangeKeyboardLayout/src/text_operations.cpp +++ b/plugins/ChangeKeyboardLayout/src/text_operations.cpp @@ -436,9 +436,9 @@ int ChangeLayout(HWND hTextWnd, BYTE TextOperation, BOOL CurrentWord) }
if (TextOperation == TOT_Layout)
- SkinPlaySound(SND_ChangeLayout);
+ Skin_PlaySound(SND_ChangeLayout);
else if (TextOperation == TOT_Case)
- SkinPlaySound(SND_ChangeCase);
+ Skin_PlaySound(SND_ChangeCase);
if (moOptions.CopyToClipboard)
CopyTextToClipboard(ptszMBox);
@@ -540,9 +540,9 @@ int ChangeLayout(HWND hTextWnd, BYTE TextOperation, BOOL CurrentWord) InvalidateRect(hTextWnd, NULL, FALSE);
if (TextOperation == TOT_Layout)
- SkinPlaySound(SND_ChangeLayout);
+ Skin_PlaySound(SND_ChangeLayout);
else if (TextOperation == TOT_Case)
- SkinPlaySound(SND_ChangeCase);
+ Skin_PlaySound(SND_ChangeCase);
}
return 0;
diff --git a/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp b/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp index 30f6df1406..cca57b1975 100644 --- a/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp +++ b/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp @@ -250,7 +250,7 @@ int ContactSettingChanged(WPARAM hContact, LPARAM lParam) }
if (PerContactSetting == NOTIFY_ALWAYS || (PopupOptPage.GetValue(IDC_POPUPOPTDLG_POPUPNOTIFY) && (g_PreviewOptPage || PerContactSetting == NOTIFY_ALMOST_ALWAYS || -1 == PcreCheck(sd.MirVer)))) {
ShowPopup(&sd);
- SkinPlaySound(CLIENTCHANGED_SOUND);
+ Skin_PlaySound(CLIENTCHANGED_SOUND);
}
}
@@ -322,7 +322,8 @@ int MirandaLoaded(WPARAM, LPARAM) HookEvent(ME_SYSTEM_MODULELOAD, ModuleLoad);
HookEvent(ME_SYSTEM_MODULEUNLOAD, ModuleLoad);
HookEvent(ME_DB_CONTACT_SETTINGCHANGED, ContactSettingChanged);
- SkinAddNewSoundEx(CLIENTCHANGED_SOUND, NULL, LPGEN("ClientChangeNotify: Client changed"));
+
+ Skin_AddSound(CLIENTCHANGED_SOUND, nullptr, LPGENW("ClientChangeNotify: Client changed"));
if (bPopupExists) {
CreateServiceFunction(MS_CCN_TOGGLEPOPUPS, srvTogglePopups);
diff --git a/plugins/ConnectionNotify/src/ConnectionNotify.cpp b/plugins/ConnectionNotify/src/ConnectionNotify.cpp index 9bec312628..fe7a0d9aa1 100644 --- a/plugins/ConnectionNotify/src/ConnectionNotify.cpp +++ b/plugins/ConnectionNotify/src/ConnectionNotify.cpp @@ -707,7 +707,7 @@ static unsigned __stdcall checkthread(void *) if (WAIT_OBJECT_0 == WaitForSingleObject(hExceptionsMutex, 100)) {
if (checkFilter(connExceptions, cur)) {
showMsg(cur->PName, cur->Pid, cur->strIntIp, cur->strExtIp, cur->intIntPort, cur->intExtPort, cur->state);
- SkinPlaySound(PLUGINNAME_NEWSOUND);
+ Skin_PlaySound(PLUGINNAME_NEWSOUND);
}
ReleaseMutex(hExceptionsMutex);
}
@@ -876,7 +876,7 @@ extern "C" int __declspec(dllexport) Load(void) CreateProtoServiceFunction(PLUGINNAME, PS_SETSTATUS, SetStatus);
CreateProtoServiceFunction(PLUGINNAME, PS_GETSTATUS, GetStatus);
- SkinAddNewSoundEx(PLUGINNAME_NEWSOUND, PLUGINNAME, LPGEN("New Connection Notification"));
+ Skin_AddSound(PLUGINNAME_NEWSOUND, PLUGINNAMEW, LPGENW("New Connection Notification"));
hOptInit = HookEvent(ME_OPT_INITIALISE, ConnectionNotifyOptInit);//register service to hook option call
assert(hOptInit);
hHookModulesLoaded = HookEvent(ME_SYSTEM_MODULESLOADED, modulesloaded);//hook event that all plugins are loaded
diff --git a/plugins/ConnectionNotify/src/stdafx.h b/plugins/ConnectionNotify/src/stdafx.h index 4e7f512ad0..f14056ff09 100644 --- a/plugins/ConnectionNotify/src/stdafx.h +++ b/plugins/ConnectionNotify/src/stdafx.h @@ -26,6 +26,7 @@ #define MAX_SETTING_STR 512
#define PLUGINNAME "ConnectionNotify"
+#define PLUGINNAMEW L"ConnectionNotify"
#define MAX_LENGTH 512
#define STATUS_COUNT 9
diff --git a/plugins/ContactsPlus/src/main.cpp b/plugins/ContactsPlus/src/main.cpp index 23500aa6f3..5e3289a06a 100644 --- a/plugins/ContactsPlus/src/main.cpp +++ b/plugins/ContactsPlus/src/main.cpp @@ -70,7 +70,7 @@ static int HookDBEventAdded(WPARAM hContact, LPARAM hDbEvent) dbe.pBlob = (PBYTE)_alloca(dbe.cbBlob);
db_event_get(hDbEvent, &dbe);
//play received sound
- SkinPlaySound("RecvContacts");
+ Skin_PlaySound("RecvContacts");
{
//add event to the contact list
wchar_t caToolTip[128];
@@ -219,8 +219,8 @@ extern "C" __declspec(dllexport) int Load(void) CreateServiceFunction(MS_CONTACTS_RECEIVE, ServiceReceiveCommand);
//define event sounds
- SkinAddNewSoundEx("RecvContacts", LPGEN("Events"), LPGEN("Incoming Contacts"), "contacts.wav");
- SkinAddNewSoundEx("SentContacts", LPGEN("Events"), LPGEN("Outgoing Contacts"), "ocontacts.wav");
+ Skin_AddSound("RecvContacts", LPGENW("Events"), LPGENW("Incoming Contacts"), L"contacts.wav");
+ Skin_AddSound("SentContacts", LPGENW("Events"), LPGENW("Outgoing Contacts"), L"ocontacts.wav");
return 0;
}
diff --git a/plugins/ContactsPlus/src/send.cpp b/plugins/ContactsPlus/src/send.cpp index cb2318aa17..1016a386dc 100644 --- a/plugins/ContactsPlus/src/send.cpp +++ b/plugins/ContactsPlus/src/send.cpp @@ -431,7 +431,7 @@ INT_PTR CALLBACK SendDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPara }
delete ackData; // all done, release structure
if (!wndData->uacklist.Count) {
- SkinPlaySound("SentContacts");
+ Skin_PlaySound("SentContacts");
KillTimer(hwndDlg, TIMERID_MSGSEND);
if (wndData->hError)
diff --git a/plugins/FTPFileYM/src/dialog.cpp b/plugins/FTPFileYM/src/dialog.cpp index 0735bedc22..9fbc7b8b57 100644 --- a/plugins/FTPFileYM/src/dialog.cpp +++ b/plugins/FTPFileYM/src/dialog.cpp @@ -395,7 +395,7 @@ INT_PTR CALLBACK UploadDialog::UploadDlgProc(HWND hwndDlg, UINT msg, WPARAM wPar result = Utils::msgBox(TranslateT("Do you really want to cancel all running jobs?"), MB_YESNO | MB_ICONQUESTION);
if (result == IDYES) {
- SkinPlaySound(SOUND_CANCEL);
+ Skin_PlaySound(SOUND_CANCEL);
size_t count = uDlg->m_tabs.size();
for (UINT i = 0; i < count; i++)
uDlg->m_tabs[0]->m_job->closeAllTabs();
diff --git a/plugins/FTPFileYM/src/ftpfile.cpp b/plugins/FTPFileYM/src/ftpfile.cpp index 91de6e0066..ae85f49aa6 100644 --- a/plugins/FTPFileYM/src/ftpfile.cpp +++ b/plugins/FTPFileYM/src/ftpfile.cpp @@ -353,8 +353,8 @@ int ModulesLoaded(WPARAM, LPARAM) InitMenuItems();
InitTabsrmmButton();
- SkinAddNewSoundEx(SOUND_UPCOMPLETE, LPGEN("FTP File"), LPGEN("File upload complete"));
- SkinAddNewSoundEx(SOUND_CANCEL, LPGEN("FTP File"), LPGEN("Upload canceled"));
+ Skin_AddSound(SOUND_UPCOMPLETE, LPGENW("FTP File"), LPGENW("File upload complete"));
+ Skin_AddSound(SOUND_CANCEL, LPGENW("FTP File"), LPGENW("Upload canceled"));
curl_global_init(CURL_GLOBAL_ALL);
diff --git a/plugins/FTPFileYM/src/job_upload.cpp b/plugins/FTPFileYM/src/job_upload.cpp index e80e5ed9f5..a519e897c4 100644 --- a/plugins/FTPFileYM/src/job_upload.cpp +++ b/plugins/FTPFileYM/src/job_upload.cpp @@ -339,7 +339,7 @@ void UploadJob::upload() }
DBEntry::add(this);
- SkinPlaySound(SOUND_UPCOMPLETE);
+ Skin_PlaySound(SOUND_UPCOMPLETE);
}
setStatus(STATUS_COMPLETED);
diff --git a/plugins/FileAsMessage/src/dialog.cpp b/plugins/FileAsMessage/src/dialog.cpp index ac13c114d1..dfb4a1c644 100644 --- a/plugins/FileAsMessage/src/dialog.cpp +++ b/plugins/FileAsMessage/src/dialog.cpp @@ -450,7 +450,7 @@ void FILEECHO::incomeRequest(char *param) setState(STATE_PRERECV);
inSend = FALSE;
- SkinPlaySound("RecvFile");
+ Skin_PlaySound("RecvFile");
int AutoMin = db_get_b(NULL, "SRFile", "AutoMin", 0);
if (db_get_b(NULL, "SRFile", "AutoAccept", 0) && !db_get_b(hContact, "CList", "NotOnList", 0))
{
@@ -548,7 +548,7 @@ void FILEECHO::onRecvTimer() PostMessage(hDlg, WM_CLOSE, 0, 0);
pcli->pfnRemoveEvent(hContact, 0);
}
- SkinPlaySound("FileDone");
+ Skin_PlaySound("FileDone");
destroyTransfer();
buffer[0] = 'x'; buffer[1] = 0;
}
@@ -719,7 +719,7 @@ void FILEECHO::cmdDACK(char *param) char *msg = Translate("Sent successfully");
SetDlgItemText(hDlg, IDC_STATUS, msg);
- SkinPlaySound("FileDone");
+ Skin_PlaySound("FileDone");
destroyTransfer();
MakePopupMsg(hDlg, hContact, msg);
setState(STATE_FINISHED);
diff --git a/plugins/GmailNotifier/src/main.cpp b/plugins/GmailNotifier/src/main.cpp index dabac93804..d2912d2082 100644 --- a/plugins/GmailNotifier/src/main.cpp +++ b/plugins/GmailNotifier/src/main.cpp @@ -91,7 +91,7 @@ extern "C" int __declspec(dllexport) Load() mir_getLP(&pluginInfoEx);
pcli = Clist_GetInterface();
- SkinAddNewSoundEx("Gmail", LPGEN("Other"), LPGEN("Gmail: New thread(s)"));
+ Skin_AddSound("Gmail", LPGENW("Other"), LPGENW("Gmail: New thread(s)"));
HookEvent(ME_CLIST_DOUBLECLICKED, OpenBrowser);
PROTOCOLDESCRIPTOR pd = { PROTOCOLDESCRIPTOR_V3_SIZE };
diff --git a/plugins/GmailNotifier/src/notify.cpp b/plugins/GmailNotifier/src/notify.cpp index eb99a41ec4..7e90749477 100644 --- a/plugins/GmailNotifier/src/notify.cpp +++ b/plugins/GmailNotifier/src/notify.cpp @@ -120,7 +120,7 @@ void NotifyUser(Account *curAcc) PUAddPopup(&ppd);
}
if (newMails > 0)
- SkinPlaySound("Gmail");
+ Skin_PlaySound("Gmail");
}
curAcc->oldResults_num = curAcc->results_num;
DeleteResults(curAcc->results.next);
diff --git a/plugins/LotusNotify/src/LotusNotify.cpp b/plugins/LotusNotify/src/LotusNotify.cpp index 90a1d3fe59..6e55f2a8e3 100644 --- a/plugins/LotusNotify/src/LotusNotify.cpp +++ b/plugins/LotusNotify/src/LotusNotify.cpp @@ -790,7 +790,7 @@ void checkthread(void*) log(L"checkthread: filters checked - positive");
///TODO eliminate popups with blank fields
showMsg(msgFrom, msgSubject, noteID, strLink);
- SkinPlaySound("LotusNotify");
+ Skin_PlaySound("LotusNotify");
}
else {
log(L"checkthread: filters checked - negative");
@@ -1728,7 +1728,7 @@ extern "C" int __declspec(dllexport) Load(void) LoadSettings(); //read from db to variables
- SkinAddNewSoundExW("LotusNotify", LPGENW("Lotus Notify"), LPGENW("New Lotus document detected"));
+ Skin_AddSound("LotusNotify", LPGENW("Lotus Notify"), LPGENW("New Lotus document detected"));
hOptInit = HookEvent(ME_OPT_INITIALISE, LotusNotifyOptInit); //register service to hook option call
assert(hOptInit);
diff --git a/plugins/MirLua/src/m_sounds.cpp b/plugins/MirLua/src/m_sounds.cpp index ea7c2a5e6a..b7e86b4c91 100644 --- a/plugins/MirLua/src/m_sounds.cpp +++ b/plugins/MirLua/src/m_sounds.cpp @@ -7,16 +7,7 @@ static int sounds_AddSound(lua_State *L) ptrW section(mir_utf8decodeW(luaL_optstring(L, 3, MODULE)));
ptrW filePath(mir_utf8decodeW(lua_tostring(L, 4)));
- SKINSOUNDDESCEX ssd = { sizeof(SKINSOUNDDESCEX) };
- ssd.pszName = name;
- ssd.dwFlags = SSDF_UNICODE;
- ssd.pwszDescription = description;
- ssd.pwszSection = section;
- ssd.pwszDefaultFile = filePath;
-
- int hScriptLangpack = CMLuaScript::GetScriptIdFromEnviroment(L);
-
- INT_PTR res = CallService("Skin/Sounds/AddNew", hScriptLangpack, (LPARAM)&ssd);
+ int res = Skin_AddSound(name, section, description, filePath, CMLuaScript::GetScriptIdFromEnviroment(L));
lua_pushboolean(L, res == 0);
return 1;
@@ -26,7 +17,7 @@ static int sounds_PlaySound(lua_State *L) {
const char *name = luaL_checkstring(L, 1);
- INT_PTR res = SkinPlaySound(name);
+ INT_PTR res = Skin_PlaySound(name);
lua_pushboolean(L, res == 0);
return 1;
@@ -36,7 +27,7 @@ static int sounds_PlayFile(lua_State *L) {
ptrW filePath(mir_utf8decodeW(luaL_checkstring(L, 1)));
- INT_PTR res = SkinPlaySoundFile(filePath);
+ INT_PTR res = Skin_PlaySoundFile(filePath);
lua_pushboolean(L, res == 0);
return 1;
diff --git a/plugins/NewAwaySysMod/src/AwaySys.cpp b/plugins/NewAwaySysMod/src/AwaySys.cpp index f1e0e4794c..efe43115c4 100644 --- a/plugins/NewAwaySysMod/src/AwaySys.cpp +++ b/plugins/NewAwaySysMod/src/AwaySys.cpp @@ -687,7 +687,7 @@ int MirandaLoaded(WPARAM, LPARAM) // we have to read the status message from contacts too... err
CreateServiceFunction(MS_AWAYMSG_SHOWAWAYMSG, GetContactStatMsg);
- SkinAddNewSoundEx(AWAYSYS_STATUSMSGREQUEST_SOUND, NULL, LPGEN("NewAwaySys: Incoming status message request"));
+ Skin_AddSound(AWAYSYS_STATUSMSGREQUEST_SOUND, nullptr, LPGENW("NewAwaySys: Incoming status message request"));
if (ServiceExists(MS_VARS_REGISTERTOKEN)) {
CreateServiceFunction(MS_AWAYSYS_FREEVARMEM, srvFreeVarMem);
diff --git a/plugins/NewXstatusNotify/src/indsnd.cpp b/plugins/NewXstatusNotify/src/indsnd.cpp index 8d5a27e7b1..6c7d5e9ee5 100644 --- a/plugins/NewXstatusNotify/src/indsnd.cpp +++ b/plugins/NewXstatusNotify/src/indsnd.cpp @@ -35,13 +35,13 @@ void PreviewSound(HWND hList) ListView_GetItemText(hList, lvi.iItem, 1, buff, _countof(buff));
if (!mir_wstrcmp(buff, TranslateW(DEFAULT_SOUND))) {
if (hlpStatus < ID_STATUS_MIN)
- SkinPlaySound(StatusListEx[hlpStatus].lpzSkinSoundName);
+ Skin_PlaySound(StatusListEx[hlpStatus].lpzSkinSoundName);
else
- SkinPlaySound(StatusList[Index(hlpStatus)].lpzSkinSoundName);
+ Skin_PlaySound(StatusList[Index(hlpStatus)].lpzSkinSoundName);
}
else {
PathToAbsoluteW(buff, stzSoundPath);
- SkinPlaySoundFile(stzSoundPath);
+ Skin_PlaySoundFile(stzSoundPath);
}
}
diff --git a/plugins/NewXstatusNotify/src/main.cpp b/plugins/NewXstatusNotify/src/main.cpp index aca8e1d4fd..fa54d48e23 100644 --- a/plugins/NewXstatusNotify/src/main.cpp +++ b/plugins/NewXstatusNotify/src/main.cpp @@ -334,13 +334,13 @@ void PlayChangeSound(MCONTACT hContact, const char *name) //Now make path to IndSound absolute, as it isn't registered
wchar_t stzSoundPath[MAX_PATH];
PathToAbsoluteW(stzSoundFile, stzSoundPath);
- SkinPlaySoundFile(stzSoundPath);
+ Skin_PlaySoundFile(stzSoundPath);
return;
}
}
if (db_get_b(0, "SkinSoundsOff", name, 0) == 0)
- SkinPlaySound(name);
+ Skin_PlaySound(name);
}
int ContactStatusChanged(MCONTACT hContact, WORD oldStatus, WORD newStatus)
@@ -1104,10 +1104,10 @@ void InitIcolib() void InitSound()
{
for (int i = ID_STATUS_MIN; i <= ID_STATUS_MAX; i++)
- SkinAddNewSoundExW(StatusList[Index(i)].lpzSkinSoundName, LPGENW("Status Notify"), StatusList[Index(i)].lpzSkinSoundDesc);
+ Skin_AddSound(StatusList[Index(i)].lpzSkinSoundName, LPGENW("Status Notify"), StatusList[Index(i)].lpzSkinSoundDesc);
for (int i = 0; i <= ID_STATUSEX_MAX; i++)
- SkinAddNewSoundExW(StatusListEx[i].lpzSkinSoundName, LPGENW("Status Notify"), StatusListEx[i].lpzSkinSoundDesc);
+ Skin_AddSound(StatusListEx[i].lpzSkinSoundName, LPGENW("Status Notify"), StatusListEx[i].lpzSkinSoundDesc);
}
int InitTopToolbar(WPARAM, LPARAM)
diff --git a/plugins/NotesAndReminders/src/main.cpp b/plugins/NotesAndReminders/src/main.cpp index 8341330d1a..e006e4f13b 100644 --- a/plugins/NotesAndReminders/src/main.cpp +++ b/plugins/NotesAndReminders/src/main.cpp @@ -150,9 +150,9 @@ static void InitServices() {
// register sounds
- SkinAddNewSoundEx("AlertReminder", LPGEN("Alerts"), LPGEN("Reminder triggered"));
- SkinAddNewSoundEx("AlertReminder2", LPGEN("Alerts"), LPGEN("Reminder triggered (Alternative 1)"));
- SkinAddNewSoundEx("AlertReminder3", LPGEN("Alerts"), LPGEN("Reminder triggered (Alternative 2)"));
+ Skin_AddSound("AlertReminder", LPGENW("Alerts"), LPGENW("Reminder triggered"));
+ Skin_AddSound("AlertReminder2", LPGENW("Alerts"), LPGENW("Reminder triggered (Alternative 1)"));
+ Skin_AddSound("AlertReminder3", LPGENW("Alerts"), LPGENW("Reminder triggered (Alternative 2)"));
// register menu command services
diff --git a/plugins/NotesAndReminders/src/reminders.cpp b/plugins/NotesAndReminders/src/reminders.cpp index f999000d78..3bb2361b9a 100644 --- a/plugins/NotesAndReminders/src/reminders.cpp +++ b/plugins/NotesAndReminders/src/reminders.cpp @@ -458,10 +458,10 @@ void GetTriggerTimeString(const ULARGE_INTEGER *When, char *s, UINT strSize, BOO else mir_snprintf(s, strSize, "%d-%02d-%02d %02d:%02d", tm.wYear, tm.wMonth, tm.wDay, tm.wHour, tm.wMinute);
}
-static void SkinPlaySoundPoly(LPCSTR pszSoundName)
+static void Skin_PlaySoundPoly(LPCSTR pszSoundName)
{
if (g_UseDefaultPlaySound) {
- SkinPlaySound(pszSoundName);
+ Skin_PlaySound(pszSoundName);
return;
}
@@ -501,10 +501,10 @@ static void UpdateReminderEvent(REMINDERDATA *pReminder, UINT nElapsedSeconds, B if (!(*pHasPlayedSound & dwSoundMask)) {
switch (pReminder->SoundSel) {
- case 1: SkinPlaySoundPoly("AlertReminder2"); break;
- case 2: SkinPlaySoundPoly("AlertReminder3"); break;
+ case 1: Skin_PlaySoundPoly("AlertReminder2"); break;
+ case 2: Skin_PlaySoundPoly("AlertReminder3"); break;
default:
- SkinPlaySoundPoly("AlertReminder");
+ Skin_PlaySoundPoly("AlertReminder");
}
*pHasPlayedSound |= dwSoundMask;
@@ -546,10 +546,10 @@ static void FireReminder(REMINDERDATA *pReminder, BOOL *pHasPlayedSound) if (!(*pHasPlayedSound & dwSoundMask)) {
switch (pReminder->SoundSel) {
- case 1: SkinPlaySoundPoly("AlertReminder2"); break;
- case 2: SkinPlaySoundPoly("AlertReminder3"); break;
+ case 1: Skin_PlaySoundPoly("AlertReminder2"); break;
+ case 2: Skin_PlaySoundPoly("AlertReminder3"); break;
default:
- SkinPlaySoundPoly("AlertReminder");
+ Skin_PlaySoundPoly("AlertReminder");
}
*pHasPlayedSound |= dwSoundMask;
@@ -1825,9 +1825,9 @@ static INT_PTR CALLBACK DlgProcNewReminder(HWND Dialog, UINT Message, WPARAM wPa int n = SendDlgItemMessage(Dialog, IDC_COMBO_SOUND, CB_GETCURSEL, 0, 0);
n = (int)SendDlgItemMessage(Dialog, IDC_COMBO_SOUND, CB_GETITEMDATA, n, 0);
switch (n) {
- case 0: SkinPlaySound("AlertReminder"); break;
- case 1: SkinPlaySound("AlertReminder2"); break;
- case 2: SkinPlaySound("AlertReminder3"); break;
+ case 0: Skin_PlaySound("AlertReminder"); break;
+ case 1: Skin_PlaySound("AlertReminder2"); break;
+ case 2: Skin_PlaySound("AlertReminder3"); break;
}
}
return TRUE;
diff --git a/plugins/NotifyAnything/src/main.cpp b/plugins/NotifyAnything/src/main.cpp index 3e72bf9f3d..598837dfc3 100644 --- a/plugins/NotifyAnything/src/main.cpp +++ b/plugins/NotifyAnything/src/main.cpp @@ -142,15 +142,7 @@ void registerSound(const std::wstring &name) std::wstring id = L"NotifyAnything_" + name;
std::wstring desc = L"NotifyAnything: " + name;
std::wstring file = name + L".wav";
-
- SKINSOUNDDESCEX ssd = { 0 };
- ssd.cbSize = sizeof(ssd);
- ssd.dwFlags = SSDF_UNICODE;
- ssd.pszName = _T2A(id.c_str());
- ssd.pwszSection = LPGENW("Notify Anything");
- ssd.pwszDescription = desc.c_str();
- ssd.pwszDefaultFile = file.c_str();
- Skin_AddSound(&ssd);
+ Skin_AddSound(_T2A(id.c_str()), LPGENW("Notify Anything"), desc.c_str(), file.c_str());
}
HICON getIcon(const std::wstring &name)
@@ -823,7 +815,7 @@ void processMessage(std::wstring buf) Beep(650, 50);
else {
std::wstring sname = L"NotifyAnything_" + msg.sound;
- SkinPlaySound(_T2A(sname.c_str()));
+ Skin_PlaySound(_T2A(sname.c_str()));
}
}
}
diff --git a/plugins/Nudge/src/main.cpp b/plugins/Nudge/src/main.cpp index a956df53bd..5c90b286ae 100644 --- a/plugins/Nudge/src/main.cpp +++ b/plugins/Nudge/src/main.cpp @@ -139,7 +139,7 @@ int NudgeReceived(WPARAM hContact, LPARAM lParam) if (p.autoResend)
mir_forkthread(AutoResendNudge, (void*)hContact);
- SkinPlaySound(p.NudgeSoundname);
+ Skin_PlaySound(p.NudgeSoundname);
}
}
@@ -182,7 +182,7 @@ int NudgeReceived(WPARAM hContact, LPARAM lParam) if (DefaultNudge.autoResend)
mir_forkthread(AutoResendNudge, (void*)hContact);
- SkinPlaySound(DefaultNudge.NudgeSoundname);
+ Skin_PlaySound(DefaultNudge.NudgeSoundname);
}
}
@@ -210,7 +210,7 @@ void LoadProtocols(void) //Load the default nudge
mir_snprintf(DefaultNudge.ProtocolName, "Default");
mir_snprintf(DefaultNudge.NudgeSoundname, "Nudge : Default");
- SkinAddNewSoundEx(DefaultNudge.NudgeSoundname, LPGEN("Nudge"), LPGEN("Default Nudge"));
+ Skin_AddSound(DefaultNudge.NudgeSoundname, LPGENW("Nudge"), LPGENW("Default Nudge"));
DefaultNudge.Load();
GlobalNudge.Load();
@@ -411,7 +411,7 @@ int Preview() for (int i = 0; i < arNudges.getCount(); i++) {
CNudgeElement &p = arNudges[i];
if (p.enabled) {
- SkinPlaySound(p.NudgeSoundname);
+ Skin_PlaySound(p.NudgeSoundname);
if (p.showPopup)
Nudge_ShowPopup(&p, hContact, p.recText);
if (p.openContactList)
@@ -427,7 +427,7 @@ int Preview() }
else {
if (DefaultNudge.enabled) {
- SkinPlaySound(DefaultNudge.NudgeSoundname);
+ Skin_PlaySound(DefaultNudge.NudgeSoundname);
if (DefaultNudge.showPopup)
Nudge_ShowPopup(&DefaultNudge, hContact, DefaultNudge.recText);
if (DefaultNudge.openContactList)
@@ -525,7 +525,7 @@ void Nudge_AddAccount(PROTOACCOUNT *proto) wchar_t soundDesc[MAXMODULELABELLENGTH + 10];
mir_snwprintf(soundDesc, LPGENW("Nudge for %s"), proto->tszAccountName);
- SkinAddNewSoundExW(p->NudgeSoundname, LPGENW("Nudge"), soundDesc);
+ Skin_AddSound(p->NudgeSoundname, LPGENW("Nudge"), soundDesc);
arNudges.insert(p);
}
diff --git a/plugins/Ping/src/ping.cpp b/plugins/Ping/src/ping.cpp index 7688afb496..7dd24e6a26 100644 --- a/plugins/Ping/src/ping.cpp +++ b/plugins/Ping/src/ping.cpp @@ -138,8 +138,8 @@ extern "C" __declspec(dllexport) int Load(void) LoadOptions();
- SkinAddNewSoundEx("PingTimeout", LPGEN("Ping"), LPGEN("Timeout"));
- SkinAddNewSoundEx("PingReply", LPGEN("Ping"), LPGEN("Reply"));
+ Skin_AddSound("PingTimeout", LPGENW("Ping"), LPGENW("Timeout"));
+ Skin_AddSound("PingReply", LPGENW("Ping"), LPGENW("Reply"));
HookEvent(ME_SYSTEM_MODULESLOADED, OnModulesLoaded);
diff --git a/plugins/Ping/src/pingthread.cpp b/plugins/Ping/src/pingthread.cpp index c3d215329d..06c5b8963e 100644 --- a/plugins/Ping/src/pingthread.cpp +++ b/plugins/Ping/src/pingthread.cpp @@ -218,8 +218,8 @@ void __cdecl sttCheckStatusThreadProc(void*) }
}
- if (timeout) SkinPlaySound("PingTimeout");
- if (reply) SkinPlaySound("PingReply");
+ if (timeout) Skin_PlaySound("PingTimeout");
+ if (reply) Skin_PlaySound("PingReply");
if (!get_list_changed()) {
upCount = count;
diff --git a/plugins/PluginUpdater/src/DlgUpdate.cpp b/plugins/PluginUpdater/src/DlgUpdate.cpp index 6d54f2e342..8aada80df1 100644 --- a/plugins/PluginUpdater/src/DlgUpdate.cpp +++ b/plugins/PluginUpdater/src/DlgUpdate.cpp @@ -87,7 +87,7 @@ static void ApplyUpdates(void *param) // interrupt update as we require all components to be updated
Netlib_CloseHandle(nlc);
PostMessage(hDlg, UM_ERROR, 0, 0);
- SkinPlaySound("updatefailed");
+ Skin_PlaySound("updatefailed");
return;
}
SetStringText(hwndList, i, TranslateT("Succeeded."));
@@ -121,7 +121,7 @@ static void ApplyUpdates(void *param) }
}
}
- SkinPlaySound("updatecompleted");
+ Skin_PlaySound("updatecompleted");
#if MIRANDA_VER < 0x0A00
// 4) Change title of clist
@@ -429,7 +429,7 @@ static void DlgUpdateSilent(void *param) if (!DownloadFile(pFileUrl, nlc)) {
// interrupt update as we require all components to be updated
Netlib_CloseHandle(nlc);
- SkinPlaySound("updatefailed");
+ Skin_PlaySound("updatefailed");
delete &UpdateFiles;
return;
}
@@ -473,7 +473,7 @@ static void DlgUpdateSilent(void *param) }
}
delete &UpdateFiles;
- SkinPlaySound("updatecompleted");
+ Skin_PlaySound("updatecompleted");
#if MIRANDA_VER < 0x0A00
// 4) Change title of clist
diff --git a/plugins/PluginUpdater/src/PluginUpdater.cpp b/plugins/PluginUpdater/src/PluginUpdater.cpp index 9c09f5a6f9..49507acd15 100644 --- a/plugins/PluginUpdater/src/PluginUpdater.cpp +++ b/plugins/PluginUpdater/src/PluginUpdater.cpp @@ -126,8 +126,8 @@ extern "C" __declspec(dllexport) int Load(void) InitEvents();
// add sounds
- SkinAddNewSoundEx("updatecompleted", LPGEN("Plugin Updater"), LPGEN("Update completed"));
- SkinAddNewSoundEx("updatefailed", LPGEN("Plugin Updater"), LPGEN("Update failed"));
+ Skin_AddSound("updatecompleted", LPGENW("Plugin Updater"), LPGENW("Update completed"));
+ Skin_AddSound("updatefailed", LPGENW("Plugin Updater"), LPGENW("Update failed"));
#if MIRANDA_VER >= 0x0A00
// Upgrade old settings
diff --git a/plugins/PluginUpdater/src/Utils.cpp b/plugins/PluginUpdater/src/Utils.cpp index c136c5c20c..7554c723ef 100644 --- a/plugins/PluginUpdater/src/Utils.cpp +++ b/plugins/PluginUpdater/src/Utils.cpp @@ -163,14 +163,14 @@ bool ParseHashes(const wchar_t *ptszUrl, ptrW &baseUrl, SERVLIST &arHashes) if (!ret) {
Netlib_LogfW(hNetlibUser,L"Downloading list of available updates from %s failed",baseUrl);
ShowPopup(TranslateT("Plugin Updater"), TranslateT("An error occurred while checking for new updates."), POPUP_TYPE_ERROR);
- SkinPlaySound("updatefailed");
+ Skin_PlaySound("updatefailed");
return false;
}
if(!unzip(pFileUrl.tszDiskPath, g_tszTempPath, NULL,true)) {
Netlib_LogfW(hNetlibUser,L"Unzipping list of available updates from %s failed",baseUrl);
ShowPopup(TranslateT("Plugin Updater"), TranslateT("An error occurred while checking for new updates."), POPUP_TYPE_ERROR);
- SkinPlaySound("updatefailed");
+ Skin_PlaySound("updatefailed");
return false;
}
diff --git a/plugins/SMS/src/SMSConstans.h b/plugins/SMS/src/SMSConstans.h index b212510210..9a48672f9f 100644 --- a/plugins/SMS/src/SMSConstans.h +++ b/plugins/SMS/src/SMSConstans.h @@ -2,6 +2,7 @@ #define AFX_SMS_CONSTANS_H__F58D13FF_F6F2_476C_B8F0_7B9E9357CF48__INCLUDED_
#define PROTOCOL_NAMEA "SMSPlugin"
+#define PROTOCOL_NAMEW L"SMSPlugin"
#define PROTOCOL_NAME_LEN (sizeof(PROTOCOL_NAMEA)-1)
#define PROTOCOL_NAME_SIZE sizeof(PROTOCOL_NAMEA)
#define PROTOCOL_DISPLAY_NAME_ORIG "SMS"
diff --git a/plugins/SMS/src/SMS_svc.cpp b/plugins/SMS/src/SMS_svc.cpp index a88d44f33e..b224343cd0 100644 --- a/plugins/SMS/src/SMS_svc.cpp +++ b/plugins/SMS/src/SMS_svc.cpp @@ -45,8 +45,8 @@ int LoadModules(void) mi.flags = CMIF_UNICODE;
ssSMSSettings.hContactMenuItems[0] = Menu_AddContactMenuItem(&mi);
- SkinAddNewSoundEx("RecvSMSMsg", PROTOCOL_NAMEA, LPGEN("Incoming SMS Message"));
- SkinAddNewSoundEx("RecvSMSConfirmation", PROTOCOL_NAMEA, LPGEN("Incoming SMS Confirmation"));
+ Skin_AddSound("RecvSMSMsg", PROTOCOL_NAMEW, LPGENW("Incoming SMS Message"));
+ Skin_AddSound("RecvSMSConfirmation", PROTOCOL_NAMEW, LPGENW("Incoming SMS Confirmation"));
RefreshAccountList(NULL, NULL);
diff --git a/plugins/SMS/src/receive.cpp b/plugins/SMS/src/receive.cpp index 28ad76e8c0..c576e2cdd3 100644 --- a/plugins/SMS/src/receive.cpp +++ b/plugins/SMS/src/receive.cpp @@ -75,7 +75,7 @@ int handleAckSMS(WPARAM wParam, LPARAM lParam) if (hContact == NULL) {
if (RecvSMSWindowAdd(NULL, ICQEVENTTYPE_SMS, tszPhone, dwPhoneSize, (LPSTR)dbei.pBlob, dbei.cbBlob)) {
db_event_markRead(hContact, hResult);
- SkinPlaySound("RecvSMSMsg");
+ Skin_PlaySound("RecvSMSMsg");
}
}
}
@@ -224,7 +224,7 @@ int handleNewMessage(WPARAM hContact, LPARAM hDbEvent) if ((dbei.flags & DBEF_SENT) == 0)
if (dbei.eventType == ICQEVENTTYPE_SMS) {
if (dbei.cbBlob > MIN_SMS_DBEVENT_LEN) {
- SkinPlaySound("RecvSMSMsg");
+ Skin_PlaySound("RecvSMSMsg");
if (DB_SMS_GetByte(NULL, "AutoPopup", 0)) {
if (RecvSMSWindowAdd(hContact, ICQEVENTTYPE_SMS, NULL, 0, (LPSTR)dbei.pBlob, dbei.cbBlob))
db_event_markRead(hContact, hDbEvent);
@@ -245,7 +245,7 @@ int handleNewMessage(WPARAM hContact, LPARAM hDbEvent) }
}
else if (dbei.eventType == ICQEVENTTYPE_SMSCONFIRMATION) {
- SkinPlaySound("RecvSMSConfirmation");
+ Skin_PlaySound("RecvSMSConfirmation");
if (DB_SMS_GetByte(NULL, "AutoPopup", 0)) {
if (RecvSMSWindowAdd(hContact, ICQEVENTTYPE_SMSCONFIRMATION, NULL, 0, (LPSTR)dbei.pBlob, dbei.cbBlob))
db_event_delete(hContact, hDbEvent);
diff --git a/plugins/Scriver/src/globals.cpp b/plugins/Scriver/src/globals.cpp index 7a174bf528..97ac6a7adf 100644 --- a/plugins/Scriver/src/globals.cpp +++ b/plugins/Scriver/src/globals.cpp @@ -161,7 +161,7 @@ static int ackevent(WPARAM, LPARAM lParam) }
else if (hwndSender != nullptr) {
SendMessage(hwndSender, DM_STOPMESSAGESENDING, 0, 0);
- SkinPlaySound("SendMsg");
+ Skin_PlaySound("SendMsg");
}
return 0;
diff --git a/plugins/Scriver/src/msgdialog.cpp b/plugins/Scriver/src/msgdialog.cpp index c642e0e422..cd49dd8bdd 100644 --- a/plugins/Scriver/src/msgdialog.cpp +++ b/plugins/Scriver/src/msgdialog.cpp @@ -1435,8 +1435,8 @@ INT_PTR CSrmmWindow::DlgProc(UINT msg, WPARAM wParam, LPARAM lParam) m_lastMessage = dbei.timestamp;
UpdateStatusBar();
if (GetForegroundWindow() == m_hwndParent && m_pParent->hwndActive == m_hwnd)
- SkinPlaySound("RecvMsgActive");
- else SkinPlaySound("RecvMsgInactive");
+ Skin_PlaySound("RecvMsgActive");
+ else Skin_PlaySound("RecvMsgInactive");
if ((g_dat.flags2 & SMF2_SWITCHTOACTIVE) && (IsIconic(m_hwndParent) || GetActiveWindow() != m_hwndParent) && IsWindowVisible(m_hwndParent))
SendMessage(m_hwndParent, CM_ACTIVATECHILD, 0, (LPARAM)m_hwnd);
if (IsAutoPopup(m_hContact))
diff --git a/plugins/Scriver/src/msgs.cpp b/plugins/Scriver/src/msgs.cpp index d7a2e05b74..26ee901ae6 100644 --- a/plugins/Scriver/src/msgs.cpp +++ b/plugins/Scriver/src/msgs.cpp @@ -106,7 +106,7 @@ static int MessageEventAdded(WPARAM hContact, LPARAM lParam) /* does a window for the contact exist? */
if (hwnd == nullptr) {
/* new message */
- SkinPlaySound("AlertMsg");
+ Skin_PlaySound("AlertMsg");
if (IsAutoPopup(hContact)) {
(new CSrmmWindow(hContact, true))->Show();
return 0;
@@ -188,7 +188,7 @@ static int TypingMessage(WPARAM hContact, LPARAM lParam) hContact = db_mc_tryMeta(hContact);
- SkinPlaySound((lParam) ? "TNStart" : "TNStop");
+ Skin_PlaySound((lParam) ? "TNStart" : "TNStop");
HWND hwnd = Srmm_FindWindow(hContact);
if (hwnd)
@@ -647,12 +647,12 @@ int OnLoadModule(void) CreateServiceFunction(MS_MSG_SENDMESSAGEW, SendMessageCommandW);
CreateServiceFunction(MS_MSG_TYPINGMESSAGE, TypingMessageCommand);
- SkinAddNewSoundEx("RecvMsgActive", LPGEN("Instant messages"), LPGEN("Incoming (focused window)"));
- SkinAddNewSoundEx("RecvMsgInactive", LPGEN("Instant messages"), LPGEN("Incoming (unfocused window)"));
- SkinAddNewSoundEx("AlertMsg", LPGEN("Instant messages"), LPGEN("Incoming (new session)"));
- SkinAddNewSoundEx("SendMsg", LPGEN("Instant messages"), LPGEN("Outgoing"));
- SkinAddNewSoundEx("TNStart", LPGEN("Instant messages"), LPGEN("Contact started typing"));
- SkinAddNewSoundEx("TNStop", LPGEN("Instant messages"), LPGEN("Contact stopped typing"));
+ Skin_AddSound("RecvMsgActive", LPGENW("Instant messages"), LPGENW("Incoming (focused window)"));
+ Skin_AddSound("RecvMsgInactive", LPGENW("Instant messages"), LPGENW("Incoming (unfocused window)"));
+ Skin_AddSound("AlertMsg", LPGENW("Instant messages"), LPGENW("Incoming (new session)"));
+ Skin_AddSound("SendMsg", LPGENW("Instant messages"), LPGENW("Outgoing"));
+ Skin_AddSound("TNStart", LPGENW("Instant messages"), LPGENW("Contact started typing"));
+ Skin_AddSound("TNStop", LPGENW("Instant messages"), LPGENW("Contact stopped typing"));
hDragCursor = LoadCursor(g_hInst, MAKEINTRESOURCE(IDC_DRAGCURSOR));
diff --git a/plugins/SecureIM/src/crypt_popups.cpp b/plugins/SecureIM/src/crypt_popups.cpp index 3bd02356dc..fbced3dd22 100644 --- a/plugins/SecureIM/src/crypt_popups.cpp +++ b/plugins/SecureIM/src/crypt_popups.cpp @@ -92,12 +92,12 @@ void showPopupSM(MCONTACT hContact) {
if (db_get_b(0, MODULENAME, "ss", 0))
showPopup(sim009, hContact, g_hPOP[POP_PU_MSS], 2);
- SkinPlaySound("OutgoingSecureMessage");
+ Skin_PlaySound("OutgoingSecureMessage");
}
void showPopupRM(MCONTACT hContact)
{
if (db_get_b(0, MODULENAME, "sr", 0))
showPopup(sim010, hContact, g_hPOP[POP_PU_MSR], 2);
- SkinPlaySound("IncomingSecureMessage");
+ Skin_PlaySound("IncomingSecureMessage");
}
diff --git a/plugins/SecureIM/src/main.cpp b/plugins/SecureIM/src/main.cpp index 3e80b7db39..22a5ef4749 100644 --- a/plugins/SecureIM/src/main.cpp +++ b/plugins/SecureIM/src/main.cpp @@ -211,8 +211,8 @@ static int onModulesLoaded(WPARAM, LPARAM) loadContactList();
// add new skin sound
- SkinAddNewSoundEx("IncomingSecureMessage", LPGEN("SecureIM"), LPGEN("Incoming Secure Message"), "Sounds\\iSecureMessage.wav");
- SkinAddNewSoundEx("OutgoingSecureMessage", LPGEN("SecureIM"), LPGEN("Outgoing Secure Message"), "Sounds\\oSecureMessage.wav");
+ Skin_AddSound("IncomingSecureMessage", LPGENW("SecureIM"), LPGENW("Incoming Secure Message"), L"Sounds\\iSecureMessage.wav");
+ Skin_AddSound("OutgoingSecureMessage", LPGENW("SecureIM"), LPGENW("Outgoing Secure Message"), L"Sounds\\oSecureMessage.wav");
// init extra icons
for (int i = 0; i < _countof(g_IEC); i++)
diff --git a/plugins/SeenPlugin/src/history.cpp b/plugins/SeenPlugin/src/history.cpp index b409a71ccb..28a959d7d4 100644 --- a/plugins/SeenPlugin/src/history.cpp +++ b/plugins/SeenPlugin/src/history.cpp @@ -297,7 +297,7 @@ void ShowHistory(MCONTACT hContact, BYTE isAlert) }
if (isAlert)
- SkinPlaySound("LastSeenTrackedStatusChange");
+ Skin_PlaySound("LastSeenTrackedStatusChange");
}
void InitHistoryDialog(void)
diff --git a/plugins/SeenPlugin/src/main.cpp b/plugins/SeenPlugin/src/main.cpp index 2261c98a46..ac6672a246 100644 --- a/plugins/SeenPlugin/src/main.cpp +++ b/plugins/SeenPlugin/src/main.cpp @@ -104,10 +104,10 @@ extern "C" __declspec(dllexport) int Load(void) LoadWatchedProtos();
- SkinAddNewSoundExW("LastSeenTrackedStatusChange", LPGENW("LastSeen"), LPGENW("User status change"));
- SkinAddNewSoundExW("LastSeenTrackedStatusOnline", LPGENW("LastSeen"), LPGENW("Changed to Online"));
- SkinAddNewSoundExW("LastSeenTrackedStatusOffline", LPGENW("LastSeen"), LPGENW("User Logged Off"));
- SkinAddNewSoundExW("LastSeenTrackedStatusFromOffline", LPGENW("LastSeen"), LPGENW("User Logged In"));
+ Skin_AddSound("LastSeenTrackedStatusChange", LPGENW("LastSeen"), LPGENW("User status change"));
+ Skin_AddSound("LastSeenTrackedStatusOnline", LPGENW("LastSeen"), LPGENW("Changed to Online"));
+ Skin_AddSound("LastSeenTrackedStatusOffline", LPGENW("LastSeen"), LPGENW("User Logged Off"));
+ Skin_AddSound("LastSeenTrackedStatusFromOffline", LPGENW("LastSeen"), LPGENW("User Logged In"));
return 0;
}
diff --git a/plugins/SeenPlugin/src/utils.cpp b/plugins/SeenPlugin/src/utils.cpp index cff0c704de..e9e043d824 100644 --- a/plugins/SeenPlugin/src/utils.cpp +++ b/plugins/SeenPlugin/src/utils.cpp @@ -510,7 +510,7 @@ void myPlaySound(MCONTACT hcontact, WORD newStatus, WORD oldStatus) else if (oldStatus == ID_STATUS_OFFLINE) soundname = "LastSeenTrackedStatusFromOffline";
else soundname = "LastSeenTrackedStatusChange";
if (soundname != NULL)
- SkinPlaySound(soundname);
+ Skin_PlaySound(soundname);
}
// will add hContact to queue and will return position;
diff --git a/plugins/SendScreenshotPlus/src/CSend.cpp b/plugins/SendScreenshotPlus/src/CSend.cpp index 194e8ac4a0..6ec66563aa 100644 --- a/plugins/SendScreenshotPlus/src/CSend.cpp +++ b/plugins/SendScreenshotPlus/src/CSend.cpp @@ -418,17 +418,17 @@ void CSend::Exit(unsigned int Result) bool err = true; switch (Result) { case CSEND_DIALOG: - SkinPlaySound("FileDone"); + Skin_PlaySound("FileDone"); DialogBoxParam(g_hSendSS, MAKEINTRESOURCE(IDD_UResultForm), 0, ResultDialogProc, (LPARAM)this); err = false; break; case ACKRESULT_SUCCESS: case GC_RESULT_SUCCESS: - SkinPlaySound("FileDone"); + Skin_PlaySound("FileDone"); err = false; break; case ACKRESULT_DENIED: - SkinPlaySound("FileDenied"); + Skin_PlaySound("FileDenied"); Error(L"%s (%i):\nFile transfer denied.", TranslateW(m_pszSendTyp), Result); MsgBoxService(NULL, (LPARAM)&m_box); err = false; @@ -447,7 +447,7 @@ void CSend::Exit(unsigned int Result) break; } if (err) { - SkinPlaySound("FileFailed"); + Skin_PlaySound("FileFailed"); if (m_ErrorMsg) MsgBoxService(NULL, (LPARAM)&m_box); else MsgErr(NULL, LPGENW("An unknown error has occurred.")); } diff --git a/plugins/TabSRMM/src/chat_tools.cpp b/plugins/TabSRMM/src/chat_tools.cpp index b27e605d2a..864745498f 100644 --- a/plugins/TabSRMM/src/chat_tools.cpp +++ b/plugins/TabSRMM/src/chat_tools.cpp @@ -214,11 +214,11 @@ void DoFlashAndSoundWorker(FLASH_PARAMS *p) p->bInactive = dat->m_pContainer->m_hwnd != GetForegroundWindow();
p->bActiveTab = (dat->m_pContainer->m_hwndActive == si->pDlg->GetHwnd());
if (p->sound && dat->MustPlaySound())
- SkinPlaySound(p->sound);
+ Skin_PlaySound(p->sound);
}
}
else if (p->sound)
- SkinPlaySound(p->sound);
+ Skin_PlaySound(p->sound);
if (dat) {
HWND hwndTab = GetParent(si->pDlg->GetHwnd());
diff --git a/plugins/TabSRMM/src/chat_window.cpp b/plugins/TabSRMM/src/chat_window.cpp index 7b2fd8f54a..cb105d1aee 100644 --- a/plugins/TabSRMM/src/chat_window.cpp +++ b/plugins/TabSRMM/src/chat_window.cpp @@ -665,7 +665,7 @@ void CChatRoomDlg::onClick_OK(CCtrlButton*) UpdateStatusBar(); if (m_pContainer) if (fSound && !nen_options.iNoSounds && !(m_pContainer->dwFlags & CNT_NOSOUND)) - SkinPlaySound("ChatSent"); + Skin_PlaySound("ChatSent"); SetFocus(m_message.GetHwnd()); } @@ -1193,7 +1193,7 @@ LRESULT CChatRoomDlg::WndProc_Message(UINT msg, WPARAM wParam, LPARAM lParam) KbdState(isShift, isCtrl, isAlt); if (PluginConfig.m_bSoundOnTyping && !isAlt && !isCtrl && !(m_pContainer->dwFlags & CNT_NOSOUND) && wParam != VK_ESCAPE && !(wParam == VK_TAB && PluginConfig.m_bAllowTab)) - SkinPlaySound("SoundOnTyping"); + Skin_PlaySound("SoundOnTyping"); if (isCtrl && !isAlt && !isShift) switch (wParam) { @@ -1209,7 +1209,7 @@ LRESULT CChatRoomDlg::WndProc_Message(UINT msg, WPARAM wParam, LPARAM lParam) // sound on typing.. if (PluginConfig.m_bSoundOnTyping && !isAlt && wParam == VK_DELETE) - SkinPlaySound("SoundOnTyping"); + Skin_PlaySound("SoundOnTyping"); if (wParam != VK_ESCAPE) if (ProcessHotkeys(wParam, isShift, isCtrl, isAlt)) diff --git a/plugins/TabSRMM/src/globals.cpp b/plugins/TabSRMM/src/globals.cpp index 5b4539fb8f..298bee3138 100644 --- a/plugins/TabSRMM/src/globals.cpp +++ b/plugins/TabSRMM/src/globals.cpp @@ -69,11 +69,11 @@ void CGlobals::reloadSystemStartup() PluginConfig.g_hMenuContext = LoadMenu(g_hInst, MAKEINTRESOURCE(IDR_TABCONTEXT));
TranslateMenu(g_hMenuContext);
- SkinAddNewSoundEx("RecvMsgActive", LPGEN("Instant messages"), LPGEN("Incoming (focused window)"));
- SkinAddNewSoundEx("RecvMsgInactive", LPGEN("Instant messages"), LPGEN("Incoming (unfocused window)"));
- SkinAddNewSoundEx("AlertMsg", LPGEN("Instant messages"), LPGEN("Incoming (new session)"));
- SkinAddNewSoundEx("SendMsg", LPGEN("Instant messages"), LPGEN("Outgoing"));
- SkinAddNewSoundEx("SendError", LPGEN("Instant messages"), LPGEN("Message send error"));
+ Skin_AddSound("RecvMsgActive", LPGENW("Instant messages"), LPGENW("Incoming (focused window)"));
+ Skin_AddSound("RecvMsgInactive", LPGENW("Instant messages"), LPGENW("Incoming (unfocused window)"));
+ Skin_AddSound("AlertMsg", LPGENW("Instant messages"), LPGENW("Incoming (new session)"));
+ Skin_AddSound("SendMsg", LPGENW("Instant messages"), LPGENW("Outgoing"));
+ Skin_AddSound("SendError", LPGENW("Instant messages"), LPGENW("Message send error"));
hCurSplitNS = LoadCursor(nullptr, IDC_SIZENS);
hCurSplitWE = LoadCursor(nullptr, IDC_SIZEWE);
@@ -212,7 +212,7 @@ void CGlobals::reloadAdv() m_bDontUseDefaultKbd = M.GetBool("adv_leaveKeyboardAlone", true);
if (m_bSoundOnTyping && m_TypingSoundAdded == false) {
- SkinAddNewSoundEx("SoundOnTyping", LPGEN("Other"), LPGEN("TabSRMM: typing"));
+ Skin_AddSound("SoundOnTyping", LPGENW("Other"), LPGENW("TabSRMM: typing"));
m_TypingSoundAdded = true;
}
m_bAllowOfflineMultisend = M.GetBool("AllowOfflineMultisend", true);
diff --git a/plugins/TabSRMM/src/mim.cpp b/plugins/TabSRMM/src/mim.cpp index a275fa74be..d1af47ec4b 100644 --- a/plugins/TabSRMM/src/mim.cpp +++ b/plugins/TabSRMM/src/mim.cpp @@ -238,7 +238,7 @@ int CMimAPI::TypingMessage(WPARAM hContact, LPARAM mode) else fShowOnClist = false; if ((!foundWin || !(pContainer->dwFlags & CNT_NOSOUND)) && preTyping != (mode != 0)) - SkinPlaySound(mode ? "TNStart" : "TNStop"); + Skin_PlaySound(mode ? "TNStart" : "TNStop"); if (M.GetByte(SRMSGMOD, "ShowTypingPopup", 0)) { BOOL fShow = false; @@ -447,7 +447,7 @@ int CMimAPI::MessageEventAdded(WPARAM hContact, LPARAM hDbEvent) // if no window is open, we are not interested in anything else but unread message events // new message if (!nen_options.iNoSounds) - SkinPlaySound("AlertMsg"); + Skin_PlaySound("AlertMsg"); if (nen_options.iNoAutoPopup) goto nowindowcreate; diff --git a/plugins/TabSRMM/src/msgdialog.cpp b/plugins/TabSRMM/src/msgdialog.cpp index 2eba71af45..147555a9c3 100644 --- a/plugins/TabSRMM/src/msgdialog.cpp +++ b/plugins/TabSRMM/src/msgdialog.cpp @@ -1991,7 +1991,7 @@ LRESULT CSrmmWindow::WndProc_Message(UINT msg, WPARAM wParam, LPARAM lParam) KbdState(isShift, isCtrl, isAlt);
if (PluginConfig.m_bSoundOnTyping && !isAlt && !isCtrl && !(m_pContainer->dwFlags & CNT_NOSOUND) && wParam != VK_ESCAPE && !(wParam == VK_TAB && PluginConfig.m_bAllowTab))
- SkinPlaySound("SoundOnTyping");
+ Skin_PlaySound("SoundOnTyping");
if (isCtrl && !isAlt) {
switch (wParam) {
@@ -2044,7 +2044,7 @@ LRESULT CSrmmWindow::WndProc_Message(UINT msg, WPARAM wParam, LPARAM lParam) KbdState(isShift, isCtrl, isAlt);
if (PluginConfig.m_bSoundOnTyping && !isAlt && !(m_pContainer->dwFlags & CNT_NOSOUND) && wParam == VK_DELETE)
- SkinPlaySound("SoundOnTyping");
+ Skin_PlaySound("SoundOnTyping");
if (wParam == VK_INSERT && !isShift && !isCtrl && !isAlt) {
m_bInsertMode = !m_bInsertMode;
@@ -2679,7 +2679,7 @@ INT_PTR CSrmmWindow::DlgProc(UINT uMsg, WPARAM wParam, LPARAM lParam) mir_snwprintf(job->szErrorMsg, TranslateT("Delivery failure: %s"), TranslateT("The message send timed out"));
job->iStatus = SendQueue::SQ_ERROR;
if (!nen_options.iNoSounds && !(m_pContainer->dwFlags & CNT_NOSOUND))
- SkinPlaySound("SendError");
+ Skin_PlaySound("SendError");
if (!(m_dwFlags & MWF_ERRORSTATE))
sendQueue->handleError(this, iIndex);
break;
diff --git a/plugins/TabSRMM/src/msgdlgutils.cpp b/plugins/TabSRMM/src/msgdlgutils.cpp index 24487881b8..09f477af63 100644 --- a/plugins/TabSRMM/src/msgdlgutils.cpp +++ b/plugins/TabSRMM/src/msgdlgutils.cpp @@ -1162,9 +1162,9 @@ void CTabBaseDlg::PlayIncomingSound() const int iPlay = MustPlaySound();
if (iPlay) {
if (GetForegroundWindow() == m_pContainer->m_hwnd && m_pContainer->m_hwndActive == m_hwnd)
- SkinPlaySound("RecvMsgActive");
+ Skin_PlaySound("RecvMsgActive");
else
- SkinPlaySound("RecvMsgInactive");
+ Skin_PlaySound("RecvMsgInactive");
}
}
diff --git a/plugins/TabSRMM/src/sendqueue.cpp b/plugins/TabSRMM/src/sendqueue.cpp index b78867654f..cae1d654e7 100644 --- a/plugins/TabSRMM/src/sendqueue.cpp +++ b/plugins/TabSRMM/src/sendqueue.cpp @@ -442,7 +442,7 @@ int SendQueue::ackMessage(CTabBaseDlg *dat, WPARAM wParam, LPARAM lParam) // "hard" errors are handled differently in multisend. There is no option to retry - once failed, they // are discarded and the user is notified with a small log message. if (!nen_options.iNoSounds && !(m_pContainer->dwFlags & CNT_NOSOUND)) - SkinPlaySound("SendError"); + Skin_PlaySound("SendError"); mir_snwprintf(job.szErrorMsg, TranslateT("Delivery failure: %s"), _A2T((char *)ack->lParam)); job.iStatus = SQ_ERROR; @@ -485,7 +485,7 @@ int SendQueue::ackMessage(CTabBaseDlg *dat, WPARAM wParam, LPARAM lParam) if (m_pContainer) if (!nen_options.iNoSounds && !(m_pContainer->dwFlags & CNT_NOSOUND)) - SkinPlaySound("SendMsg"); + Skin_PlaySound("SendMsg"); Srmm_Broadcast(DM_APPENDMCEVENT, job.hContact, hNewEvent); diff --git a/plugins/TabSRMM/src/typingnotify.cpp b/plugins/TabSRMM/src/typingnotify.cpp index 0e133464a3..42a3238131 100644 --- a/plugins/TabSRMM/src/typingnotify.cpp +++ b/plugins/TabSRMM/src/typingnotify.cpp @@ -548,8 +548,8 @@ int TN_ModuleInit() hDisableMenu = Menu_AddMainMenuItem(&mi);
}
- SkinAddNewSoundEx("TNStart", LPGEN("Instant messages"), LPGEN("Contact started typing"));
- SkinAddNewSoundEx("TNStop", LPGEN("Instant messages"), LPGEN("Contact stopped typing"));
+ Skin_AddSound("TNStart", LPGENW("Instant messages"), LPGENW("Contact started typing"));
+ Skin_AddSound("TNStop", LPGENW("Instant messages"), LPGENW("Contact stopped typing"));
return 0;
}
diff --git a/plugins/TooltipNotify/src/TooltipNotify.cpp b/plugins/TooltipNotify/src/TooltipNotify.cpp index fc3e2ccd9d..9b17cb37e6 100644 --- a/plugins/TooltipNotify/src/TooltipNotify.cpp +++ b/plugins/TooltipNotify/src/TooltipNotify.cpp @@ -133,14 +133,13 @@ int CTooltipNotify::ModulesLoaded(WPARAM, LPARAM) db_set_b(NULL, MODULENAME, "firstrun", 0);
}
- SkinAddNewSoundEx(SND_ONLINE, LPGEN("Tooltip Notify"), LPGEN("Online"), "online.wav");
- SkinAddNewSoundEx(SND_OFFLINE, LPGEN("Tooltip Notify"), LPGEN("Offline"), "offline.wav");
- SkinAddNewSoundEx(SND_OTHER, LPGEN("Tooltip Notify"), LPGEN("Other"), "other.wav");
- SkinAddNewSoundEx(SND_TYPING, LPGEN("Tooltip Notify"), LPGEN("Typing"), "typing.wav");
+ Skin_AddSound(SND_ONLINE, LPGENW("Tooltip Notify"), LPGENW("Online"), L"online.wav");
+ Skin_AddSound(SND_OFFLINE, LPGENW("Tooltip Notify"), LPGENW("Offline"), L"offline.wav");
+ Skin_AddSound(SND_OTHER, LPGENW("Tooltip Notify"), LPGENW("Other"), L"other.wav");
+ Skin_AddSound(SND_TYPING, LPGENW("Tooltip Notify"), LPGENW("Typing"), L"typing.wav");
// register fonts
RegisterFonts();
-
return 0;
}
@@ -156,7 +155,7 @@ int CTooltipNotify::ProtoContactIsTyping(WPARAM hContact, LPARAM lParam) pTooltipData->iStatus = ID_TTNTF_STATUS_TYPING;
EndNotifyAll();
- SkinPlaySound(SND_TYPING);
+ Skin_PlaySound(SND_TYPING);
BeginNotify(pTooltipData);
}
else EndNotifyAll();
@@ -225,18 +224,18 @@ int CTooltipNotify::ContactSettingChanged(WPARAM hContact, LPARAM lParam) switch (wNewStatus) {
case ID_STATUS_OFFLINE:
if (!m_sOptions.bOffline) return 0;
- SkinPlaySound(SND_OFFLINE);
+ Skin_PlaySound(SND_OFFLINE);
break;
case ID_STATUS_ONLINE:
if (CallService(MS_IGNORE_ISIGNORED, hContact, IGNOREEVENT_USERONLINE) && m_sOptions.bConjSOLN) return 0;
if (!m_sOptions.bOnline) return 0;
- SkinPlaySound(SND_ONLINE);
+ Skin_PlaySound(SND_ONLINE);
break;
default:
if (!m_sOptions.bOther) return 0;
- SkinPlaySound(SND_OTHER);
+ Skin_PlaySound(SND_OTHER);
break;
}
diff --git a/plugins/UserInfoEx/src/svc_reminder.cpp b/plugins/UserInfoEx/src/svc_reminder.cpp index ffaa8b8a0b..151b3a7bfb 100644 --- a/plugins/UserInfoEx/src/svc_reminder.cpp +++ b/plugins/UserInfoEx/src/svc_reminder.cpp @@ -352,11 +352,11 @@ static BYTE NotifyWithSound(const CEvent &evt) if (evt._wDaysLeft <= min(db_get_b(NULL, MODNAME, SET_REMIND_SOUNDOFFSET, DEFVAL_REMIND_SOUNDOFFSET), gRemindOpts.wDaysEarlier)) {
switch (evt._eType) {
case CEvent::BIRTHDAY:
- SkinPlaySound(evt._wDaysLeft == 0 ? SOUND_BIRTHDAY_TODAY : SOUND_BIRTHDAY_SOON);
+ Skin_PlaySound(evt._wDaysLeft == 0 ? SOUND_BIRTHDAY_TODAY : SOUND_BIRTHDAY_SOON);
return 0;
case CEvent::ANNIVERSARY:
- SkinPlaySound(SOUND_ANNIVERSARY);
+ Skin_PlaySound(SOUND_ANNIVERSARY);
return 0;
}
}
@@ -893,24 +893,9 @@ void SvcReminderOnModulesLoaded(void) void SvcReminderLoadModule(void)
{
// init sounds
- SKINSOUNDDESCEX ssd = { 0 };
- ssd.cbSize = sizeof(ssd);
- ssd.pszSection = MODNAME;
-
- ssd.pszName = SOUND_BIRTHDAY_TODAY;
- ssd.pszDescription = LPGEN("Birthday reminder");
- ssd.pszDefaultFile = "Sounds\\BirthDay.wav";
- Skin_AddSound(&ssd);
-
- ssd.pszName = SOUND_BIRTHDAY_SOON;
- ssd.pszDescription = LPGEN("Birthday reminder: it's coming");
- ssd.pszDefaultFile = "Sounds\\BirthDayComing.wav";
- Skin_AddSound(&ssd);
-
- ssd.pszName = SOUND_ANNIVERSARY;
- ssd.pszDescription = LPGEN("Anniversary Reminder");
- ssd.pszDefaultFile = "Sounds\\Reminder.wav";
- Skin_AddSound(&ssd);
+ Skin_AddSound(SOUND_BIRTHDAY_TODAY, LPGENW("Birthday reminder"), L"Sounds\\BirthDay.wav");
+ Skin_AddSound(SOUND_BIRTHDAY_SOON, LPGENW("Birthday reminder: it's coming"), L"Sounds\\BirthDayComing.wav");
+ Skin_AddSound(SOUND_ANNIVERSARY, LPGENW("Anniversary Reminder"), L"Sounds\\Reminder.wav");
// create service functions
CreateServiceFunction(MS_USERINFO_REMINDER_CHECK, CheckService);
@@ -926,7 +911,6 @@ void SvcReminderLoadModule(void) if (db_get_b(NULL, MODNAME, SET_REMIND_ENABLED, DEFVAL_REMIND_ENABLED) != REMIND_OFF && ExtraIcon == INVALID_HANDLE_VALUE)
ExtraIcon = ExtraIcon_RegisterIcolib("Reminder", LPGEN("Reminder (UInfoEx)"), ICO_COMMON_ANNIVERSARY);
-
}
/**
diff --git a/plugins/Weather/src/weather.cpp b/plugins/Weather/src/weather.cpp index 827b5514eb..94327bc8e4 100644 --- a/plugins/Weather/src/weather.cpp +++ b/plugins/Weather/src/weather.cpp @@ -226,8 +226,8 @@ extern "C" int __declspec(dllexport) Load(void) InitServices();
// add sound event
- SkinAddNewSoundExW("weatherupdated", _A2W(WEATHERPROTONAME), LPGENW("Weather Condition Changed"));
- SkinAddNewSoundExW("weatheralert", _A2W(WEATHERPROTONAME), LPGENW("Weather Alert Issued"));
+ Skin_AddSound("weatherupdated", _A2W(WEATHERPROTONAME), LPGENW("Weather Condition Changed"));
+ Skin_AddSound("weatheralert", _A2W(WEATHERPROTONAME), LPGENW("Weather Alert Issued"));
// window needed for popup commands
wchar_t SvcFunc[100];
diff --git a/plugins/Weather/src/weather_update.cpp b/plugins/Weather/src/weather_update.cpp index 3054f13e3c..02d5129fab 100644 --- a/plugins/Weather/src/weather_update.cpp +++ b/plugins/Weather/src/weather_update.cpp @@ -110,7 +110,7 @@ int UpdateWeather(MCONTACT hContact) // alert issued, set display to italic
if (opt.MakeItalic)
db_set_w(hContact, WEATHERPROTONAME, "ApparentMode", ID_STATUS_OFFLINE);
- SkinPlaySound("weatheralert");
+ Skin_PlaySound("weatheralert");
}
// alert dropped, set the display back to normal
else db_unset(hContact, WEATHERPROTONAME, "ApparentMode");
@@ -162,7 +162,7 @@ int UpdateWeather(MCONTACT hContact) // logging
if (Ch) {
// play the sound event
- SkinPlaySound("weatherupdated");
+ Skin_PlaySound("weatherupdated");
if (db_get_b(hContact, WEATHERPROTONAME, "File", 0)) {
// external log
diff --git a/plugins/WebView/src/main.cpp b/plugins/WebView/src/main.cpp index 2709aa050f..fd897fb380 100644 --- a/plugins/WebView/src/main.cpp +++ b/plugins/WebView/src/main.cpp @@ -164,7 +164,7 @@ extern "C" int __declspec(dllexport) Load() InitServices();
//add sound event to options
- SkinAddNewSoundExW("webviewalert", _A2W(MODULENAME), LPGENW("Alert event"));
+ Skin_AddSound("webviewalert", _A2W(MODULENAME), LPGENW("Alert event"));
//value is 1 if menu is disabled
db_set_b(NULL, MODULENAME, MENU_IS_DISABLED_KEY, 1);
diff --git a/plugins/WebView/src/webview_alerts.cpp b/plugins/WebView/src/webview_alerts.cpp index 2e744c3df8..bdd4551410 100644 --- a/plugins/WebView/src/webview_alerts.cpp +++ b/plugins/WebView/src/webview_alerts.cpp @@ -345,7 +345,7 @@ int ProcessAlerts(MCONTACT hContact, char *truncated, char *tstr, char *contactn wasAlert = 1;
// play sound?
- SkinPlaySound("webviewalert");
+ Skin_PlaySound("webviewalert");
//
if ((!notpresent)) {
if (alertIndex == 0) { // popup
@@ -443,7 +443,7 @@ int ProcessAlerts(MCONTACT hContact, char *truncated, char *tstr, char *contactn if (strncmp(tempraw, cachecompare, mir_strlen(tempraw)) != 0) { //lets try this instead
// play sound?
- SkinPlaySound("webviewalert");
+ Skin_PlaySound("webviewalert");
// there was an alert
wasAlert = 1;
@@ -654,7 +654,7 @@ int ProcessAlerts(MCONTACT hContact, char *truncated, char *tstr, char *contactn // end write to cache
if (strncmp(raw, cachecompare, (mir_strlen(raw))) != 0) { //lets try this instead
// play sound?
- SkinPlaySound("webviewalert");
+ Skin_PlaySound("webviewalert");
// there was an alert
wasAlert = 1;
diff --git a/plugins/WhenWasIt/src/WhenWasIt.cpp b/plugins/WhenWasIt/src/WhenWasIt.cpp index f6fd93f05f..ee26949b6d 100644 --- a/plugins/WhenWasIt/src/WhenWasIt.cpp +++ b/plugins/WhenWasIt/src/WhenWasIt.cpp @@ -131,8 +131,8 @@ extern "C" int __declspec(dllexport) Load(void) hotkey.pszService = MS_WWI_CHECK_BIRTHDAYS;
Hotkey_Register(&hotkey);
- SkinAddNewSoundExW(BIRTHDAY_NEAR_SOUND, LPGENW("WhenWasIt"), LPGENW("Birthday near"));
- SkinAddNewSoundExW(BIRTHDAY_TODAY_SOUND, LPGENW("WhenWasIt"), LPGENW("Birthday today"));
+ Skin_AddSound(BIRTHDAY_NEAR_SOUND, LPGENW("WhenWasIt"), LPGENW("Birthday near"));
+ Skin_AddSound(BIRTHDAY_TODAY_SOUND, LPGENW("WhenWasIt"), LPGENW("Birthday today"));
Log("%s", "Leaving function " __FUNCTION__);
return 0;
diff --git a/plugins/WhenWasIt/src/notifiers.cpp b/plugins/WhenWasIt/src/notifiers.cpp index 739fbbb789..96bf7fe280 100644 --- a/plugins/WhenWasIt/src/notifiers.cpp +++ b/plugins/WhenWasIt/src/notifiers.cpp @@ -194,9 +194,9 @@ int DialogNotifyMissedBirthday(MCONTACT hContact, int dab, int age) int SoundNotifyBirthday(int dtb)
{
if (dtb == 0)
- SkinPlaySound(BIRTHDAY_TODAY_SOUND);
+ Skin_PlaySound(BIRTHDAY_TODAY_SOUND);
else if (dtb <= commonData.cSoundNearDays)
- SkinPlaySound(BIRTHDAY_NEAR_SOUND);
+ Skin_PlaySound(BIRTHDAY_NEAR_SOUND);
return 0;
}
diff --git a/plugins/XSoundNotify/src/dialog.cpp b/plugins/XSoundNotify/src/dialog.cpp index bbc972fac2..7c8a3e794c 100644 --- a/plugins/XSoundNotify/src/dialog.cpp +++ b/plugins/XSoundNotify/src/dialog.cpp @@ -137,14 +137,14 @@ static INT_PTR CALLBACK DlgProcContactsOptions(HWND hwndDlg, UINT msg, WPARAM wP if (!db_get_ws(hContact, SETTINGSNAME, SETTINGSKEY, &dbv)) {
wchar_t longpath[MAX_PATH] = { 0 };
PathToAbsoluteW(dbv.ptszVal, longpath);
- SkinPlaySoundFile(longpath);
+ Skin_PlaySoundFile(longpath);
db_free(&dbv);
}
}
else {
wchar_t longpath[MAX_PATH] = { 0 };
PathToAbsoluteW(p->path, longpath);
- SkinPlaySoundFile(longpath);
+ Skin_PlaySoundFile(longpath);
}
break;
diff --git a/plugins/XSoundNotify/src/options.cpp b/plugins/XSoundNotify/src/options.cpp index f7735d774b..fd5bc06ca8 100644 --- a/plugins/XSoundNotify/src/options.cpp +++ b/plugins/XSoundNotify/src/options.cpp @@ -205,14 +205,14 @@ static INT_PTR CALLBACK OptsProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l if (!db_get_ws(NULL, SETTINGSNAME, pa->szModuleName, &dbv)) {
wchar_t longpath[MAX_PATH];
PathToAbsoluteW(dbv.ptszVal, longpath);
- SkinPlaySoundFile(longpath);
+ Skin_PlaySoundFile(longpath);
db_free(&dbv);
}
}
else {
wchar_t longpath[MAX_PATH] = { 0 };
PathToAbsoluteW(p->path, longpath);
- SkinPlaySoundFile(longpath);
+ Skin_PlaySoundFile(longpath);
}
}
else {
@@ -224,14 +224,14 @@ static INT_PTR CALLBACK OptsProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l if (!db_get_ws(hContact, SETTINGSNAME, SETTINGSKEY, &dbv)) {
wchar_t longpath[MAX_PATH];
PathToAbsoluteW(dbv.ptszVal, longpath);
- SkinPlaySoundFile(longpath);
+ Skin_PlaySoundFile(longpath);
db_free(&dbv);
}
}
else {
wchar_t longpath[MAX_PATH] = { 0 };
PathToAbsoluteW(p->path, longpath);
- SkinPlaySoundFile(longpath);
+ Skin_PlaySoundFile(longpath);
}
}
}
diff --git a/plugins/XSoundNotify/src/xsn_main.cpp b/plugins/XSoundNotify/src/xsn_main.cpp index b97d930f8d..417dd08dbd 100644 --- a/plugins/XSoundNotify/src/xsn_main.cpp +++ b/plugins/XSoundNotify/src/xsn_main.cpp @@ -78,7 +78,7 @@ void InitSelfSounds() wchar_t infobuf[256];
mir_snwprintf(infobuf, L"%s [%s]", TranslateT("Self status"), protos[i]->tszAccountName);
- SkinAddNewSoundExW(namebuf, infobuf, pcli->pfnGetStatusModeDescription(selfSounds[j].iStatus, 0));
+ Skin_AddSound(namebuf, infobuf, pcli->pfnGetStatusModeDescription(selfSounds[j].iStatus, 0));
}
}
}
@@ -91,7 +91,7 @@ static int ProtoAck(WPARAM, LPARAM lParam) if (selfSounds[i].iStatus == ack->lParam) {
char buf[128];
mir_snprintf(buf, "%s%s", ack->szModule, selfSounds[i].szName);
- SkinPlaySound(buf);
+ Skin_PlaySound(buf);
break;
}
}
@@ -121,7 +121,7 @@ static int ProcessEvent(WPARAM hContact, LPARAM lParam) wchar_t PlaySoundPath[MAX_PATH] = { 0 };
PathToAbsoluteW(dbv.ptszVal, PlaySoundPath);
isOwnSound = 0;
- SkinPlaySoundFile(PlaySoundPath);
+ Skin_PlaySoundFile(PlaySoundPath);
db_free(&dbv);
isOwnSound = 1;
return 0;
@@ -138,7 +138,7 @@ static int ProcessEvent(WPARAM hContact, LPARAM lParam) wchar_t PlaySoundPath[MAX_PATH] = { 0 };
PathToAbsoluteW(dbv.ptszVal, PlaySoundPath);
isAccSound = 0;
- SkinPlaySoundFile(PlaySoundPath);
+ Skin_PlaySoundFile(PlaySoundPath);
db_free(&dbv);
isAccSound = 1;
}
@@ -168,7 +168,7 @@ static int ProcessChatEvent(WPARAM, LPARAM lParam) wchar_t PlaySoundPath[MAX_PATH] = { 0 };
PathToAbsoluteW(dbv.ptszVal, PlaySoundPath);
isOwnSound = 0;
- SkinPlaySoundFile(PlaySoundPath);
+ Skin_PlaySoundFile(PlaySoundPath);
db_free(&dbv);
isOwnSound = 1;
return 0;
@@ -184,7 +184,7 @@ static int ProcessChatEvent(WPARAM, LPARAM lParam) wchar_t PlaySoundPath[MAX_PATH] = { 0 };
PathToAbsoluteW(dbv.ptszVal, PlaySoundPath);
isAccSound = 0;
- SkinPlaySoundFile(PlaySoundPath);
+ Skin_PlaySoundFile(PlaySoundPath);
db_free(&dbv);
isAccSound = 1;
}
diff --git a/plugins/YAMN/src/browser/badconnect.cpp b/plugins/YAMN/src/browser/badconnect.cpp index 31cbb57829..90f5815d4e 100644 --- a/plugins/YAMN/src/browser/badconnect.cpp +++ b/plugins/YAMN/src/browser/badconnect.cpp @@ -245,7 +245,7 @@ void __cdecl BadConnection(void *Param) DebugLog(SynchroFile,"BadConnect:ActualAccountSO-read enter\n");
#endif
if (ActualAccount->BadConnectN.Flags & YAMN_ACC_SND)
- CallService(MS_SKIN_PLAYSOUND, 0, (LPARAM)YAMN_CONNECTFAILSOUND);
+ Skin_PlaySound(YAMN_CONNECTFAILSOUND);
if (ActualAccount->BadConnectN.Flags & YAMN_ACC_MSG)
ShowWindow(hBadConnect, SW_SHOWNORMAL);
diff --git a/plugins/YAMN/src/browser/mailbrowser.cpp b/plugins/YAMN/src/browser/mailbrowser.cpp index 64b7508f92..9342ecc1aa 100644 --- a/plugins/YAMN/src/browser/mailbrowser.cpp +++ b/plugins/YAMN/src/browser/mailbrowser.cpp @@ -741,7 +741,7 @@ void DoMailActions(HWND hDlg, HACCOUNT ActualAccount, struct CMailNumbers *MN, D if (MN->Real.SoundNC + MN->Virtual.SoundNC != 0) if (nflags & YAMN_ACC_SND) - SkinPlaySound(YAMN_NEWMAILSOUND); + Skin_PlaySound(YAMN_NEWMAILSOUND); if ((nnflags & YAMN_ACC_POP) && (MN->Real.PopupRun + MN->Virtual.PopupRun == 0)) { POPUPDATAT NoNewMailPopup; diff --git a/plugins/YAMN/src/main.cpp b/plugins/YAMN/src/main.cpp index d13f61a6ba..9264edaf70 100644 --- a/plugins/YAMN/src/main.cpp +++ b/plugins/YAMN/src/main.cpp @@ -324,8 +324,8 @@ extern "C" int __declspec(dllexport) Load(void) CreateServiceFunctions(); - SkinAddNewSoundEx(YAMN_NEWMAILSOUND, YAMN_DBMODULE, YAMN_NEWMAILSNDDESC); - SkinAddNewSoundEx(YAMN_CONNECTFAILSOUND, YAMN_DBMODULE, YAMN_CONNECTFAILSNDDESC); + Skin_AddSound(YAMN_NEWMAILSOUND, L"YAMN", YAMN_NEWMAILSNDDESC); + Skin_AddSound(YAMN_CONNECTFAILSOUND, L"YAMN", YAMN_CONNECTFAILSNDDESC); HookEvents(); diff --git a/plugins/YAMN/src/main.h b/plugins/YAMN/src/main.h index eacb470e69..fd09d77b13 100644 --- a/plugins/YAMN/src/main.h +++ b/plugins/YAMN/src/main.h @@ -1,8 +1,8 @@ #ifndef __MAIN_H
#define __MAIN_H
-#define YAMN_NEWMAILSNDDESC LPGEN("YAMN: new mail message")
-#define YAMN_CONNECTFAILSNDDESC LPGEN("YAMN: connect failed")
+#define YAMN_NEWMAILSNDDESC LPGENW("YAMN: new mail message")
+#define YAMN_CONNECTFAILSNDDESC LPGENW("YAMN: connect failed")
#define YAMN_CONNECTFAILSOUND "YAMN/Sound/ConnectFail"
#define YAMN_NEWMAILSOUND "YAMN/Sound/NewMail"
|