diff options
author | George Hazan <george.hazan@gmail.com> | 2013-06-17 21:24:53 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2013-06-17 21:24:53 +0000 |
commit | 5ab0462a05c80e52a629255353405d7e5c39e304 (patch) | |
tree | 84a90be689d517efa8b0c9723724856ce66b4fec /plugins | |
parent | dab6220221dd014aa8490a8f56561b383507304e (diff) |
PS_GETCUSTOMSTATUSICON used instead of raw text
git-svn-id: http://svn.miranda-ng.org/main/trunk@5005 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/Clist_modern/src/modern_clistmod.cpp | 2 | ||||
-rw-r--r-- | plugins/Clist_modern/src/modern_statusbar.cpp | 4 | ||||
-rw-r--r-- | plugins/Scriver/src/commonheaders.h | 1 | ||||
-rw-r--r-- | plugins/Scriver/src/infobar.cpp | 6 | ||||
-rw-r--r-- | plugins/TabSRMM/src/commonheaders.h | 2 | ||||
-rw-r--r-- | plugins/TabSRMM/src/msgdlgutils.cpp | 12 |
6 files changed, 15 insertions, 12 deletions
diff --git a/plugins/Clist_modern/src/modern_clistmod.cpp b/plugins/Clist_modern/src/modern_clistmod.cpp index 6fd2978021..db2b694093 100644 --- a/plugins/Clist_modern/src/modern_clistmod.cpp +++ b/plugins/Clist_modern/src/modern_clistmod.cpp @@ -64,7 +64,7 @@ HICON cliGetIconFromStatusMode(HANDLE hContact, const char *szProto,int status) // check service exists
char str[MAXMODULELABELLENGTH];
strcpy(str,szProto);
- strcat(str,"/GetXStatusIcon");
+ strcat(str,PS_GETCUSTOMSTATUSICON);
if ( ServiceExists(str)) {
// check status is online
if (status > ID_STATUS_OFFLINE) {
diff --git a/plugins/Clist_modern/src/modern_statusbar.cpp b/plugins/Clist_modern/src/modern_statusbar.cpp index 0c8e13521e..a8eef4b790 100644 --- a/plugins/Clist_modern/src/modern_statusbar.cpp +++ b/plugins/Clist_modern/src/modern_statusbar.cpp @@ -382,7 +382,7 @@ int ModernDrawStatusBarWorker(HWND hWnd, HDC hDC) if ((p.xStatusMode & 3)) {
if (p.ProtoStatus > ID_STATUS_OFFLINE) {
char str[MAXMODULELABELLENGTH];
- mir_snprintf(str, SIZEOF(str), "%s/GetXStatusIcon", p.AccountName);
+ mir_snprintf(str, SIZEOF(str), "%s%s", p.AccountName, PS_GETCUSTOMSTATUSICON);
if ( ServiceExists(str))
p.extraIcon = (HICON)CallService(str, 0, 0);
if (p.extraIcon && (p.xStatusMode & 3) == 3)
@@ -468,7 +468,7 @@ int ModernDrawStatusBarWorker(HWND hWnd, HDC hDC) if (p.showProtoIcon) {
if (p.ProtoStatus > ID_STATUS_OFFLINE && (p.xStatusMode & 3) > 0) {
char str[MAXMODULELABELLENGTH];
- mir_snprintf(str, SIZEOF(str), "%s/GetXStatusIcon", p.AccountName);
+ mir_snprintf(str, SIZEOF(str), "%s%s", p.AccountName, PS_GETCUSTOMSTATUSICON);
if ( ServiceExists(str)) {
hxIcon = p.extraIcon;
if (hxIcon) {
diff --git a/plugins/Scriver/src/commonheaders.h b/plugins/Scriver/src/commonheaders.h index a7c0ca5af5..246ccb6d3f 100644 --- a/plugins/Scriver/src/commonheaders.h +++ b/plugins/Scriver/src/commonheaders.h @@ -64,6 +64,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include <m_hotkeys.h>
#include <m_popup.h>
#include <m_timezones.h>
+#include <m_xstatus.h>
#include <win2k.h>
#include <m_ieview.h>
diff --git a/plugins/Scriver/src/infobar.cpp b/plugins/Scriver/src/infobar.cpp index 897c414e77..79c83e2e94 100644 --- a/plugins/Scriver/src/infobar.cpp +++ b/plugins/Scriver/src/infobar.cpp @@ -61,9 +61,9 @@ void SetupInfobar(InfobarWindowData* idat) { static HICON GetExtraStatusIcon(InfobarWindowData* idat)
{
BYTE bXStatus = db_get_b(idat->mwd->windowData.hContact, idat->mwd->szProto, "XStatusId", 0);
- if (bXStatus > 0) {
- return (HICON) CallProtoService(idat->mwd->szProto, "/GetXStatusIcon", bXStatus, 0);
- }
+ if (bXStatus > 0)
+ return (HICON) CallProtoService(idat->mwd->szProto, PS_GETCUSTOMSTATUSICON, bXStatus, 0);
+
return NULL;
}
diff --git a/plugins/TabSRMM/src/commonheaders.h b/plugins/TabSRMM/src/commonheaders.h index 36ba7e241e..46b1d5b50f 100644 --- a/plugins/TabSRMM/src/commonheaders.h +++ b/plugins/TabSRMM/src/commonheaders.h @@ -30,7 +30,6 @@ *
*/
-
#ifndef __COMMONHEADERS_H
#define __COMMONHEADERS_H
@@ -86,6 +85,7 @@ #include <m_popup.h>
#include <m_timezones.h>
#include <m_modernopt.h>
+#include <m_xstatus.h>
#include <m_ieview.h>
#include <m_popup2.h>
diff --git a/plugins/TabSRMM/src/msgdlgutils.cpp b/plugins/TabSRMM/src/msgdlgutils.cpp index 2f25a63a10..9f5385688b 100644 --- a/plugins/TabSRMM/src/msgdlgutils.cpp +++ b/plugins/TabSRMM/src/msgdlgutils.cpp @@ -2141,14 +2141,16 @@ void TSAPI ConfigureSmileyButton(TWindowData *dat) HICON TSAPI GetXStatusIcon(const TWindowData *dat)
{
- char szServiceName[128];
BYTE xStatus = dat->cache->getXStatusId();
+ if (xStatus == 0)
+ return NULL;
- mir_snprintf(szServiceName, 128, "%s/GetXStatusIcon", dat->cache->getActiveProto());
+ char szServiceName[128];
+ mir_snprintf(szServiceName, 128, "%s%s", dat->cache->getActiveProto(), PS_GETCUSTOMSTATUSICON);
+ if ( !ServiceExists(szServiceName))
+ return NULL;
- if ( ServiceExists(szServiceName))
- return (HICON)(CallProtoService(dat->cache->getActiveProto(), "/GetXStatusIcon", xStatus, 0));
- return 0;
+ return (HICON)(CallProtoService(dat->cache->getActiveProto(), PS_GETCUSTOMSTATUSICON, xStatus, 0));
}
LRESULT TSAPI GetSendButtonState(HWND hwnd)
|