diff options
-rw-r--r-- | plugins/CommonLibs/CString.cpp | 8 | ||||
-rw-r--r-- | protocols/IcqOscarJ/icq_menu.cpp | 24 | ||||
-rw-r--r-- | protocols/IcqOscarJ/icq_xtraz.h | 36 | ||||
-rw-r--r-- | protocols/IcqOscarJ/icqoscar.h | 1 | ||||
-rw-r--r-- | src/modules/clist/clistmenus.cpp | 2 |
5 files changed, 15 insertions, 56 deletions
diff --git a/plugins/CommonLibs/CString.cpp b/plugins/CommonLibs/CString.cpp index c78d9e25b0..fb8760dc74 100644 --- a/plugins/CommonLibs/CString.cpp +++ b/plugins/CommonLibs/CString.cpp @@ -82,7 +82,7 @@ void TString<T>::SetAllocSize(int nNewAllocSize) if (pBuf)
{
memcpy(pNewBuf, pBuf, sizeof(T) * min(nBufSize, nNewAllocSize));
- //HeapFree(GetProcessHeap(), 0, pBuf);
+ //HeapFree(GetProcessHeap(), 0, pBuf);
free(pBuf);
}
pBuf = pNewBuf;
@@ -177,7 +177,7 @@ TString<T>& TString<T>::Replace(int nIndex, int nCount, const T *szReplaceBy) {
return *this;
}
-
+
TString<T> Result;
Result.GetBuffer(1)[0] = '\0';
Result.ReleaseBuffer(0); // set the string to ""; we can't do it in a usual way (using a constructor or an assignment) because we don't know whether "" needs to be unicode or ansi
@@ -339,11 +339,7 @@ TCString DBGetContactSettingString(HANDLE hContact, const char *szModule, const int DBGetContactSettingString(HANDLE hContact, const char *szModule, const char *szSetting, DBVARIANT *dbv)
{
-#ifdef _DEBUG
- return db_get_s(hContact, szModule, szSetting, dbv, DBVT_ASCIIZ);
-#else
return db_get_s(hContact, szModule, szSetting, dbv, DBVT_ASCIIZ);
-#endif
}
diff --git a/protocols/IcqOscarJ/icq_menu.cpp b/protocols/IcqOscarJ/icq_menu.cpp index 8c67310963..f3dd072cde 100644 --- a/protocols/IcqOscarJ/icq_menu.cpp +++ b/protocols/IcqOscarJ/icq_menu.cpp @@ -1,22 +1,22 @@ // ---------------------------------------------------------------------------80
// ICQ plugin for Miranda Instant Messenger
// ________________________________________
-//
+//
// Copyright © 2000-2001 Richard Hughes, Roland Rabien, Tristan Van de Vreede
// Copyright © 2001-2002 Jon Keating, Richard Hughes
// Copyright © 2002-2004 Martin Öberg, Sam Kothari, Robert Rainwater
// Copyright © 2004-2008 Joe Kucera, Bio
-//
+//
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation; either version 2
// of the License, or (at your option) any later version.
-//
+//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
-//
+//
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -125,7 +125,7 @@ void g_MenuInit(void) char str[MAXMODULELABELLENGTH], *pszDest = str + 3;
strcpy( str, "ICQ" );
-
+
CLISTMENUITEM mi = { 0 };
mi.cbSize = sizeof(CLISTMENUITEM);
mi.pszService = str;
@@ -222,20 +222,20 @@ int CIcqProto::OnPreBuildContactMenu(WPARAM wParam, LPARAM) DWORD dwUin = getContactUin(hContact);
- sttEnableMenuItem(g_hContactMenuItems[ICMI_AUTH_REQUEST],
+ sttEnableMenuItem(g_hContactMenuItems[ICMI_AUTH_REQUEST],
dwUin && (bCtrlPressed || (getSettingByte((HANDLE)wParam, "Auth", 0) && getSettingWord((HANDLE)wParam, DBSETTING_SERVLIST_ID, 0))));
sttEnableMenuItem(g_hContactMenuItems[ICMI_AUTH_GRANT], dwUin && (bCtrlPressed || getSettingByte((HANDLE)wParam, "Grant", 0)));
- sttEnableMenuItem(g_hContactMenuItems[ICMI_AUTH_REVOKE],
+ sttEnableMenuItem(g_hContactMenuItems[ICMI_AUTH_REVOKE],
dwUin && (bCtrlPressed || (getSettingByte(NULL, "PrivacyItems", 0) && !getSettingByte((HANDLE)wParam, "Grant", 0))));
- sttEnableMenuItem(g_hContactMenuItems[ICMI_ADD_TO_SERVLIST],
- m_bSsiEnabled && !getSettingWord((HANDLE)wParam, DBSETTING_SERVLIST_ID, 0) &&
+ sttEnableMenuItem(g_hContactMenuItems[ICMI_ADD_TO_SERVLIST],
+ m_bSsiEnabled && !getSettingWord((HANDLE)wParam, DBSETTING_SERVLIST_ID, 0) &&
!getSettingWord((HANDLE)wParam, DBSETTING_SERVLIST_IGNORE, 0) &&
!DBGetContactSettingByte(hContact, "CList", "NotOnList", 0));
}
-
+
sttEnableMenuItem(g_hContactMenuItems[ICMI_OPEN_PROFILE],getContactUin(hContact) != 0);
BYTE bXStatus = getContactXStatus((HANDLE)wParam);
-
+
sttEnableMenuItem(g_hContactMenuItems[ICMI_XSTATUS_DETAILS], m_bHideXStatusUI ? 0 : bXStatus != 0);
if (bXStatus && !m_bHideXStatusUI) {
CLISTMENUITEM clmi = {0};
@@ -254,7 +254,7 @@ int CIcqProto::OnPreBuildContactMenu(WPARAM wParam, LPARAM) }
/////////////////////////////////////////////////////////////////////////////////////////
-// OnPrebuildContactMenu event
+// OnPreBuildStatusMenu event
int CIcqProto::OnPreBuildStatusMenu(WPARAM wParam, LPARAM lParam)
{
diff --git a/protocols/IcqOscarJ/icq_xtraz.h b/protocols/IcqOscarJ/icq_xtraz.h deleted file mode 100644 index 28578e71a5..0000000000 --- a/protocols/IcqOscarJ/icq_xtraz.h +++ /dev/null @@ -1,36 +0,0 @@ -// ---------------------------------------------------------------------------80
-// ICQ plugin for Miranda Instant Messenger
-// ________________________________________
-//
-// Copyright © 2000-2001 Richard Hughes, Roland Rabien, Tristan Van de Vreede
-// Copyright © 2001-2002 Jon Keating, Richard Hughes
-// Copyright © 2002-2004 Martin Öberg, Sam Kothari, Robert Rainwater
-// Copyright © 2004-2008 Joe Kucera
-//
-// This program is free software; you can redistribute it and/or
-// modify it under the terms of the GNU General Public License
-// as published by the Free Software Foundation; either version 2
-// of the License, or (at your option) any later version.
-//
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with this program; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-//
-// -----------------------------------------------------------------------------
-// DESCRIPTION:
-//
-// Describe me here please...
-//
-// -----------------------------------------------------------------------------
-#ifndef __ICQ_XTRAZ_H
-#define __ICQ_XTRAZ_H
-
-// custom status support
-void InitXStatusItems(BOOL bAllowStatus);
-
-#endif /* __ICQ_XTRAZ_H */
diff --git a/protocols/IcqOscarJ/icqoscar.h b/protocols/IcqOscarJ/icqoscar.h index 1efd1ffebb..b565eda497 100644 --- a/protocols/IcqOscarJ/icqoscar.h +++ b/protocols/IcqOscarJ/icqoscar.h @@ -102,7 +102,6 @@ #include "icq_direct.h"
#include "icq_server.h"
#include "icqosc_svcs.h"
-#include "icq_xtraz.h"
#include "icq_opts.h"
#include "icq_servlist.h"
#include "icq_http.h"
diff --git a/src/modules/clist/clistmenus.cpp b/src/modules/clist/clistmenus.cpp index 8abc2bd2da..53f7728d9c 100644 --- a/src/modules/clist/clistmenus.cpp +++ b/src/modules/clist/clistmenus.cpp @@ -1193,7 +1193,7 @@ static INT_PTR AddStatusMenuItem(WPARAM wParam, LPARAM lParam) mir_free(ptszName);
}
if (pRoot == NULL) {
- memset(&tmi, 0, sizeof(tmi));
+ TMO_MenuItem tmi = { 0 };
tmi.cbSize = sizeof(tmi);
tmi.flags = (mi->flags & CMIF_UNICODE) | CMIF_ROOTHANDLE;
tmi.position = 1001;
|