From 5f8a607f900a42e27bf166b86185001aadf3e9f2 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 27 Feb 2014 13:50:53 +0000 Subject: more fun: - MS_AWAYMSG_GETSTATUSMSGW/T is present in any MIID_SRAWAY plugin, so there's no need to check its existence; - therefore MS_AWAYMSG_GETSTATUSMSG considered useless, cause it has no references git-svn-id: http://svn.miranda-ng.org/main/trunk@8293 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/BossKeyPlus/src/BossKey.cpp | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) (limited to 'plugins/BossKeyPlus/src/BossKey.cpp') diff --git a/plugins/BossKeyPlus/src/BossKey.cpp b/plugins/BossKeyPlus/src/BossKey.cpp index 15c0b1b480..188e1ec57f 100644 --- a/plugins/BossKeyPlus/src/BossKey.cpp +++ b/plugins/BossKeyPlus/src/BossKey.cpp @@ -201,16 +201,7 @@ BOOL CALLBACK EnumWindowsProc(HWND hWnd,LPARAM) TCHAR* GetDefStatusMsg(unsigned uStatus, const char* szProto) { - INT_PTR res = CallService (MS_AWAYMSG_GETSTATUSMSGT, (WPARAM)uStatus, (LPARAM)szProto ); - if (res == CALLSERVICE_NOTFOUND ) - { - char* tmp = ( char* )CallService(MS_AWAYMSG_GETSTATUSMSG, (WPARAM)uStatus, (LPARAM)szProto ); - TCHAR *ret = mir_a2t( tmp ); - mir_free( tmp ); - return ret; - } - else - return (TCHAR *) res; + return (TCHAR*)CallService (MS_AWAYMSG_GETSTATUSMSGT, uStatus, (LPARAM)szProto); } void SetStatus(const char* szProto, unsigned status, TCHAR *tszAwayMsg) @@ -220,7 +211,7 @@ void SetStatus(const char* szProto, unsigned status, TCHAR *tszAwayMsg) if ( CallProtoService( szProto, PS_SETAWAYMSGT, status, (LPARAM) tszAwayMsg ) == CALLSERVICE_NOTFOUND ) { char *szAwayMsg = mir_t2a(tszAwayMsg); - CallProtoService( szProto, PS_SETAWAYMSG, status, (LPARAM) szAwayMsg ); + CallProtoService( szProto, PS_SETAWAYMSG, status, (LPARAM)szAwayMsg ); mir_free(szAwayMsg); } } -- cgit v1.2.3