diff options
Diffstat (limited to 'plugins/TabSRMM/src')
74 files changed, 451 insertions, 726 deletions
diff --git a/plugins/TabSRMM/src/ImageDataObject.cpp b/plugins/TabSRMM/src/ImageDataObject.cpp index 65e8e8d4dd..9d6b6f2ddf 100644 --- a/plugins/TabSRMM/src/ImageDataObject.cpp +++ b/plugins/TabSRMM/src/ImageDataObject.cpp @@ -24,9 +24,6 @@ *
* part of tabSRMM messaging plugin for Miranda.
*
- * *
- * $Id: ImageDataObject.cpp 11611 2010-04-22 12:36:29Z silvercircle $
- *
* This inserts a bitmap into a rich edit control using OLE
* code partially taken from public example on the internet, source unknown.
*
@@ -35,7 +32,6 @@ */
#include "commonheaders.h"
-#include "include\ImageDataObject.h"
extern void ReleaseRichEditOle(IRichEditOle *ole)
{
diff --git a/plugins/TabSRMM/src/include/ImageDataObject.h b/plugins/TabSRMM/src/ImageDataObject.h index 0e2c112827..2c83b1c27d 100644 --- a/plugins/TabSRMM/src/include/ImageDataObject.h +++ b/plugins/TabSRMM/src/ImageDataObject.h @@ -19,11 +19,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. //code taken partly from public example on the internet, source unknown.
-//make sure <richedit.h> is include before this file
-#include <richedit.h>
-#include <richole.h>
-#include <ole2.h>
-
class CImageDataObject : IDataObject
{
public:
diff --git a/plugins/TabSRMM/src/TSButton.cpp b/plugins/TabSRMM/src/TSButton.cpp index 0488a3e45e..e32ab00173 100644 --- a/plugins/TabSRMM/src/TSButton.cpp +++ b/plugins/TabSRMM/src/TSButton.cpp @@ -33,7 +33,6 @@ */
#include "commonheaders.h"
-#include <ctype.h>
#define PBS_PUSHDOWNPRESSED 6
diff --git a/plugins/TabSRMM/src/include/buttonbar.h b/plugins/TabSRMM/src/buttonbar.h index 9be67e965b..9be67e965b 100644 --- a/plugins/TabSRMM/src/include/buttonbar.h +++ b/plugins/TabSRMM/src/buttonbar.h diff --git a/plugins/TabSRMM/src/buttonsbar.cpp b/plugins/TabSRMM/src/buttonsbar.cpp index 4a86c79137..2d05a0a9e1 100644 --- a/plugins/TabSRMM/src/buttonsbar.cpp +++ b/plugins/TabSRMM/src/buttonsbar.cpp @@ -1,5 +1,4 @@ #include "commonheaders.h"
-#pragma hdrstop
static HANDLE hButtonsBarAddButton;
static HANDLE hButtonsBarRemoveButton;
@@ -933,127 +932,127 @@ void CB_InitDefaultButtons() bbd.cbSize = sizeof(BBButton);
bbd.bbbFlags = BBBF_ISIMBUTTON | BBBF_ISLSIDEBUTTON | BBBF_ISARROWBUTTON | BBBF_CREATEBYID;
bbd.dwButtonID = IDC_PROTOCOL;
- bbd.dwDefPos = 10; - bbd.hIcon = LoadSkinnedIconHandle(SKINICON_OTHER_CONNECTING); - bbd.pszModuleName = "Tabsrmm"; - bbd.ptszTooltip = LPGENT("Protocol Button"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwDefPos = 10;
+ bbd.hIcon = LoadSkinnedIconHandle(SKINICON_OTHER_CONNECTING);
+ bbd.pszModuleName = "Tabsrmm";
+ bbd.ptszTooltip = LPGENT("Protocol Button");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
bbd.bbbFlags = BBBF_ISIMBUTTON | BBBF_ISLSIDEBUTTON | BBBF_ISARROWBUTTON | BBBF_CREATEBYID;
- bbd.dwButtonID = IDC_NAME; - bbd.dwDefPos = 20; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[20]; - bbd.ptszTooltip = LPGENT("Info button"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwButtonID = IDC_NAME;
+ bbd.dwDefPos = 20;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[20];
+ bbd.ptszTooltip = LPGENT("Info button");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
if (PluginConfig.g_SmileyAddAvail) {
bbd.bbbFlags = BBBF_ISIMBUTTON | BBBF_ISCHATBUTTON | BBBF_ISLSIDEBUTTON | BBBF_CREATEBYID;
bbd.dwButtonID = IDC_SMILEYBTN;
- bbd.iButtonWidth = 0; - bbd.dwDefPos = 30; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[9]; - bbd.ptszTooltip = LPGENT("Insert Emoticon"); - CB_AddButton(0, (LPARAM)&bbd); - } - + bbd.iButtonWidth = 0;
+ bbd.dwDefPos = 30;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[9];
+ bbd.ptszTooltip = LPGENT("Insert Emoticon");
+ CB_AddButton(0, (LPARAM)&bbd);
+ }
+
bbd.bbbFlags = BBBF_ISIMBUTTON | BBBF_ISCHATBUTTON | BBBF_ISLSIDEBUTTON | BBBF_ISPUSHBUTTON | BBBF_CANBEHIDDEN | BBBF_CREATEBYID;
- bbd.dwButtonID = IDC_FONTBOLD; - bbd.dwDefPos = 40; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[10]; - bbd.ptszTooltip = LPGENT("Bold text"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwButtonID = IDC_FONTBOLD;
+ bbd.dwDefPos = 40;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[10];
+ bbd.ptszTooltip = LPGENT("Bold text");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
bbd.bbbFlags = BBBF_ISIMBUTTON | BBBF_ISCHATBUTTON | BBBF_ISLSIDEBUTTON | BBBF_ISPUSHBUTTON | BBBF_CANBEHIDDEN | BBBF_CREATEBYID;
- bbd.dwButtonID = IDC_FONTITALIC; - bbd.dwDefPos = 50; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[11]; - bbd.ptszTooltip = LPGENT("Italic text"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwButtonID = IDC_FONTITALIC;
+ bbd.dwDefPos = 50;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[11];
+ bbd.ptszTooltip = LPGENT("Italic text");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
bbd.bbbFlags = BBBF_ISIMBUTTON | BBBF_ISCHATBUTTON | BBBF_ISLSIDEBUTTON | BBBF_ISPUSHBUTTON | BBBF_CANBEHIDDEN | BBBF_CREATEBYID;
- bbd.dwButtonID = IDC_FONTUNDERLINE; - bbd.dwDefPos = 60; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[12]; - bbd.ptszTooltip = LPGENT("Underlined text"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwButtonID = IDC_FONTUNDERLINE;
+ bbd.dwDefPos = 60;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[12];
+ bbd.ptszTooltip = LPGENT("Underlined text");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
bbd.bbbFlags = BBBF_ISIMBUTTON | BBBF_ISLSIDEBUTTON | BBBF_ISPUSHBUTTON | BBBF_CANBEHIDDEN | BBBF_CREATEBYID;
- bbd.dwButtonID = IDC_FONTSTRIKEOUT; - bbd.dwDefPos = 70; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[15]; - bbd.ptszTooltip = LPGENT("Strike-through text"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwButtonID = IDC_FONTSTRIKEOUT;
+ bbd.dwDefPos = 70;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[15];
+ bbd.ptszTooltip = LPGENT("Strike-through text");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
bbd.bbbFlags = BBBF_ISIMBUTTON | BBBF_ISCHATBUTTON | BBBF_ISLSIDEBUTTON | BBBF_CANBEHIDDEN | BBBF_CREATEBYID;
- bbd.dwButtonID = IDC_FONTFACE; - bbd.dwDefPos = 80; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[14]; - bbd.ptszTooltip = LPGENT("Select font color"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwButtonID = IDC_FONTFACE;
+ bbd.dwDefPos = 80;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[14];
+ bbd.ptszTooltip = LPGENT("Select font color");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
bbd.bbbFlags = BBBF_ISIMBUTTON | BBBF_ISCHATBUTTON | BBBF_ISRSIDEBUTTON | BBBF_ISARROWBUTTON | BBBF_CREATEBYID;
bbd.dwButtonID = IDOK;
- bbd.dwDefPos = 10; - bbd.iButtonWidth = 51; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[6]; - bbd.ptszTooltip = LPGENT("Send message\nClick dropdown arrow for sending options"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwDefPos = 10;
+ bbd.iButtonWidth = 51;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[6];
+ bbd.ptszTooltip = LPGENT("Send message\nClick dropdown arrow for sending options");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
bbd.bbbFlags = BBBF_ISIMBUTTON | BBBF_ISCHATBUTTON | BBBF_ISRSIDEBUTTON | BBBF_CREATEBYID;
bbd.dwButtonID = IDC_SAVE;
- bbd.dwDefPos = 20; - bbd.iButtonWidth = 0; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[8]; - bbd.ptszTooltip = LPGENT("Close session"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwDefPos = 20;
+ bbd.iButtonWidth = 0;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[8];
+ bbd.ptszTooltip = LPGENT("Close session");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
bbd.bbbFlags = BBBF_ISIMBUTTON | BBBF_ISRSIDEBUTTON | BBBF_CREATEBYID;
bbd.dwButtonID = IDC_QUOTE;
- bbd.dwDefPos = 30; - bbd.iButtonWidth = 0; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[4]; - bbd.ptszTooltip = LPGENT("Quote last message OR selected text"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwDefPos = 30;
+ bbd.iButtonWidth = 0;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[4];
+ bbd.ptszTooltip = LPGENT("Quote last message OR selected text");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
bbd.bbbFlags = BBBF_ISIMBUTTON | BBBF_ISRSIDEBUTTON | BBBF_CREATEBYID;
bbd.dwButtonID = IDC_TIME;
- bbd.dwDefPos = 40; - bbd.iButtonWidth = 0; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[2]; - bbd.ptszTooltip = LPGENT("Message Log Options"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwDefPos = 40;
+ bbd.iButtonWidth = 0;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[2];
+ bbd.ptszTooltip = LPGENT("Message Log Options");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
bbd.bbbFlags = BBBF_ISIMBUTTON | BBBF_ISCHATBUTTON | BBBF_ISRSIDEBUTTON | BBBF_CREATEBYID;
bbd.dwButtonID = IDC_HISTORY;
- bbd.dwDefPos = 50; - bbd.iButtonWidth = 0; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[0]; - bbd.ptszTooltip = LPGENT("View User's History"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwDefPos = 50;
+ bbd.iButtonWidth = 0;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[0];
+ bbd.ptszTooltip = LPGENT("View User's History");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
bbd.bbbFlags = BBBF_ISIMBUTTON | BBBF_ISRSIDEBUTTON | BBBF_CREATEBYID;
bbd.dwButtonID = IDC_PIC;
- bbd.dwDefPos = 60; - bbd.iButtonWidth = 0; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[7]; - bbd.ptszTooltip = LPGENT("Edit user notes"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwDefPos = 60;
+ bbd.iButtonWidth = 0;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[7];
+ bbd.ptszTooltip = LPGENT("Edit user notes");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
//chat buttons
bbd.bbbFlags = BBBF_ISCHATBUTTON | BBBF_ISLSIDEBUTTON | BBBF_ISDUMMYBUTTON;
@@ -1088,41 +1087,41 @@ void CB_InitDefaultButtons() bbd.bbbFlags = BBBF_ISCHATBUTTON | BBBF_ISLSIDEBUTTON | BBBF_ISPUSHBUTTON | BBBF_CREATEBYID;
bbd.dwButtonID = IDC_BKGCOLOR;
bbd.pszModuleName = "Tabsrmm";
- bbd.dwDefPos = 81; - bbd.iButtonWidth = 22; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[16]; - bbd.ptszTooltip = LPGENT("Change background color"); - - CB_AddButton(0, (LPARAM)&bbd); - // + bbd.dwDefPos = 81;
+ bbd.iButtonWidth = 22;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[16];
+ bbd.ptszTooltip = LPGENT("Change background color");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+ //
bbd.bbbFlags = BBBF_ISCHATBUTTON | BBBF_ISRSIDEBUTTON | BBBF_CREATEBYID;
bbd.dwButtonID = IDC_SHOWNICKLIST;
- bbd.dwDefPos = 22; - bbd.iButtonWidth = 22; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[19]; - bbd.ptszTooltip = LPGENT("Toggle nick list"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwDefPos = 22;
+ bbd.iButtonWidth = 22;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[19];
+ bbd.ptszTooltip = LPGENT("Toggle nick list");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
bbd.bbbFlags = BBBF_ISCHATBUTTON | BBBF_ISRSIDEBUTTON | BBBF_CREATEBYID;
bbd.dwButtonID = IDC_FILTER;
- bbd.dwDefPos = 24; - bbd.iButtonWidth = 22; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[18]; - bbd.ptszTooltip = LPGENT("Event filter - right click to setup, left click to activate/deactivate"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwDefPos = 24;
+ bbd.iButtonWidth = 22;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[18];
+ bbd.ptszTooltip = LPGENT("Event filter - right click to setup, left click to activate/deactivate");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
bbd.bbbFlags = BBBF_ISCHATBUTTON | BBBF_ISRSIDEBUTTON | BBBF_CREATEBYID;
bbd.dwButtonID = IDC_CHANMGR;
- bbd.dwDefPos = 33; - bbd.iButtonWidth = 22; - bbd.hIcon = PluginConfig.g_buttonBarIconHandles[17]; - bbd.ptszTooltip = LPGENT("Channel manager"); - - CB_AddButton(0, (LPARAM)&bbd); - + bbd.dwDefPos = 33;
+ bbd.iButtonWidth = 22;
+ bbd.hIcon = PluginConfig.g_buttonBarIconHandles[17];
+ bbd.ptszTooltip = LPGENT("Channel manager");
+
+ CB_AddButton(0, (LPARAM)&bbd);
+
BB_RegisterSeparators();
}
@@ -1231,13 +1230,13 @@ static int BuildMenuObjectsTree(HWND hToolBarTree) for (i=0; i < LButtonsList->realCount; i++) {
CustomButtonData * cbd = (CustomButtonData *)LButtonsList->items[i];
- tvis.item.lParam = (LPARAM)cbd; - - if (cbd->bDummy) { - tvis.item.pszText = TranslateT("<Separator>"); - tvis.item.iImage = tvis.item.iSelectedImage = 0; - } else { - tvis.item.pszText = TranslateTS(cbd->ptszTooltip); + tvis.item.lParam = (LPARAM)cbd;
+
+ if (cbd->bDummy) {
+ tvis.item.pszText = TranslateT("<Separator>");
+ tvis.item.iImage = tvis.item.iSelectedImage = 0;
+ } else {
+ tvis.item.pszText = TranslateTS(cbd->ptszTooltip);
iImage = ImageList_AddIcon(himgl, Skin_GetIconByHandle(cbd->hIcon));
tvis.item.iImage = tvis.item.iSelectedImage = iImage;
}
@@ -1261,13 +1260,13 @@ static int BuildMenuObjectsTree(HWND hToolBarTree) for (i = RButtonsList->realCount; i > 0; i--) {
CustomButtonData * cbd = (CustomButtonData *)RButtonsList->items[i-1];
- tvis.item.lParam = (LPARAM)cbd; - - if (cbd->bDummy) { - tvis.item.pszText = TranslateT("<Separator>"); - tvis.item.iImage = tvis.item.iSelectedImage = -1; - } else { - tvis.item.pszText = TranslateTS(cbd->ptszTooltip); + tvis.item.lParam = (LPARAM)cbd;
+
+ if (cbd->bDummy) {
+ tvis.item.pszText = TranslateT("<Separator>");
+ tvis.item.iImage = tvis.item.iSelectedImage = -1;
+ } else {
+ tvis.item.pszText = TranslateTS(cbd->ptszTooltip);
iImage = ImageList_AddIcon(himgl, Skin_GetIconByHandle(cbd->hIcon));
tvis.item.iImage = tvis.item.iSelectedImage = iImage;
}
@@ -1421,13 +1420,13 @@ INT_PTR CALLBACK DlgProcToolBar(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM l List_InsertPtr(LButtonsList, cbd);
tvis.hParent = NULL;
- tvis.hInsertAfter = hti; - tvis.item.mask = TVIF_PARAM | TVIF_TEXT | TVIF_IMAGE | TVIF_SELECTEDIMAGE; - - tvis.item.pszText = TranslateT("<Separator>"); - tvis.item.iImage = tvis.item.iSelectedImage = -1; - tvis.item.lParam = (LPARAM)cbd; - + tvis.hInsertAfter = hti;
+ tvis.item.mask = TVIF_PARAM | TVIF_TEXT | TVIF_IMAGE | TVIF_SELECTEDIMAGE;
+
+ tvis.item.pszText = TranslateT("<Separator>");
+ tvis.item.iImage = tvis.item.iSelectedImage = -1;
+ tvis.item.lParam = (LPARAM)cbd;
+
hti = TreeView_InsertItem(hToolBarTree, &tvis);
TreeView_SetCheckState(hToolBarTree, hti, (cbd->bIMButton || cbd->bChatButton));
diff --git a/plugins/TabSRMM/src/chat/chat.h b/plugins/TabSRMM/src/chat/chat.h index 97224cef53..12fa5bb75d 100644 --- a/plugins/TabSRMM/src/chat/chat.h +++ b/plugins/TabSRMM/src/chat/chat.h @@ -30,20 +30,11 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: chat.h 12272 2010-08-04 08:24:08Z silvercircle $
- *
*/
#ifndef _CHAT_H_
#define _CHAT_H_
-#pragma warning( disable : 4786 ) // limitation in MSVC's debugger.
-#pragma warning( disable : 4996 ) // limitation in MSVC's debugger.
-
-#define WIN32_LEAN_AND_MEAN
-
-#include "m_stdhdr.h"
-
//defines
#define OPTIONS_FONTCOUNT 20
#define GC_UPDATETITLE (WM_USER+100)
diff --git a/plugins/TabSRMM/src/chat/chatprototypes.h b/plugins/TabSRMM/src/chat/chatprototypes.h index c304b38cec..4f682ce6b4 100644 --- a/plugins/TabSRMM/src/chat/chatprototypes.h +++ b/plugins/TabSRMM/src/chat/chatprototypes.h @@ -16,9 +16,6 @@ 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.
-
-$Id: chatprototypes.h 13184 2010-12-07 14:16:58Z silvercircle $
-
*/
void LoadIcons(void);
diff --git a/plugins/TabSRMM/src/chat/clist.cpp b/plugins/TabSRMM/src/chat/clist.cpp index d3714fc820..d465202497 100644 --- a/plugins/TabSRMM/src/chat/clist.cpp +++ b/plugins/TabSRMM/src/chat/clist.cpp @@ -26,8 +26,6 @@ contacts and handle default action for such contacts. This code was taken in almost unmodified from from the chat.dll
plugin, originally written by Jörgen Persson
-$Id: clist.c 10402 2009-07-24 00:35:21Z silvercircle $
-
*/
/*
@@ -38,8 +36,6 @@ $Id: clist.c 10402 2009-07-24 00:35:21Z silvercircle $ char *szChatIconString = "chaticon";
-extern HANDLE hJoinMenuItem, hLeaveMenuItem;
-
static HANDLE Clist_GroupExists(TCHAR *tszGroup)
{
unsigned int i = 0;
diff --git a/plugins/TabSRMM/src/chat/colorchooser.cpp b/plugins/TabSRMM/src/chat/colorchooser.cpp index 2bf8b4ded2..53a0ae67cc 100644 --- a/plugins/TabSRMM/src/chat/colorchooser.cpp +++ b/plugins/TabSRMM/src/chat/colorchooser.cpp @@ -30,14 +30,11 @@ * original chat module for Miranda NG, written and copyrighted
* by Joergen Persson in 2005.
*
- * $Id: colorchooser.cpp 10670 2009-09-11 03:28:50Z silvercircle $
- *
* Color chooser for group chats
*
*/
#include "..\commonheaders.h"
-#include <math.h>
static int CalculateCoordinatesToButton(COLORCHOOSER * pCC, POINT pt)
{
diff --git a/plugins/TabSRMM/src/chat/log.cpp b/plugins/TabSRMM/src/chat/log.cpp index 9aa450af3d..cf58bec369 100644 --- a/plugins/TabSRMM/src/chat/log.cpp +++ b/plugins/TabSRMM/src/chat/log.cpp @@ -30,25 +30,18 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: log.cpp 13614 2011-04-22 13:16:21Z borkra $
- *
* Implements the richedit-based message history display for the group
* chat window.
*
*/
#include "..\commonheaders.h"
-#include <math.h>
-#include <mbstring.h>
/*
* The code for streaming the text is to a large extent copied from
* the srmm module and then modified to fit the chat module.
*/
-extern FONTINFO aFonts[OPTIONS_FONTCOUNT];
-extern HICON hIcons[30];
-
static PBYTE pLogIconBmpBits[14];
static int logIconBmpSize[ SIZEOF(pLogIconBmpBits)];
diff --git a/plugins/TabSRMM/src/chat/main.cpp b/plugins/TabSRMM/src/chat/main.cpp index 56489a2fc9..1e8919e8c0 100644 --- a/plugins/TabSRMM/src/chat/main.cpp +++ b/plugins/TabSRMM/src/chat/main.cpp @@ -30,8 +30,6 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: main.cpp 13132 2010-11-17 03:47:44Z silvercircle $
- *
* chat module exports and functions to load/unload the plugin.
*
*/
diff --git a/plugins/TabSRMM/src/chat/manager.cpp b/plugins/TabSRMM/src/chat/manager.cpp index e8a203a470..090f4ce119 100644 --- a/plugins/TabSRMM/src/chat/manager.cpp +++ b/plugins/TabSRMM/src/chat/manager.cpp @@ -19,24 +19,16 @@ 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.
-
-$Id: manager.cpp 14208 2012-03-26 13:56:42Z silvercircle $
*/
#include "..\commonheaders.h"
-extern TCHAR *pszActiveWndID ;
-extern char *pszActiveWndModule ;
-extern HICON hIcons[30];
-
#define WINDOWS_COMMANDS_MAX 30
#define STATUSICONCOUNT 6
SESSION_INFO *m_WndList = 0;
MODULEINFO *m_ModList = 0;
-extern CRITICAL_SECTION cs;
-
void SetActiveSession(const TCHAR* pszID, const char* pszModule)
{
SESSION_INFO* si = SM_FindSession(pszID, pszModule);
diff --git a/plugins/TabSRMM/src/chat/message.cpp b/plugins/TabSRMM/src/chat/message.cpp index 5fb99a38c4..0b6e0b00a4 100644 --- a/plugins/TabSRMM/src/chat/message.cpp +++ b/plugins/TabSRMM/src/chat/message.cpp @@ -19,12 +19,9 @@ 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.
-
-$Id: message.c 10402 2009-07-24 00:35:21Z silvercircle $
*/
#include "..\commonheaders.h"
-#include <math.h>
static int RTFColorToIndex(int *pIndex, int iCol, SESSION_INFO* si)
{
diff --git a/plugins/TabSRMM/src/chat/muchighlight.cpp b/plugins/TabSRMM/src/chat/muchighlight.cpp index 36bf980b3c..935d2e38d4 100644 --- a/plugins/TabSRMM/src/chat/muchighlight.cpp +++ b/plugins/TabSRMM/src/chat/muchighlight.cpp @@ -26,16 +26,12 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: muchighlight.cpp 13184 2010-12-07 14:16:58Z silvercircle $
- *
* highlighter class for multi user chats
*
*/
#include "..\commonheaders.h"
-//#define __HLT_PERFSTATS 0
-
void CMUCHighlight::cleanup()
{
if (m_NickPatternString)
diff --git a/plugins/TabSRMM/src/chat/options.cpp b/plugins/TabSRMM/src/chat/options.cpp index 5057f53ab7..d74e321c5d 100644 --- a/plugins/TabSRMM/src/chat/options.cpp +++ b/plugins/TabSRMM/src/chat/options.cpp @@ -30,21 +30,12 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: options.cpp 13412 2011-03-08 19:13:11Z george.hazan $
- *
* group chat options and generic font handling
*
*/
#include "..\commonheaders.h"
-extern HBRUSH hListBkgBrush;
-extern HICON hIcons[30];
-extern FONTINFO aFonts[OPTIONS_FONTCOUNT];
-extern HMODULE g_hIconDLL;
-
-extern HIMAGELIST CreateStateImageList();
-
#define FONTF_BOLD 1
#define FONTF_ITALIC 2
diff --git a/plugins/TabSRMM/src/chat/services.cpp b/plugins/TabSRMM/src/chat/services.cpp index 9219d730f2..ed4907467a 100644 --- a/plugins/TabSRMM/src/chat/services.cpp +++ b/plugins/TabSRMM/src/chat/services.cpp @@ -30,17 +30,12 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: services.cpp 13046 2010-10-28 10:02:50Z silvercircle $
- *
* This implements the services that form the group chat API
*
*/
#include "..\commonheaders.h"
-// defs
-extern HICON hIcons[30];
-
CRITICAL_SECTION cs;
HANDLE hSendEvent;
@@ -454,9 +449,9 @@ HWND CreateNewRoom(TContainerData *pContainer, SESSION_INFO *si, BOOL bActivateT TCHAR newcontactname[128];
if ( lstrlen(contactName) > 0) {
if (M->GetByte("cuttitle", 0))
- CutContactName(contactName, newcontactname, safe_sizeof(newcontactname));
+ CutContactName(contactName, newcontactname, SIZEOF(newcontactname));
else {
- lstrcpyn(newcontactname, contactName, safe_sizeof(newcontactname));
+ lstrcpyn(newcontactname, contactName, SIZEOF(newcontactname));
newcontactname[127] = 0;
}
}
diff --git a/plugins/TabSRMM/src/chat/tools.cpp b/plugins/TabSRMM/src/chat/tools.cpp index dfe7071225..e6576b39e9 100644 --- a/plugins/TabSRMM/src/chat/tools.cpp +++ b/plugins/TabSRMM/src/chat/tools.cpp @@ -30,21 +30,12 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: tools.cpp 13650 2011-05-30 11:53:13Z silvercircle@gmail.com $
- *
* Helper functions for the group chat module.
*
*/
#include "..\commonheaders.h"
-// externs
-extern HICON hIcons[30];
-extern FONTINFO aFonts[OPTIONS_FONTCOUNT];
-extern HMENU g_hMenu;
-extern HANDLE hBuildMenuEvent ;
-extern HANDLE hSendEvent;
-
int GetRichTextLength(HWND hwnd)
{
GETTEXTLENGTHEX gtl;
diff --git a/plugins/TabSRMM/src/chat/window.cpp b/plugins/TabSRMM/src/chat/window.cpp index 17c8f5580a..ed591ba6d1 100644 --- a/plugins/TabSRMM/src/chat/window.cpp +++ b/plugins/TabSRMM/src/chat/window.cpp @@ -30,15 +30,12 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: window.cpp 13631 2011-04-24 08:44:57Z silvercircle $
- *
* This implements the group chat dialog window
*
*/
#include "..\commonheaders.h"
-#include <tom.h>
//#include "../m_MathModule.h"
@@ -2118,9 +2115,9 @@ INT_PTR CALLBACK RoomWndProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPar if (lstrlen(szNick) > 0) {
if (M->GetByte("cuttitle", 0))
- CutContactName(szNick, dat->newtitle, safe_sizeof(dat->newtitle));
+ CutContactName(szNick, dat->newtitle, SIZEOF(dat->newtitle));
else {
- lstrcpyn(dat->newtitle, szNick, safe_sizeof(dat->newtitle));
+ lstrcpyn(dat->newtitle, szNick, SIZEOF(dat->newtitle));
dat->newtitle[129] = 0;
}
}
diff --git a/plugins/TabSRMM/src/commonheaders.h b/plugins/TabSRMM/src/commonheaders.h index 83ccf13448..ab646524f8 100644 --- a/plugins/TabSRMM/src/commonheaders.h +++ b/plugins/TabSRMM/src/commonheaders.h @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: commonheaders.h 13596 2011-04-15 19:07:23Z george.hazan $
- *
* global include file, used to build the precompiled header.
*
*/
@@ -36,15 +34,6 @@ #ifndef __COMMONHEADERS_H
#define __COMMONHEADERS_H
-#define _UNICODE 1
-
-//#define __LOGDEBUG_ 1 // log some stuff to %profile_dir%/tabsrmm_debug.log
-//#define __FEAT_DEPRECATED_DYNAMICSWITCHLOGVIEWER 1
-
-//#define __USE_EX_HANDLERS 1
-
-// #define __DELAYED_FOR_3_1 1 // features not going into 3.0.x and will be completed later
-
#if !defined __DELAYED_FOR_3_1
#define __FEAT_EXP_AUTOSPLITTER 1
#endif
@@ -54,64 +43,146 @@ #define _WIN32_IE 0x0501
#define WIN32_LEAN_AND_MEAN
-#define MIRANDA_VER 0x0A00
-
-#include <m_stdhdr.h>
-
#include <windows.h>
-#include <commctrl.h>
#include <commdlg.h>
#include <shellapi.h>
#include <uxtheme.h>
-#include <vsstyle.h>
+#include <tom.h>
+#include <time.h>
+#include <shlwapi.h>
+#include <shlobj.h>
+#include <vector>
+#include <assert.h>
+#include <mbstring.h>
+#include <richedit.h>
+#include <richole.h>
+#include <string>
+
+#include <msapi\vsstyle.h>
+#include <m_avatars.h>
+#include <m_message.h>
+#include <win2k.h>
+#include <newpluginapi.h>
+#include <m_imgsrvc.h>
+#include <m_database.h>
+#include <m_langpack.h>
+#include <m_button.h>
+#include <m_protosvc.h>
+#include <m_skin.h>
+#include <m_contacts.h>
+#include <m_icolib.h>
+#include <m_clc.h>
+#include <m_clui.h>
+#include <m_userinfo.h>
+#include <m_history.h>
+#include <m_addcontact.h>
+#include <m_file.h>
+#include <m_fontservice.h>
+#include <m_acc.h>
+#include <m_chat.h>
+#include <m_protomod.h>
+#include <m_hotkeys.h>
+#include <m_genmenu.h>
+#include <m_popup.h>
+#include <m_timezones.h>
+#include <m_modernopt.h>
+
+#include <m_ieview.h>
+#include <m_popup2.h>
+#include <m_metacontacts.h>
+#include <m_fingerprint.h>
+#include <m_nudge.h>
+#include <m_folders.h>
+#include <m_msg_buttonsbar.h>
+#include <m_flash.h>
+#include <m_mathmodule.h>
+#include <m_historyevents.h>
+#include <m_smileyadd.h>
#define TSAPI __stdcall
#define FASTCALL __fastcall
- /*
- * text shadow types (DrawThemeTextEx() / Vista+ uxtheme)
- */
- #define TST_NONE 0
- #define TST_SINGLE 1
- #define TST_CONTINUOUS 2
+typedef HANDLE HTHUMBNAIL;
+typedef HTHUMBNAIL* PHTHUMBNAIL;
+
+typedef struct _DWM_BLURBEHIND
+{
+ DWORD dwFlags;
+ BOOL fEnable;
+ HRGN hRgnBlur;
+ BOOL fTransitionOnMaximized;
+} DWM_BLURBEHIND, *PDWM_BLURBEHIND;
+
+typedef struct _DWM_THUMBNAIL_PROPERTIES
+{
+ DWORD dwFlags;
+ RECT rcDestination;
+ RECT rcSource;
+ BYTE opacity;
+ BOOL fVisible;
+ BOOL fSourceClientAreaOnly;
+} DWM_THUMBNAIL_PROPERTIES, *PDWM_THUMBNAIL_PROPERTIES;
+
+#include "m_cln_skinedit.h"
+
+#include "resource.h"
+#include "version.h"
+#include "buttonbar.h"
+#include "msgs.h"
+#include "msgdlgutils.h"
+#include "typingnotify.h"
+#include "generic_msghandlers.h"
+#include "nen.h"
+#include "functions.h"
+#include "chat/chat.h"
+#include "contactcache.h"
+#include "translator.h"
+#include "themes.h"
+#include "globals.h"
+#include "mim.h"
+#include "sendqueue.h"
+#include "taskbar.h"
+#include "controls.h"
+#include "infopanel.h"
+#include "sidebar.h"
+#include "utils.h"
+#include "sendlater.h"
+#include "ImageDataObject.h"
+#include "chat/muchighlight.h"
+
+
+/*
+* text shadow types (DrawThemeTextEx() / Vista+ uxtheme)
+*/
+#define TST_NONE 0
+#define TST_SINGLE 1
+#define TST_CONTINUOUS 2
+
+enum DWMWINDOWATTRIBUTE
+{
+ DWMWA_NCRENDERING_ENABLED = 1, // [get] Is non-client rendering enabled/disabled
+ DWMWA_NCRENDERING_POLICY, // [set] Non-client rendering policy
+ DWMWA_TRANSITIONS_FORCEDISABLED, // [set] Potentially enable/forcibly disable transitions
+ DWMWA_ALLOW_NCPAINT, // [set] Allow contents rendered in the non-client area to be visible on the DWM-drawn frame.
+ DWMWA_CAPTION_BUTTON_BOUNDS, // [get] Bounds of the caption button area in window-relative space.
+ DWMWA_NONCLIENT_RTL_LAYOUT, // [set] Is non-client content RTL mirrored
+ DWMWA_FORCE_ICONIC_REPRESENTATION, // [set] Force this window to display iconic thumbnails.
+ DWMWA_FLIP3D_POLICY, // [set] Designates how Flip3D will treat the window.
+ DWMWA_EXTENDED_FRAME_BOUNDS, // [get] Gets the extended frame bounds rectangle in screen space
+ DWMWA_HAS_ICONIC_BITMAP, // [set] Indicates an available bitmap when there is no better thumbnail representation.
+ DWMWA_DISALLOW_PEEK, // [set] Don't invoke Peek on the window.
+ DWMWA_EXCLUDED_FROM_PEEK, // [set] LivePreview exclusion information
+ DWMWA_LAST
+};
+
+#define DWM_TNP_RECTDESTINATION 0x00000001
+#define DWM_TNP_RECTSOURCE 0x00000002
+#define DWM_TNP_OPACITY 0x00000004
+#define DWM_TNP_VISIBLE 0x00000008
+#define DWM_TNP_SOURCECLIENTAREAONLY 0x00000010
+
+#define DWM_SIT_DISPLAYFRAME 0x00000001 // Display a window frame around the provided bitmap
- typedef struct _DWM_THUMBNAIL_PROPERTIES
- {
- DWORD dwFlags;
- RECT rcDestination;
- RECT rcSource;
- BYTE opacity;
- BOOL fVisible;
- BOOL fSourceClientAreaOnly;
- } DWM_THUMBNAIL_PROPERTIES, *PDWM_THUMBNAIL_PROPERTIES;
-
- enum DWMWINDOWATTRIBUTE
- {
- DWMWA_NCRENDERING_ENABLED = 1, // [get] Is non-client rendering enabled/disabled
- DWMWA_NCRENDERING_POLICY, // [set] Non-client rendering policy
- DWMWA_TRANSITIONS_FORCEDISABLED, // [set] Potentially enable/forcibly disable transitions
- DWMWA_ALLOW_NCPAINT, // [set] Allow contents rendered in the non-client area to be visible on the DWM-drawn frame.
- DWMWA_CAPTION_BUTTON_BOUNDS, // [get] Bounds of the caption button area in window-relative space.
- DWMWA_NONCLIENT_RTL_LAYOUT, // [set] Is non-client content RTL mirrored
- DWMWA_FORCE_ICONIC_REPRESENTATION, // [set] Force this window to display iconic thumbnails.
- DWMWA_FLIP3D_POLICY, // [set] Designates how Flip3D will treat the window.
- DWMWA_EXTENDED_FRAME_BOUNDS, // [get] Gets the extended frame bounds rectangle in screen space
- DWMWA_HAS_ICONIC_BITMAP, // [set] Indicates an available bitmap when there is no better thumbnail representation.
- DWMWA_DISALLOW_PEEK, // [set] Don't invoke Peek on the window.
- DWMWA_EXCLUDED_FROM_PEEK, // [set] LivePreview exclusion information
- DWMWA_LAST
- };
-
- #define DWM_TNP_RECTDESTINATION 0x00000001
- #define DWM_TNP_RECTSOURCE 0x00000002
- #define DWM_TNP_OPACITY 0x00000004
- #define DWM_TNP_VISIBLE 0x00000008
- #define DWM_TNP_SOURCECLIENTAREAONLY 0x00000010
-
- #define DWM_SIT_DISPLAYFRAME 0x00000001 // Display a window frame around the provided bitmap
-
- typedef HANDLE HTHUMBNAIL;
- typedef HTHUMBNAIL* PHTHUMBNAIL;
#ifndef BPPF_ERASE
typedef enum _BP_BUFFERFORMAT
@@ -136,15 +207,8 @@ #define BPPF_NONCLIENT 4
#endif
- typedef struct _DWM_BLURBEHIND
- {
- DWORD dwFlags;
- BOOL fEnable;
- HRGN hRgnBlur;
- BOOL fTransitionOnMaximized;
- } DWM_BLURBEHIND, *PDWM_BLURBEHIND;
- #define DWM_BB_ENABLE 1
+#define DWM_BB_ENABLE 1
#ifndef LOCALE_SISO3166CTRYNAME2
#define LOCALE_SISO3166CTRYNAME2 0x00000068 // 3 character ISO country name, eg "USA Vista+
@@ -161,95 +225,10 @@ #define WM_DWMSENDICONICLIVEPREVIEWBITMAP 0x0326
#endif
-#include <stdio.h>
-#include <time.h>
-#include <stddef.h>
-#include <process.h>
-#include <shlwapi.h>
-#include <shlobj.h>
-#include <richedit.h>
-#include <limits.h>
-#include <ctype.h>
-#include <string>
-#include <vector>
-#include <assert.h>
-
-#include "include/resource.h"
/* State of icon with such flag will not be saved, and you must set it manually */
#define MBF_OWNERSTATE 0x04
-#include <win2k.h>
-#include <newpluginapi.h>
-#include <m_imgsrvc.h>
-#include <m_system.h>
-#include <m_system_cpp.h>
-#include <m_database.h>
-#include <m_langpack.h>
-#include <m_button.h>
-#include <m_clist.h>
-#include <m_options.h>
-#include <m_protosvc.h>
-#include <m_utils.h>
-#include <m_skin.h>
-#include <m_contacts.h>
-#include <m_icolib.h>
-#include <m_clc.h>
-#include <m_clui.h>
-#include <m_userinfo.h>
-#include <m_history.h>
-#include <m_addcontact.h>
-#include <m_file.h>
-#include <m_fontservice.h>
-#include <m_acc.h>
-#include <m_chat.h>
-#include <m_protomod.h>
-#include <m_hotkeys.h>
-#include <m_genmenu.h>
-#include <m_popup.h>
-#include <m_timezones.h>
-
-#define safe_sizeof(a) (unsigned int)((sizeof((a)) / sizeof((a)[0])))
-
-#include "include/version.h"
-#include "m_ieview.h"
-#include "m_popup2.h"
-#include "m_metacontacts.h"
-#include "m_fingerprint.h"
-#include "m_nudge.h"
-#include "m_folders.h"
-#include "m_msg_buttonsbar.h"
-#include "m_flash.h"
-#include "m_spellchecker.h"
-#include "m_mathmodule.h"
-#include "m_historyevents.h"
-#include "m_smileyadd.h"
-
-#include "include/m_cln_skinedit.h"
-#include "include/buttonbar.h"
-#include "include/msgs.h"
-#include "include/msgdlgutils.h"
-#include "include/typingnotify.h"
-#include "include/generic_msghandlers.h"
-#include "include/nen.h"
-extern NEN_OPTIONS nen_options;
-#include "include/functions.h"
-#include "chat/chat.h"
-
-#include "include/contactcache.h"
-#include "include/translator.h"
-#include "include/themes.h"
-#include "include/globals.h"
-#include "include/mim.h"
-#include "include/sendqueue.h"
-#include "include/taskbar.h"
-#include "include/controls.h"
-#include "include/infopanel.h"
-#include "include/sidebar.h"
-#include "include/utils.h"
-#include "include/sendlater.h"
-
-#include "chat/muchighlight.h"
#if !defined(_WIN64) && !defined(_USE_32BIT_TIME_T)
#define _USE_32BIT_TIME_T
@@ -257,32 +236,72 @@ extern NEN_OPTIONS nen_options; #undef _USE_32BIT_TIME_T
#endif
-#if defined(__GNUWIN32__)
- #define wEffects wReserved
-#endif
-
-#if defined(__GNUG__)
-#define __except(x) if (x)
-#define __try
-#define __finally
-
-EXCEPTION_POINTERS* GetExceptionInformation()
-{
- EXCEPTION_POINTERS e;
- return(&e);
-}
-#endif
-
/*
- * tchar-like std::string
- */
-
+* tchar-like std::string
+*/
typedef std::basic_string<TCHAR> tstring;
-extern HINSTANCE g_hInst;
+extern NEN_OPTIONS nen_options;
+extern HINSTANCE g_hInst;
extern CSkinItem SkinItems[];
extern TContainerData *pFirstContainer, *pLastActiveContainer;
extern HANDLE hTypingNotify;
+extern SESSION_INFO *m_WndList;
+extern ButtonSet g_ButtonSet;
+extern int status_icon_list_size;
+extern TStatusBarIconNode *status_icon_list;
+extern HANDLE g_hEvent;
+extern RECT rcLastStatusBarClick;
+extern PLUGININFOEX pluginInfo;
+extern HICON hIcons[];
+extern TTemplateSet RTL_Active, LTR_Active;
+extern LOGFONTA logfonts[MSGDLGFONTCOUNT + 2];
+extern COLORREF fontcolors[MSGDLGFONTCOUNT + 2];
+extern HINSTANCE hinstance;
+extern BOOL g_bIMGtagButton;
+extern HIMAGELIST g_himlOptions;
+extern HANDLE hHookToolBarLoadedEvt;
+extern struct TLogIcon msgLogIcons[NR_LOGICONS * 3];
+extern const TCHAR *pszIDCSAVE_save, *pszIDCSAVE_close;
+extern char *TemplateNames[];
+extern HANDLE hUserPrefsWindowList;
+extern struct TCpTable cpTable[];
+extern HANDLE hJoinMenuItem, hLeaveMenuItem;
+extern FONTINFO aFonts[OPTIONS_FONTCOUNT];
+extern TCHAR *pszActiveWndID;
+extern char *pszActiveWndModule;
+extern CRITICAL_SECTION cs;
+extern HBRUSH hListBkgBrush;
+extern HMODULE g_hIconDLL;
+extern HMENU g_hMenu;
+extern HANDLE hBuildMenuEvent;
+extern HANDLE hSendEvent;
+
+extern int LoadSendRecvMessageModule(void);
+extern int SplitmsgShutdown(void);
+extern void LogErrorMessage(HWND hwndDlg, struct TWindowData *dat, int i, TCHAR *szMsg);
+extern int Chat_Load(), Chat_Unload();
+extern void FreeLogFonts();
+extern INT_PTR CALLBACK DlgProcSetupStatusModes(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
+extern HIMAGELIST CreateStateImageList();
+extern INT_PTR SendMessageCommand(WPARAM wParam, LPARAM lParam);
+extern INT_PTR SendMessageCommand_W(WPARAM wParam, LPARAM lParam);
+extern void ReleaseRichEditOle(IRichEditOle *ole);
+extern void ImageDataInsertBitmap(IRichEditOle *ole, HBITMAP hBm);
+extern int CacheIconToBMP(struct TLogIcon *theIcon, HICON hIcon, COLORREF backgroundColor, int sizeX, int sizeY);
+extern void DeleteCachedIcon(struct TLogIcon *theIcon);
+extern INT_PTR CALLBACK DlgProcPopupOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
+extern INT_PTR CALLBACK DlgProcTabConfig(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
+extern INT_PTR CALLBACK DlgProcTemplateEditor(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
+extern INT_PTR CALLBACK DlgProcToolBar(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
+extern INT_PTR CALLBACK PlusOptionsProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
+extern INT_PTR CALLBACK DlgProcOptions1(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
+extern INT_PTR CALLBACK DlgProcOptions2(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
+extern INT_PTR CALLBACK DlgProcOptions3(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
+extern INT_PTR CALLBACK DlgProcUserPrefsFrame(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
+extern int TSAPI TBStateConvert2Flat(int state);
+extern int TSAPI RBStateConvert2Flat(int state);
+extern void TSAPI FillTabBackground(const HDC hdc, int iStateId, const TWindowData* dat, RECT* rc);
#define IS_EXTKEY(a) (a & (1 << 24))
diff --git a/plugins/TabSRMM/src/contactcache.cpp b/plugins/TabSRMM/src/contactcache.cpp index 046ed7377e..8a1b014c54 100644 --- a/plugins/TabSRMM/src/contactcache.cpp +++ b/plugins/TabSRMM/src/contactcache.cpp @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: contactcache.cpp 13336 2011-01-27 20:02:17Z george.hazan $
- *
* contact cache implementation
*
* the contact cache provides various services to the message window(s)
@@ -207,11 +205,11 @@ bool CContactCache::updateUIN() if (!CallService(MS_CONTACT_GETCONTACTINFO, 0, (LPARAM) & ci)) {
switch (ci.type) {
case CNFT_ASCIIZ:
- mir_sntprintf(m_szUIN, safe_sizeof(m_szUIN), _T("%s"), reinterpret_cast<TCHAR *>(ci.pszVal));
+ mir_sntprintf(m_szUIN, SIZEOF(m_szUIN), _T("%s"), reinterpret_cast<TCHAR *>(ci.pszVal));
mir_free((void*)ci.pszVal);
break;
case CNFT_DWORD:
- mir_sntprintf(m_szUIN, safe_sizeof(m_szUIN), _T("%u"), ci.dVal);
+ mir_sntprintf(m_szUIN, SIZEOF(m_szUIN), _T("%u"), ci.dVal);
break;
default:
m_szUIN[0] = 0;
diff --git a/plugins/TabSRMM/src/include/contactcache.h b/plugins/TabSRMM/src/contactcache.h index 309e95131d..ab166e6b3c 100644 --- a/plugins/TabSRMM/src/include/contactcache.h +++ b/plugins/TabSRMM/src/contactcache.h @@ -26,8 +26,6 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: contactcache.h 12846 2010-10-01 03:26:02Z silvercircle $
- *
* the contact cache
*
*/
diff --git a/plugins/TabSRMM/src/container.cpp b/plugins/TabSRMM/src/container.cpp index f1a3aa3ade..434ba36676 100644 --- a/plugins/TabSRMM/src/container.cpp +++ b/plugins/TabSRMM/src/container.cpp @@ -26,18 +26,12 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: container.cpp 13447 2011-03-14 19:55:07Z george.hazan $
- *
* implements the "Container" window which acts as a toplevel window
* for message sessions.
*
*/
#include "commonheaders.h"
-#pragma hdrstop
-
-extern SESSION_INFO* m_WndList;
-extern ButtonSet g_ButtonSet;
TContainerData *pFirstContainer = 0; // the linked list of struct ContainerWindowData
TContainerData *pLastActiveContainer = NULL;
@@ -2675,7 +2669,7 @@ HMENU TSAPI BuildMCProtocolMenu(HWND hwndDlg) { wStatus = (WORD)DBGetContactSettingWord(dat->hContact, PluginConfig.szMetaName, szTemp, 0);
szStatusText = (TCHAR *) CallService(MS_CLIST_GETSTATUSMODEDESCRIPTION, wStatus, GSMDF_TCHAR);
}
- mir_sntprintf(szMenuLine, safe_sizeof(szMenuLine), _T("%s: %s [%s] %s"), acc->tszAccountName, nick, szStatusText,
+ mir_sntprintf(szMenuLine, SIZEOF(szMenuLine), _T("%s: %s [%s] %s"), acc->tszAccountName, nick, szStatusText,
i == isForced ? TranslateT("(Forced)") : _T(""));
iChecked = MF_UNCHECKED;
if (hContactMostOnline != 0 && hContactMostOnline == handle)
diff --git a/plugins/TabSRMM/src/containeroptions.cpp b/plugins/TabSRMM/src/containeroptions.cpp index 48ce593a44..17b7a84fb0 100644 --- a/plugins/TabSRMM/src/containeroptions.cpp +++ b/plugins/TabSRMM/src/containeroptions.cpp @@ -26,14 +26,11 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: containeroptions.cpp 13631 2011-04-24 08:44:57Z silvercircle $
- *
* The dialog to customize per container options
*
*/
#include "commonheaders.h"
-#pragma hdrstop
static void MY_CheckDlgButton(HWND hWnd, UINT id, int iCheck)
{
diff --git a/plugins/TabSRMM/src/controls.cpp b/plugins/TabSRMM/src/controls.cpp index 1cad737eb4..07d0bc117d 100644 --- a/plugins/TabSRMM/src/controls.cpp +++ b/plugins/TabSRMM/src/controls.cpp @@ -26,17 +26,13 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: controls.cpp 13587 2011-04-12 13:54:26Z george.hazan $
- *
* Menu and status bar control(s) for the container window.
*
*/
#include "commonheaders.h"
-static WNDPROC OldStatusBarproc = 0;
-extern int status_icon_list_size;
-extern TStatusBarIconNode *status_icon_list;
+static WNDPROC OldStatusBarproc = 0;
bool CMenuBar::m_buttonsInit = false;
HHOOK CMenuBar::m_hHook = 0;
@@ -1080,7 +1076,7 @@ LONG_PTR CALLBACK StatusBarSubclassProc(HWND hWnd, UINT msg, WPARAM wParam, LPAR if ((int)iconNum == list_icons && pContainer) {
TCHAR wBuf[512];
- mir_sntprintf(wBuf, safe_sizeof(wBuf), TranslateT("Sounds are %s. Click to toggle status, hold SHIFT and click to set for all open containers"),
+ mir_sntprintf(wBuf, SIZEOF(wBuf), TranslateT("Sounds are %s. Click to toggle status, hold SHIFT and click to set for all open containers"),
pContainer->dwFlags & CNT_NOSOUND ? TranslateT("disabled") : TranslateT("enabled"));
CallService(szTTService, (WPARAM)wBuf, (LPARAM)&ti);
tooltip_active = TRUE;
@@ -1089,7 +1085,7 @@ LONG_PTR CALLBACK StatusBarSubclassProc(HWND hWnd, UINT msg, WPARAM wParam, LPAR int mtnStatus = (int)M->GetByte(dat->hContact, SRMSGMOD, SRMSGSET_TYPING, M->GetByte(SRMSGMOD, SRMSGSET_TYPINGNEW, SRMSGDEFSET_TYPINGNEW));
TCHAR wBuf[512];
- mir_sntprintf(wBuf, safe_sizeof(wBuf), TranslateT("Sending typing notifications is %s."),
+ mir_sntprintf(wBuf, SIZEOF(wBuf), TranslateT("Sending typing notifications is %s."),
mtnStatus ? TranslateT("enabled") : TranslateT("disabled"));
CallService(szTTService, (WPARAM)wBuf, (LPARAM)&ti);
tooltip_active = TRUE;
@@ -1097,7 +1093,7 @@ LONG_PTR CALLBACK StatusBarSubclassProc(HWND hWnd, UINT msg, WPARAM wParam, LPAR else if ((int)iconNum == list_icons + 2) {
TCHAR wBuf[512];
- mir_sntprintf(wBuf, safe_sizeof(wBuf), _T("%s"), TranslateT("Session list.\nClick left for a list of open sessions.\nClick right to access favorites and quickly configure message window behavior"));
+ mir_sntprintf(wBuf, SIZEOF(wBuf), _T("%s"), TranslateT("Session list.\nClick left for a list of open sessions.\nClick right to access favorites and quickly configure message window behavior"));
CallService(szTTService, (WPARAM)wBuf, (LPARAM)&ti);
tooltip_active = TRUE;
@@ -1122,7 +1118,7 @@ LONG_PTR CALLBACK StatusBarSubclassProc(HWND hWnd, UINT msg, WPARAM wParam, LPAR TCHAR wBuf[512];
const TCHAR *szFormat = TranslateT("There are %d pending send jobs. Message length: %d bytes, message length limit: %d bytes\n\n%d messages are queued for later delivery");
- mir_sntprintf(wBuf, safe_sizeof(wBuf), szFormat, dat->iOpenJobs, iLength, dat->nMax ? dat->nMax : 20000, iQueued);
+ mir_sntprintf(wBuf, SIZEOF(wBuf), szFormat, dat->iOpenJobs, iLength, dat->nMax ? dat->nMax : 20000, iQueued);
CallService(szTTService, (WPARAM)wBuf, (LPARAM)&ti);
}
//MAD
diff --git a/plugins/TabSRMM/src/include/controls.h b/plugins/TabSRMM/src/controls.h index 31eb0239cc..d04f589021 100644 --- a/plugins/TabSRMM/src/include/controls.h +++ b/plugins/TabSRMM/src/controls.h @@ -26,8 +26,6 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: controls.h 11635 2010-04-26 07:17:39Z silvercircle $
- *
* menu bar and status bar classes for the container window.
*
*/
diff --git a/plugins/TabSRMM/src/eventpopups.cpp b/plugins/TabSRMM/src/eventpopups.cpp index 79af801c17..362adf97b3 100644 --- a/plugins/TabSRMM/src/eventpopups.cpp +++ b/plugins/TabSRMM/src/eventpopups.cpp @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: eventpopups.cpp 13750 2011-08-03 20:10:43Z george.hazan $
- *
* This implements the event notification module for tabSRMM. The code
* is largely based on the NewEventNotify plugin for Miranda NG. See
* notices below.
@@ -41,11 +39,6 @@ */
#include "commonheaders.h"
-#pragma hdrstop
-
-extern INT_PTR CALLBACK DlgProcSetupStatusModes(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
-extern HIMAGELIST CreateStateImageList();
-extern HANDLE g_hEvent;
typedef std::vector<PLUGIN_DATAT *>::iterator PopupListIterator;
static std::vector<PLUGIN_DATAT *> PopupList;
@@ -614,7 +607,7 @@ static int PopupUpdateT(HANDLE hContact, HANDLE hEvent) if (hEvent) {
if (pdata->pluginOptions->bShowHeaders) {
- mir_sntprintf(pdata->szHeader, safe_sizeof(pdata->szHeader), _T("%s %d\n"),
+ mir_sntprintf(pdata->szHeader, SIZEOF(pdata->szHeader), _T("%s %d\n"),
TranslateT("New messages: "), pdata->nrMerged + 1);
pdata->szHeader[255] = 0;
}
@@ -808,7 +801,7 @@ void TSAPI UpdateTrayMenuState(struct TWindowData *dat, BOOL bForced) if (!bForced)
mii.dwItemData = 0;
mii.fMask |= MIIM_STRING;
- mir_sntprintf(szMenuEntry, safe_sizeof(szMenuEntry), _T("%s: %s (%s) [%d]"), tszProto, dat->cache->getNick(), dat->szStatus[0] ? dat->szStatus : _T("(undef)"), mii.dwItemData & 0x0000ffff);
+ mir_sntprintf(szMenuEntry, SIZEOF(szMenuEntry), _T("%s: %s (%s) [%d]"), tszProto, dat->cache->getNick(), dat->szStatus[0] ? dat->szStatus : _T("(undef)"), mii.dwItemData & 0x0000ffff);
mii.dwTypeData = (LPTSTR)szMenuEntry;
mii.cch = lstrlen(szMenuEntry) + 1;
}
@@ -854,7 +847,7 @@ int TSAPI UpdateTrayMenu(const TWindowData *dat, WORD wStatus, const char *szPro if (fromEvent == 2) // from chat...
mii.dwItemData |= 0x10000000;
DeleteMenu(PluginConfig.g_hMenuTrayUnread, (UINT_PTR)hContact, MF_BYCOMMAND);
- mir_sntprintf(szMenuEntry, safe_sizeof(szMenuEntry), _T("%s: %s (%s) [%d]"), tszFinalProto, szNick, szMyStatus, mii.dwItemData & 0x0000ffff);
+ mir_sntprintf(szMenuEntry, SIZEOF(szMenuEntry), _T("%s: %s (%s) [%d]"), tszFinalProto, szNick, szMyStatus, mii.dwItemData & 0x0000ffff);
AppendMenu(PluginConfig.g_hMenuTrayUnread, MF_BYCOMMAND | MF_STRING, (UINT_PTR)hContact, szMenuEntry);
PluginConfig.m_UnreadInTray++;
if (PluginConfig.m_UnreadInTray)
@@ -863,7 +856,7 @@ int TSAPI UpdateTrayMenu(const TWindowData *dat, WORD wStatus, const char *szPro } else {
szNick = (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR);
if (CheckMenuItem(PluginConfig.g_hMenuTrayUnread, (UINT_PTR)hContact, MF_BYCOMMAND | MF_UNCHECKED) == -1) {
- mir_sntprintf(szMenuEntry, safe_sizeof(szMenuEntry), _T("%s: %s (%s) [%d]"), tszFinalProto, szNick, szMyStatus, fromEvent ? 1 : 0);
+ mir_sntprintf(szMenuEntry, SIZEOF(szMenuEntry), _T("%s: %s (%s) [%d]"), tszFinalProto, szNick, szMyStatus, fromEvent ? 1 : 0);
AppendMenu(PluginConfig.g_hMenuTrayUnread, MF_BYCOMMAND | MF_STRING, (UINT_PTR)hContact, szMenuEntry);
mii.dwItemData = fromEvent ? 1 : 0;
PluginConfig.m_UnreadInTray += (mii.dwItemData & 0x0000ffff);
@@ -880,7 +873,7 @@ int TSAPI UpdateTrayMenu(const TWindowData *dat, WORD wStatus, const char *szPro mii.fMask |= MIIM_STRING;
if (fromEvent == 2)
mii.dwItemData |= 0x10000000;
- mir_sntprintf(szMenuEntry, safe_sizeof(szMenuEntry), _T("%s: %s (%s) [%d]"), tszFinalProto, szNick, szMyStatus, mii.dwItemData & 0x0000ffff);
+ mir_sntprintf(szMenuEntry, SIZEOF(szMenuEntry), _T("%s: %s (%s) [%d]"), tszFinalProto, szNick, szMyStatus, mii.dwItemData & 0x0000ffff);
mii.cch = lstrlen(szMenuEntry) + 1;
mii.dwTypeData = (LPTSTR)szMenuEntry;
}
diff --git a/plugins/TabSRMM/src/include/functions.h b/plugins/TabSRMM/src/functions.h index 8d3dabb7ba..5b440cb7aa 100644 --- a/plugins/TabSRMM/src/include/functions.h +++ b/plugins/TabSRMM/src/functions.h @@ -26,8 +26,6 @@ *
*(C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: functions.h 11636 2010-04-27 22:08:16Z silvercircle $
- *
* Global function prototypes
*
*/
diff --git a/plugins/TabSRMM/src/generic_msghandlers.cpp b/plugins/TabSRMM/src/generic_msghandlers.cpp index 90c8d5dd04..e8654cfacb 100644 --- a/plugins/TabSRMM/src/generic_msghandlers.cpp +++ b/plugins/TabSRMM/src/generic_msghandlers.cpp @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: generic_msghandlers.cpp 13587 2011-04-12 13:54:26Z george.hazan $
- *
* these are generic message handlers which are used by the message dialog window procedure.
* calling them directly instead of using SendMessage() is faster.
* also contains various callback functions for custom buttons
@@ -36,9 +34,6 @@ #include "commonheaders.h"
-extern RECT rcLastStatusBarClick;
-
-
/**
* Save message log for given session as RTF document
*/
@@ -1222,7 +1217,7 @@ LRESULT TSAPI DM_UpdateLastMessage(const TWindowData *dat) if (dat->showTyping) {
TCHAR szBuf[80];
- mir_sntprintf(szBuf, safe_sizeof(szBuf), TranslateT("%s is typing a message."), dat->cache->getNick());
+ mir_sntprintf(szBuf, SIZEOF(szBuf), TranslateT("%s is typing a message."), dat->cache->getNick());
SendMessage(dat->pContainer->hwndStatus, SB_SETTEXT, 0, (LPARAM) szBuf);
SendMessage(dat->pContainer->hwndStatus, SB_SETICON, 0, (LPARAM) PluginConfig.g_buttonBarIcons[ICON_DEFAULT_TYPING]);
return 0;
@@ -1234,18 +1229,18 @@ LRESULT TSAPI DM_UpdateLastMessage(const TWindowData *dat) TCHAR date[64], time[64];
if (!(dat->pContainer->dwFlags & CNT_UINSTATUSBAR)) {
- tmi.printTimeStamp(NULL, dat->lastMessage, _T("d"), date, safe_sizeof(date), 0);
+ tmi.printTimeStamp(NULL, dat->lastMessage, _T("d"), date, SIZEOF(date), 0);
if (dat->pContainer->dwFlags & CNT_UINSTATUSBAR && lstrlen(date) > 6)
date[lstrlen(date) - 5] = 0;
- tmi.printTimeStamp(NULL, dat->lastMessage, _T("t"), time, safe_sizeof(time), 0);
+ tmi.printTimeStamp(NULL, dat->lastMessage, _T("t"), time, SIZEOF(time), 0);
}
if (dat->pContainer->dwFlags & CNT_UINSTATUSBAR) {
TCHAR fmt[100];
- mir_sntprintf(fmt, safe_sizeof(fmt), _T("UID: %s"), dat->cache->getUIN());
+ mir_sntprintf(fmt, SIZEOF(fmt), _T("UID: %s"), dat->cache->getUIN());
SendMessage(dat->pContainer->hwndStatus, SB_SETTEXT, 0, (LPARAM)fmt);
} else {
TCHAR fmt[100];
- mir_sntprintf(fmt, safe_sizeof(fmt), TranslateT("Last received: %s at %s"), date, time);
+ mir_sntprintf(fmt, SIZEOF(fmt), TranslateT("Last received: %s at %s"), date, time);
SendMessage(dat->pContainer->hwndStatus, SB_SETTEXT, 0, (LPARAM) fmt);
}
} else
@@ -1617,7 +1612,7 @@ void TSAPI DM_Typing(TWindowData *dat, bool fForceOff) dat->showTyping = 2;
dat->nTypeSecs = 86400;
- mir_sntprintf(dat->szStatusBar, safe_sizeof(dat->szStatusBar),
+ mir_sntprintf(dat->szStatusBar, SIZEOF(dat->szStatusBar),
TranslateT("%s has entered text."), dat->cache->getNick());
if (hwndStatus && dat->pContainer->hwndActive == hwndDlg)
SendMessage(hwndStatus, SB_SETTEXT, 0, (LPARAM) dat->szStatusBar);
@@ -1643,7 +1638,7 @@ void TSAPI DM_Typing(TWindowData *dat, bool fForceOff) }
else {
if (dat->nTypeSecs > 0) {
- mir_sntprintf(dat->szStatusBar, safe_sizeof(dat->szStatusBar), TranslateT("%s is typing a message."), dat->cache->getNick());
+ mir_sntprintf(dat->szStatusBar, SIZEOF(dat->szStatusBar), TranslateT("%s is typing a message."), dat->cache->getNick());
dat->nTypeSecs--;
if (hwndStatus && dat->pContainer->hwndActive == hwndDlg) {
@@ -1854,7 +1849,7 @@ void TSAPI DM_EventAdded(TWindowData *dat, WPARAM wParam, LPARAM lParam) dat->iEventQueueSize += 10;
}
dat->hQueuedEvents[dat->iNextQueuedEvent++] = (HANDLE)lParam;
- mir_sntprintf(szBuf, safe_sizeof(szBuf), TranslateT("Autoscrolling is disabled, %d message(s) queued (press F12 to enable it)"),
+ mir_sntprintf(szBuf, SIZEOF(szBuf), TranslateT("Autoscrolling is disabled, %d message(s) queued (press F12 to enable it)"),
dat->iNextQueuedEvent);
SetDlgItemText(hwndDlg, IDC_LOGFROZENTEXT, szBuf);
RedrawWindow(GetDlgItem(hwndDlg, IDC_LOGFROZENTEXT), NULL, NULL, RDW_INVALIDATE);
@@ -2007,13 +2002,13 @@ void TSAPI DM_UpdateTitle(TWindowData *dat, WPARAM wParam, LPARAM lParam) dat->dwFlagsEx = dat->idle ? dat->dwFlagsEx | MWF_SHOW_ISIDLE : dat->dwFlagsEx & ~MWF_SHOW_ISIDLE;
dat->wStatus = dat->cache->getStatus();
- mir_sntprintf(dat->szStatus, safe_sizeof(dat->szStatus), _T("%s"), (char *) CallService(MS_CLIST_GETSTATUSMODEDESCRIPTION, dat->szProto == NULL ? ID_STATUS_OFFLINE : dat->wStatus, GSMDF_TCHAR));
+ mir_sntprintf(dat->szStatus, SIZEOF(dat->szStatus), _T("%s"), (char *) CallService(MS_CLIST_GETSTATUSMODEDESCRIPTION, dat->szProto == NULL ? ID_STATUS_OFFLINE : dat->wStatus, GSMDF_TCHAR));
if (lParam != 0) {
if (PluginConfig.m_CutContactNameOnTabs)
- CutContactName(szNick, newcontactname, safe_sizeof(newcontactname));
+ CutContactName(szNick, newcontactname, SIZEOF(newcontactname));
else
- lstrcpyn(newcontactname, szNick, safe_sizeof(newcontactname));
+ lstrcpyn(newcontactname, szNick, SIZEOF(newcontactname));
Utils::DoubleAmpersands(newcontactname);
@@ -2029,24 +2024,24 @@ void TSAPI DM_UpdateTitle(TWindowData *dat, WPARAM wParam, LPARAM lParam) }
SendMessage(hwndDlg, DM_UPDATEWINICON, 0, 0);
if (dat->bIsMeta)
- mir_sntprintf(fulluin, safe_sizeof(fulluin),
+ mir_sntprintf(fulluin, SIZEOF(fulluin),
TranslateT("UID: %s (SHIFT click -> copy to clipboard)\nClick for User's Details\nRight click for MetaContact control\nClick dropdown to add or remove user from your favorites."),
iHasName ? dat->cache->getUIN() : TranslateT("No UID"));
else
- mir_sntprintf(fulluin, safe_sizeof(fulluin),
+ mir_sntprintf(fulluin, SIZEOF(fulluin),
TranslateT("UID: %s (SHIFT click -> copy to clipboard)\nClick for User's Details\nClick dropdown to change this contact's favorite status."),
iHasName ? dat->cache->getUIN() : TranslateT("No UID"));
SendMessage(GetDlgItem(hwndDlg, IDC_NAME), BUTTONADDTOOLTIP, /*iHasName ?*/ (WPARAM)fulluin /*: (WPARAM)_T("")*/, 0);
}
} else
- lstrcpyn(newtitle, pszNewTitleEnd, safe_sizeof(newtitle));
+ lstrcpyn(newtitle, pszNewTitleEnd, SIZEOF(newtitle));
if (dat->idle != dwOldIdle || lParam != 0) {
if (item.mask & TCIF_TEXT) {
item.pszText = newtitle;
- _tcsncpy(dat->newtitle, newtitle, safe_sizeof(dat->newtitle));
+ _tcsncpy(dat->newtitle, newtitle, SIZEOF(dat->newtitle));
dat->newtitle[127] = 0;
item.cchTextMax = 127;
if (dat->pWnd)
diff --git a/plugins/TabSRMM/src/include/generic_msghandlers.h b/plugins/TabSRMM/src/generic_msghandlers.h index 4f756b24f0..4916a90c06 100644 --- a/plugins/TabSRMM/src/include/generic_msghandlers.h +++ b/plugins/TabSRMM/src/generic_msghandlers.h @@ -26,8 +26,6 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: generic_msghandlers.h 12058 2010-06-24 15:26:10Z silvercircle $
- *
* prototypes from generic_msghandlers.c
*
*/
diff --git a/plugins/TabSRMM/src/globals.cpp b/plugins/TabSRMM/src/globals.cpp index b807218b0b..b8329eb8e1 100644 --- a/plugins/TabSRMM/src/globals.cpp +++ b/plugins/TabSRMM/src/globals.cpp @@ -26,15 +26,12 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: globals.cpp 13447 2011-03-14 19:55:07Z george.hazan $
- *
* Plugin configuration variables and functions. Implemented as a class
* though there will always be only a single instance.
*
*/
#include "commonheaders.h"
-extern PLUGININFOEX pluginInfo;
CGlobals PluginConfig;
CGlobals* pConfig = &PluginConfig;
@@ -187,7 +184,7 @@ void CGlobals::reloadSystemModulesChanged() if (m_MathModAvail) {
char *szDelim = (char *)CallService(MATH_GET_STARTDELIMITER, 0, 0);
if (szDelim) {
- MultiByteToWideChar(CP_ACP, 0, szDelim, -1, PluginConfig.m_MathModStartDelimiter, safe_sizeof(PluginConfig.m_MathModStartDelimiter));
+ MultiByteToWideChar(CP_ACP, 0, szDelim, -1, PluginConfig.m_MathModStartDelimiter, SIZEOF(PluginConfig.m_MathModStartDelimiter));
CallService(MTH_FREE_MATH_BUFFER, 0, (LPARAM)szDelim);
}
}
@@ -683,7 +680,7 @@ void CGlobals::RestoreUnreadMessageAlerts(void) cle.hContact = hContact;
cle.hDbEvent = hDbEvent;
- mir_sntprintf(toolTip, safe_sizeof(toolTip), TranslateT("Message from %s"),
+ mir_sntprintf(toolTip, SIZEOF(toolTip), TranslateT("Message from %s"),
(TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM) hContact, GCDNF_TCHAR));
cle.ptszTooltip = toolTip;
CallService(MS_CLIST_ADDEVENT, 0, (LPARAM) & cle);
@@ -734,11 +731,11 @@ void CGlobals::logStatusChange(WPARAM wParam, const CContactCache *c) if (c->isValid()) {
if (wStatus == ID_STATUS_OFFLINE)
- mir_sntprintf(buffer, safe_sizeof(buffer), TranslateT("signed off."));
+ mir_sntprintf(buffer, SIZEOF(buffer), TranslateT("signed off."));
else if (wOldStatus == ID_STATUS_OFFLINE)
- mir_sntprintf(buffer, safe_sizeof(buffer), TranslateT("signed on and is now %s."), szNewStatus);
+ mir_sntprintf(buffer, SIZEOF(buffer), TranslateT("signed on and is now %s."), szNewStatus);
else
- mir_sntprintf(buffer, safe_sizeof(buffer), TranslateT("changed status from %s to %s."), szOldStatus, szNewStatus);
+ mir_sntprintf(buffer, SIZEOF(buffer), TranslateT("changed status from %s to %s."), szOldStatus, szNewStatus);
}
char *szMsg = mir_utf8encodeT(buffer);
diff --git a/plugins/TabSRMM/src/include/globals.h b/plugins/TabSRMM/src/globals.h index 071928c0af..279016b8df 100644 --- a/plugins/TabSRMM/src/include/globals.h +++ b/plugins/TabSRMM/src/globals.h @@ -26,8 +26,6 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: globals.h 13046 2010-10-28 10:02:50Z silvercircle $
- *
* Plugin configuration variables and functions. Implemented as a class
* though there will always be only a single instance.
*
diff --git a/plugins/TabSRMM/src/hotkeyhandler.cpp b/plugins/TabSRMM/src/hotkeyhandler.cpp index a66951c93e..936d1991b7 100644 --- a/plugins/TabSRMM/src/hotkeyhandler.cpp +++ b/plugins/TabSRMM/src/hotkeyhandler.cpp @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: hotkeyhandler.cpp 13596 2011-04-15 19:07:23Z george.hazan $
- *
* The hotkeyhandler is a small, invisible window which handles the following things:
a) event notify stuff, messages posted from the popups to avoid threading
@@ -40,11 +38,6 @@ */
#include "commonheaders.h"
-#pragma hdrstop
-
-extern HICON hIcons[];
-extern INT_PTR SendMessageCommand(WPARAM wParam, LPARAM lParam);
-extern INT_PTR SendMessageCommand_W(WPARAM wParam, LPARAM lParam);
static UINT WM_TASKBARCREATED;
static HANDLE hSvcHotkeyProcessor = 0;
@@ -166,7 +159,7 @@ LONG_PTR CALLBACK HotkeyHandlerDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LP switch (msg) {
case WM_CREATE:
- for (int i=0; i < safe_sizeof(_hotkeydescs); i++) {
+ for (int i=0; i < SIZEOF(_hotkeydescs); i++) {
_hotkeydescs[i].cbSize = sizeof(HOTKEYDESC);
Hotkey_Register(&_hotkeydescs[i]);
}
diff --git a/plugins/TabSRMM/src/include/version.h b/plugins/TabSRMM/src/include/version.h deleted file mode 100644 index 4390ed33dc..0000000000 --- a/plugins/TabSRMM/src/include/version.h +++ /dev/null @@ -1,15 +0,0 @@ -#define VER_PLAIN "3,1,99,8"
-#define _VER_MAJOR 3
-#define _VER_MINOR 1
-#define _VER_REVISION 99
-#define _VER_BUILD 8
-
-#if defined(_WIN64)
- #define RES_FILE_DESC "TabSRMM (Unicode) x86_amd64"
- #define ADDONS_UPDATE_URL "http://miranda-ng.org/"
- #define ADDONS_DL_URL "http://miranda-ng.org/distr/x64/Plugins/tabsrmm.zip"
-#else
- #define RES_FILE_DESC "TabSRMM (Unicode) x86"
- #define ADDONS_UPDATE_URL "http://miranda-ng.org/"
- #define ADDONS_DL_URL "http://miranda-ng.org/distr/x32/Plugins/tabsrmm.zip"
-#endif
diff --git a/plugins/TabSRMM/src/infopanel.cpp b/plugins/TabSRMM/src/infopanel.cpp index 5399a6da56..5399d5a9bb 100644 --- a/plugins/TabSRMM/src/infopanel.cpp +++ b/plugins/TabSRMM/src/infopanel.cpp @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: infopanel.cpp 12702 2010-09-16 02:36:17Z borkra $
- *
* the info area for both im and chat sessions
*/
@@ -509,7 +507,7 @@ void CInfoPanel::RenderIPUIN(const HDC hdc, RECT& rcItem) time_t diff = time(NULL) - m_dat->idle;
int i_hrs = diff / 3600;
int i_mins = (diff - i_hrs * 3600) / 60;
- mir_sntprintf(szBuf, safe_sizeof(szBuf), TranslateT("%s Idle: %dh,%02dm"), tszUin, i_hrs, i_mins);
+ mir_sntprintf(szBuf, SIZEOF(szBuf), TranslateT("%s Idle: %dh,%02dm"), tszUin, i_hrs, i_mins);
}
else _tcscpy_s (szBuf, 256, tszUin);
@@ -645,7 +643,7 @@ void CInfoPanel::Chat_RenderIPNickname(const HDC hdc, RECT& rcItem) if (m_height < DEGRADE_THRESHOLD) {
TCHAR tszText[2048];
- mir_sntprintf(tszText, safe_sizeof(tszText), TranslateT("Topic is: %s"), si->ptszTopic ? si->ptszTopic :
+ mir_sntprintf(tszText, SIZEOF(tszText), TranslateT("Topic is: %s"), si->ptszTopic ? si->ptszTopic :
TranslateT("no topic set."));
hOldFont = reinterpret_cast<HFONT>(::SelectObject(hdc, m_ipConfig.hFonts[IPFONTID_UIN]));
@@ -986,7 +984,7 @@ void CInfoPanel::showTip(UINT ctrlId, const LPARAM lParam) m_tip->show(rc, pt, m_dat->hTabIcon, m_dat->szStatus);
return;
}
- mir_sntprintf(szTitle, safe_sizeof(szTitle), TranslateT("tabSRMM Information"));
+ mir_sntprintf(szTitle, SIZEOF(szTitle), TranslateT("tabSRMM Information"));
::SendMessage(m_dat->hwndTip, TTM_UPDATETIPTEXT, 0, (LPARAM)&m_dat->ti);
::SendMessage(m_dat->hwndTip, TTM_SETMAXTIPWIDTH, 0, 350);
diff --git a/plugins/TabSRMM/src/include/infopanel.h b/plugins/TabSRMM/src/infopanel.h index a7c64e469a..86caf2b1a9 100644 --- a/plugins/TabSRMM/src/include/infopanel.h +++ b/plugins/TabSRMM/src/infopanel.h @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: infopanel.h 12396 2010-08-22 17:17:05Z silvercircle $
- *
* the info area for both im and chat sessions
*/
diff --git a/plugins/TabSRMM/src/include/m_cln_skinedit.h b/plugins/TabSRMM/src/m_cln_skinedit.h index 5ee66829c5..5ee66829c5 100644 --- a/plugins/TabSRMM/src/include/m_cln_skinedit.h +++ b/plugins/TabSRMM/src/m_cln_skinedit.h diff --git a/plugins/TabSRMM/src/mim.cpp b/plugins/TabSRMM/src/mim.cpp index b254604484..dbc529f4c5 100644 --- a/plugins/TabSRMM/src/mim.cpp +++ b/plugins/TabSRMM/src/mim.cpp @@ -26,16 +26,12 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: mim.cpp 12842 2010-09-28 04:32:57Z borkra $
- *
* wraps some parts of Miranda API
* Also, OS dependent stuff (visual styles api etc.)
*
*/
-
#include "commonheaders.h"
-extern PLUGININFOEX pluginInfo;
PITA CMimAPI::m_pfnIsThemeActive = 0;
POTD CMimAPI::m_pfnOpenThemeData = 0;
@@ -320,7 +316,7 @@ void CMimAPI::configureCustomFolders() {
m_hDataPath = FoldersRegisterCustomPathT("TabSRMM", "Data path", const_cast<TCHAR *>(getDataPath()));
m_hSkinsPath = FoldersRegisterCustomPathT("TabSRMM", "Skins root", const_cast<TCHAR *>(getSkinPath()));
- m_hAvatarsPath = FoldersRegisterCustomPathT("TabSRMM", "Saved Avatars", const_cast<TCHAR *>(getSavedAvatarPath()));
+ m_hAvatarsPath = FoldersRegisterCustomPathT("Avatars", "Saved TabSRMM avatars", const_cast<TCHAR *>(getSavedAvatarPath()));
m_hChatLogsPath = FoldersRegisterCustomPathT("TabSRMM", "Group chat logs root", const_cast<TCHAR *>(getChatLogPath()));
if (m_hDataPath)
diff --git a/plugins/TabSRMM/src/include/mim.h b/plugins/TabSRMM/src/mim.h index 30d89406e6..42beca34b2 100644 --- a/plugins/TabSRMM/src/include/mim.h +++ b/plugins/TabSRMM/src/mim.h @@ -26,8 +26,6 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: mim.h 12272 2010-08-04 08:24:08Z silvercircle $
- *
* wraps some parts of Miranda API
* Also, OS dependent stuff (visual styles api etc.)
*
diff --git a/plugins/TabSRMM/src/modplus.cpp b/plugins/TabSRMM/src/modplus.cpp index 5eb4748c79..f3430b4f28 100644 --- a/plugins/TabSRMM/src/modplus.cpp +++ b/plugins/TabSRMM/src/modplus.cpp @@ -26,8 +26,6 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: modplus.cpp 11848 2010-05-27 14:57:22Z silvercircle $
- *
* implements features of the tabSRMM "MADMOD" patch, developed by
* Mad Cluster in May 2008
*
diff --git a/plugins/TabSRMM/src/msgdialog.cpp b/plugins/TabSRMM/src/msgdialog.cpp index 1de04854b4..bb3424ad7b 100644 --- a/plugins/TabSRMM/src/msgdialog.cpp +++ b/plugins/TabSRMM/src/msgdialog.cpp @@ -26,18 +26,14 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: msgdialog.cpp 13447 2011-03-14 19:55:07Z george.hazan $
- *
* This implements the message dialog window.
*
*/
#include "commonheaders.h"
-#pragma hdrstop
#define MS_HTTPSERVER_ADDFILENAME "HTTPServer/AddFileName"
-extern TTemplateSet RTL_Active, LTR_Active;
const TCHAR* pszIDCSAVE_close = 0, *pszIDCSAVE_save = 0;
static const UINT sendControls[] = { IDC_MESSAGE, IDC_LOG };
@@ -1336,7 +1332,7 @@ INT_PTR CALLBACK DlgProcMessage(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lP if (dat->hContact && dat->szProto != NULL) {
dat->wStatus = DBGetContactSettingWord(dat->hContact, dat->szProto, "Status", ID_STATUS_OFFLINE);
- mir_sntprintf(dat->szStatus, safe_sizeof(dat->szStatus), _T("%s"), (char *) CallService(MS_CLIST_GETSTATUSMODEDESCRIPTION, dat->szProto == NULL ? ID_STATUS_OFFLINE : dat->wStatus, GSMDF_TCHAR));
+ mir_sntprintf(dat->szStatus, SIZEOF(dat->szStatus), _T("%s"), (char *) CallService(MS_CLIST_GETSTATUSMODEDESCRIPTION, dat->szProto == NULL ? ID_STATUS_OFFLINE : dat->wStatus, GSMDF_TCHAR));
} else
dat->wStatus = ID_STATUS_OFFLINE;
@@ -2672,7 +2668,7 @@ INT_PTR CALLBACK DlgProcMessage(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lP if (iIndex < SendQueue::NR_SENDJOBS) { // single sendjob timer
SendJob *job = sendQueue->getJobByIndex(iIndex);
KillTimer(hwndDlg, wParam);
- mir_sntprintf(job->szErrorMsg, safe_sizeof(job->szErrorMsg), TranslateT("Delivery failure: %s"),
+ mir_sntprintf(job->szErrorMsg, SIZEOF(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))
@@ -3498,7 +3494,7 @@ quote_from_last: if (!(pcaps & PF4_OFFLINEFILES)) {
TCHAR szBuffer[256];
- _sntprintf(szBuffer, safe_sizeof(szBuffer), TranslateT("Contact is offline and this protocol does not support sending files to offline users."));
+ _sntprintf(szBuffer, SIZEOF(szBuffer), TranslateT("Contact is offline and this protocol does not support sending files to offline users."));
SendMessage(hwndDlg, DM_ACTIVATETOOLTIP, IDC_MESSAGE, (LPARAM)szBuffer);
break;
}
diff --git a/plugins/TabSRMM/src/msgdlgutils.cpp b/plugins/TabSRMM/src/msgdlgutils.cpp index 3b394d5975..0570d4db2a 100644 --- a/plugins/TabSRMM/src/msgdlgutils.cpp +++ b/plugins/TabSRMM/src/msgdlgutils.cpp @@ -26,21 +26,11 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: msgdlgutils.cpp 13650 2011-05-30 11:53:13Z silvercircle@gmail.com $
- *
* Helper functions for the message dialog.
*
*/
#include "commonheaders.h"
-#pragma hdrstop
-
-//#include "m_MathModule.h"
-
-extern NEN_OPTIONS nen_options;
-extern LOGFONTA logfonts[MSGDLGFONTCOUNT + 2];
-extern COLORREF fontcolors[MSGDLGFONTCOUNT + 2];
-extern TTemplateSet LTR_Active, RTL_Active;
#ifndef SHVIEW_THUMBNAIL
#define SHVIEW_THUMBNAIL 0x702D
@@ -540,7 +530,7 @@ void TSAPI UpdateReadChars(const TWindowData *dat) if (dat->fInsertMode || fCaps || fNum)
lstrcat(szIndicators, _T(" | "));
- mir_sntprintf(buf, safe_sizeof(buf), _T("%s%s %d/%d"), szIndicators, dat->lcID, dat->iOpenJobs, len);
+ mir_sntprintf(buf, SIZEOF(buf), _T("%s%s %d/%d"), szIndicators, dat->lcID, dat->iOpenJobs, len);
SendMessage(dat->pContainer->hwndStatus, SB_SETTEXT, 1, (LPARAM) buf);
if (PluginConfig.m_visualMessageSizeIndicator)
InvalidateRect(dat->pContainer->hwndStatus, NULL, FALSE);
@@ -1077,48 +1067,48 @@ BOOL TSAPI DoRtfToTags(TCHAR * pszText, const TWindowData *dat) bTextHasStarted = TRUE;
bJustRemovedRTF = TRUE;
iRemoveChars = 5;
- _sntprintf(InsertThis, safe_sizeof(InsertThis), _T("\n"));
+ _sntprintf(InsertThis, SIZEOF(InsertThis), _T("\n"));
} else if (p1 == _tcsstr(p1, _T("\\endash"))) {
bTextHasStarted = bJustRemovedRTF = TRUE;
iRemoveChars = 7;
- _sntprintf(InsertThis, safe_sizeof(InsertThis), _T("%c"), 0x2013);
+ _sntprintf(InsertThis, SIZEOF(InsertThis), _T("%c"), 0x2013);
} else if (p1 == _tcsstr(p1, _T("\\emdash"))) {
bTextHasStarted = TRUE;
bJustRemovedRTF = TRUE;
iRemoveChars = 7;
- _sntprintf(InsertThis, safe_sizeof(InsertThis), _T("%c"), 0x2014);
+ _sntprintf(InsertThis, SIZEOF(InsertThis), _T("%c"), 0x2014);
} else if (p1 == _tcsstr(p1, _T("\\bullet"))) {
bTextHasStarted = TRUE;
bJustRemovedRTF = TRUE;
iRemoveChars = 7;
- _sntprintf(InsertThis, safe_sizeof(InsertThis), _T("%c"), 0x2022);
+ _sntprintf(InsertThis, SIZEOF(InsertThis), _T("%c"), 0x2022);
} else if (p1 == _tcsstr(p1, _T("\\ldblquote"))) {
bTextHasStarted = TRUE;
bJustRemovedRTF = TRUE;
iRemoveChars = 10;
- _sntprintf(InsertThis, safe_sizeof(InsertThis), _T("%c"), 0x201C);
+ _sntprintf(InsertThis, SIZEOF(InsertThis), _T("%c"), 0x201C);
} else if (p1 == _tcsstr(p1, _T("\\rdblquote"))) {
bTextHasStarted = TRUE;
bJustRemovedRTF = TRUE;
iRemoveChars = 10;
- _sntprintf(InsertThis, safe_sizeof(InsertThis), _T("%c"), 0x201D);
+ _sntprintf(InsertThis, SIZEOF(InsertThis), _T("%c"), 0x201D);
} else if (p1 == _tcsstr(p1, _T("\\lquote"))) {
bTextHasStarted = TRUE;
bJustRemovedRTF = TRUE;
iRemoveChars = 7;
- _sntprintf(InsertThis, safe_sizeof(InsertThis), _T("%c"), 0x2018);
+ _sntprintf(InsertThis, SIZEOF(InsertThis), _T("%c"), 0x2018);
} else if (p1 == _tcsstr(p1, _T("\\rquote"))) {
bTextHasStarted = TRUE;
bJustRemovedRTF = TRUE;
iRemoveChars = 7;
- _sntprintf(InsertThis, safe_sizeof(InsertThis), _T("%c"), 0x2019);
+ _sntprintf(InsertThis, SIZEOF(InsertThis), _T("%c"), 0x2019);
} else if (p1 == _tcsstr(p1, _T("\\b"))) { //bold
bTextHasStarted = TRUE;
bJustRemovedRTF = TRUE;
iRemoveChars = (p1[2] != (TCHAR) '0') ? 2 : 3;
if (!(lf.lfWeight == FW_BOLD)) { // only allow bold if the font itself isn't a bold one, otherwise just strip it..
if (dat->SendFormat)
- _sntprintf(InsertThis, safe_sizeof(InsertThis), (p1[2] != (TCHAR) '0') ? _T("[b]") : _T("[/b]"));
+ _sntprintf(InsertThis, SIZEOF(InsertThis), (p1[2] != (TCHAR) '0') ? _T("[b]") : _T("[/b]"));
}
} else if (p1 == _tcsstr(p1, _T("\\i"))) { // italics
@@ -1127,7 +1117,7 @@ BOOL TSAPI DoRtfToTags(TCHAR * pszText, const TWindowData *dat) iRemoveChars = (p1[2] != (TCHAR) '0') ? 2 : 3;
if (!lf.lfItalic) { // same as for bold
if (dat->SendFormat)
- _sntprintf(InsertThis, safe_sizeof(InsertThis), (p1[2] != (TCHAR) '0') ? _T("[i]") : _T("[/i]"));
+ _sntprintf(InsertThis, SIZEOF(InsertThis), (p1[2] != (TCHAR) '0') ? _T("[i]") : _T("[/i]"));
}
} else if (p1 == _tcsstr(p1, _T("\\strike"))) { // strike-out
@@ -1136,7 +1126,7 @@ BOOL TSAPI DoRtfToTags(TCHAR * pszText, const TWindowData *dat) iRemoveChars = (p1[7] != (TCHAR) '0') ? 7 : 8;
if (!lf.lfStrikeOut) { // same as for bold
if (dat->SendFormat)
- _sntprintf(InsertThis, safe_sizeof(InsertThis), (p1[7] != (TCHAR) '0') ? _T("[s]") : _T("[/s]"));
+ _sntprintf(InsertThis, SIZEOF(InsertThis), (p1[7] != (TCHAR) '0') ? _T("[s]") : _T("[/s]"));
}
} else if (p1 == _tcsstr(p1, _T("\\ul"))) { // underlined
@@ -1150,19 +1140,19 @@ BOOL TSAPI DoRtfToTags(TCHAR * pszText, const TWindowData *dat) iRemoveChars = 3;
if (!lf.lfUnderline) { // same as for bold
if (dat->SendFormat)
- _sntprintf(InsertThis, safe_sizeof(InsertThis), (p1[3] != (TCHAR) '0' && p1[3] != (TCHAR) 'n') ? _T("[u]") : _T("[/u]"));
+ _sntprintf(InsertThis, SIZEOF(InsertThis), (p1[3] != (TCHAR) '0' && p1[3] != (TCHAR) 'n') ? _T("[u]") : _T("[/u]"));
}
} else if (p1 == _tcsstr(p1, _T("\\tab"))) { // tab
bTextHasStarted = TRUE;
bJustRemovedRTF = TRUE;
iRemoveChars = 4;
- _sntprintf(InsertThis, safe_sizeof(InsertThis), _T("%c"), 0x09);
+ _sntprintf(InsertThis, SIZEOF(InsertThis), _T("%c"), 0x09);
} else if (p1[1] == (TCHAR) '\\' || p1[1] == (TCHAR) '{' || p1[1] == (TCHAR) '}') { // escaped characters
bTextHasStarted = TRUE;
//bJustRemovedRTF = TRUE;
iRemoveChars = 2;
- _sntprintf(InsertThis, safe_sizeof(InsertThis), _T("%c"), p1[1]);
+ _sntprintf(InsertThis, SIZEOF(InsertThis), _T("%c"), p1[1]);
} else if (p1[1] == (TCHAR) '\'') { // special character
bTextHasStarted = TRUE;
bJustRemovedRTF = FALSE;
@@ -1183,7 +1173,7 @@ BOOL TSAPI DoRtfToTags(TCHAR * pszText, const TWindowData *dat) // convert string containing char in hex format to int.
p3 = InsertThis;
iLame = _tcstol(p3, &stoppedHere, 16);
- _sntprintf(InsertThis, safe_sizeof(InsertThis), _T("%c"), (TCHAR) iLame);
+ _sntprintf(InsertThis, SIZEOF(InsertThis), _T("%c"), (TCHAR) iLame);
} else
iRemoveChars = 2;
@@ -1271,11 +1261,11 @@ void TSAPI GetMYUIN(TWindowData *dat) if (!CallService(MS_CONTACT_GETCONTACTINFO, 0, (LPARAM) & ci)) {
switch (ci.type) {
case CNFT_ASCIIZ:
- mir_sntprintf(dat->myUin, safe_sizeof(dat->myUin), _T("%s"), reinterpret_cast<TCHAR *>(ci.pszVal));
+ mir_sntprintf(dat->myUin, SIZEOF(dat->myUin), _T("%s"), reinterpret_cast<TCHAR *>(ci.pszVal));
mir_free((void*)ci.pszVal);
break;
case CNFT_DWORD:
- mir_sntprintf(dat->myUin, safe_sizeof(dat->myUin), _T("%u"), ci.dVal);
+ mir_sntprintf(dat->myUin, SIZEOF(dat->myUin), _T("%u"), ci.dVal);
break;
default:
dat->myUin[0] = 0;
@@ -1633,7 +1623,7 @@ void TSAPI GetLocaleID(TWindowData *dat, const TCHAR *szKLName) _tcsupr(szLI);
}
fLocaleNotSet = (dat->lcID[0] == 0 && dat->lcID[1] == 0);
- mir_sntprintf(dat->lcID, safe_sizeof(dat->lcID), szLI);
+ mir_sntprintf(dat->lcID, SIZEOF(dat->lcID), szLI);
GetStringTypeA(dat->lcid, CT_CTYPE2, szTest, 3, wCtype2);
pf2.cbSize = sizeof(pf2);
pf2.dwMask = PFM_RTLPARA;
@@ -2272,7 +2262,7 @@ void TSAPI GetMyNick(TWindowData *dat) if (ci.type == CNFT_ASCIIZ) {
if (lstrlen(reinterpret_cast<TCHAR *>(ci.pszVal)) < 1 || !_tcscmp(reinterpret_cast<TCHAR *>(ci.pszVal),
TranslateT("'(Unknown Contact)'"))) {
- mir_sntprintf(dat->szMyNickname, safe_sizeof(dat->szMyNickname), _T("%s"), dat->myUin[0] ? dat->myUin : TranslateT("'(Unknown Contact)'"));
+ mir_sntprintf(dat->szMyNickname, SIZEOF(dat->szMyNickname), _T("%s"), dat->myUin[0] ? dat->myUin : TranslateT("'(Unknown Contact)'"));
if (ci.pszVal) {
mir_free(ci.pszVal);
ci.pszVal = NULL;
diff --git a/plugins/TabSRMM/src/include/msgdlgutils.h b/plugins/TabSRMM/src/msgdlgutils.h index 59e349f07c..40141064a2 100644 --- a/plugins/TabSRMM/src/include/msgdlgutils.h +++ b/plugins/TabSRMM/src/msgdlgutils.h @@ -26,9 +26,6 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: msgdlgutils.h 12833 2010-09-27 23:45:55Z silvercircle $
- *
- *
*/
#ifndef _MSGDLGUTILS_H
diff --git a/plugins/TabSRMM/src/msglog.cpp b/plugins/TabSRMM/src/msglog.cpp index c8dd66df89..047476d6fe 100644 --- a/plugins/TabSRMM/src/msglog.cpp +++ b/plugins/TabSRMM/src/msglog.cpp @@ -26,21 +26,11 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: msglog.cpp 13642 2011-05-27 10:26:12Z silvercircle $
- *
* implements the richedit based message log and the template parser
*
*/
#include "commonheaders.h"
-#include <mbstring.h>
-
-#pragma hdrstop
-
-extern void ReleaseRichEditOle(IRichEditOle *ole);
-extern void ImageDataInsertBitmap(IRichEditOle *ole, HBITMAP hBm);
-extern int CacheIconToBMP(struct TLogIcon *theIcon, HICON hIcon, COLORREF backgroundColor, int sizeX, int sizeY);
-extern void DeleteCachedIcon(struct TLogIcon *theIcon);
struct TCpTable cpTable[] = {
{ 874, LPGENT("Thai") },
@@ -1619,7 +1609,7 @@ static TCHAR *Template_MakeRelativeDate(struct TWindowData *dat, HANDLE hTimeZon else
szFormat = _T("d");
- tmi.printTimeStamp(hTimeZone, check, szFormat, szResult, safe_sizeof(szResult), 0);
+ tmi.printTimeStamp(hTimeZone, check, szFormat, szResult, SIZEOF(szResult), 0);
}
return szResult;
}
diff --git a/plugins/TabSRMM/src/msgoptions.cpp b/plugins/TabSRMM/src/msgoptions.cpp index be168ccc19..77d73409db 100644 --- a/plugins/TabSRMM/src/msgoptions.cpp +++ b/plugins/TabSRMM/src/msgoptions.cpp @@ -26,28 +26,14 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: msgoptions.cpp 13750 2011-08-03 20:10:43Z george.hazan $
- *
* Implementation of the option pages
*
*/
#include "commonheaders.h"
-#pragma hdrstop
-#include <m_modernopt.h>
#define DM_GETSTATUSMASK (WM_USER + 10)
-extern INT_PTR CALLBACK DlgProcPopupOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
-extern INT_PTR CALLBACK DlgProcTabConfig(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
-extern INT_PTR CALLBACK DlgProcTemplateEditor(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
-extern INT_PTR CALLBACK DlgProcToolBar(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
-extern INT_PTR CALLBACK PlusOptionsProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
-
-extern INT_PTR CALLBACK DlgProcOptions1(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
-extern INT_PTR CALLBACK DlgProcOptions2(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
-extern INT_PTR CALLBACK DlgProcOptions3(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
-
INT_PTR CALLBACK DlgProcSetupStatusModes(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
struct FontOptionsList {
@@ -694,7 +680,7 @@ static INT_PTR CALLBACK DlgProcLogOptions(HWND hwndDlg, UINT msg, WPARAM wParam, Utils::showDlgControl(hwndDlg, IDC_EXPLAINMSGLOGSETTINGS, r == 0 ? SW_HIDE : SW_SHOW);
Utils::showDlgControl(hwndDlg, IDC_LOGOPTIONS, r == 0 ? SW_SHOW : SW_HIDE);
Utils::enableDlgControl(GetDlgItem(hwndDlg, IDC_MSGLOGDIDSPLAY),r == 0 ? FALSE : TRUE);
- for (int i=0; i < safe_sizeof(__ctrls); i++)
+ for (int i=0; i < SIZEOF(__ctrls); i++)
Utils::enableDlgControl(hwndDlg, __ctrls[i], r == 0 ? TRUE : FALSE);
return 0;
}
diff --git a/plugins/TabSRMM/src/msgoptions_plus.cpp b/plugins/TabSRMM/src/msgoptions_plus.cpp index e407f392d6..9ebb60fea0 100644 --- a/plugins/TabSRMM/src/msgoptions_plus.cpp +++ b/plugins/TabSRMM/src/msgoptions_plus.cpp @@ -26,8 +26,6 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: msgoptions_plus.cpp 13034 2010-10-24 20:39:04Z silvercircle $
- *
* implements the "advanced tweak" option page
*
* originally developed by Mad Cluster for the tabSRMM "MADMOD" patch in
@@ -37,10 +35,6 @@ #include "commonheaders.h"
-extern HINSTANCE hinstance;
-extern BOOL g_bIMGtagButton;
-extern HIMAGELIST g_himlOptions, CreateStateImageList();
-
static void FillDialog(HWND hwndDlg)
{
TVINSERTSTRUCT tvi = {0};
diff --git a/plugins/TabSRMM/src/msgs.cpp b/plugins/TabSRMM/src/msgs.cpp index 43a1ce0137..b08d31f0a9 100644 --- a/plugins/TabSRMM/src/msgs.cpp +++ b/plugins/TabSRMM/src/msgs.cpp @@ -26,32 +26,22 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: msgs.cpp 13587 2011-04-12 13:54:26Z george.hazan $
- *
* Load, setup and shutdown the plugin
* core plugin messaging services (single IM chats only).
*
*/
#include "commonheaders.h"
-#pragma hdrstop
#define IDI_CORE_LOAD 132 // icon id for the "connecting" icon
REOLECallback* mREOLECallback;
NEN_OPTIONS nen_options;
-extern PLUGININFOEX pluginInfo;
-extern HANDLE hHookToolBarLoadedEvt;
static HANDLE hUserPrefsWindowLis = 0;
HMODULE g_hIconDLL = 0;
static void UnloadIcons();
-extern INT_PTR CALLBACK DlgProcUserPrefsFrame(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
-extern struct TLogIcon msgLogIcons[NR_LOGICONS * 3];
-extern int CacheIconToBMP (struct TLogIcon *theIcon, HICON hIcon, COLORREF backgroundColor, int sizeX, int sizeY);
-extern void DeleteCachedIcon(struct TLogIcon *theIcon);
-
int Chat_IconsChanged(WPARAM wp, LPARAM lp);
void Chat_AddIcons(void);
int Chat_PreShutdown(WPARAM wParam, LPARAM lParam);
@@ -541,7 +531,7 @@ static void TSAPI InitAPI() {
ZeroMemory(PluginConfig.hSvc, sizeof(HANDLE) * CGlobals::SERVICE_LAST);
- for (int i=0; i < safe_sizeof(SERVICES); i++)
+ for (int i=0; i < SIZEOF(SERVICES); i++)
*(SERVICES[i].h) = CreateServiceFunction(SERVICES[i].szName, SERVICES[i].pfnService);
*(SERVICES[CGlobals::H_MS_MSG_SENDMESSAGEW].h) = CreateServiceFunction(MS_MSG_SENDMESSAGE "W", SendMessageCommand_W);
@@ -709,23 +699,23 @@ HWND TSAPI CreateNewTabForContact(struct TContainerData *pContainer, HANDLE hCon if (contactName && lstrlen(contactName) > 0) {
if (M->GetByte("cuttitle", 0))
- CutContactName(contactName, newcontactname, safe_sizeof(newcontactname));
+ CutContactName(contactName, newcontactname, SIZEOF(newcontactname));
else {
- lstrcpyn(newcontactname, contactName, safe_sizeof(newcontactname));
+ lstrcpyn(newcontactname, contactName, SIZEOF(newcontactname));
newcontactname[127] = 0;
}
//Mad: to fix tab width for nicknames with ampersands
Utils::DoubleAmpersands(newcontactname);
} else
- lstrcpyn(newcontactname, _T("_U_"), safe_sizeof(newcontactname));
+ lstrcpyn(newcontactname, _T("_U_"), SIZEOF(newcontactname));
WORD wStatus = (szProto == NULL ? ID_STATUS_OFFLINE : db_get_w(newData.hContact, szProto, "Status", ID_STATUS_OFFLINE));
TCHAR *szStatus = (TCHAR *) CallService(MS_CLIST_GETSTATUSMODEDESCRIPTION, szProto == NULL ? ID_STATUS_OFFLINE : db_get_w(newData.hContact, szProto, "Status", ID_STATUS_OFFLINE), GSMDF_TCHAR);
if (M->GetByte("tabstatus", 1))
- mir_sntprintf(tabtitle, safe_sizeof(tabtitle), _T("%s (%s) "), newcontactname, szStatus);
+ mir_sntprintf(tabtitle, SIZEOF(tabtitle), _T("%s (%s) "), newcontactname, szStatus);
else
- mir_sntprintf(tabtitle, safe_sizeof(tabtitle), _T("%s "), newcontactname);
+ mir_sntprintf(tabtitle, SIZEOF(tabtitle), _T("%s "), newcontactname);
newData.item.pszText = tabtitle;
newData.item.mask = TCIF_TEXT | TCIF_IMAGE | TCIF_PARAM;
diff --git a/plugins/TabSRMM/src/include/msgs.h b/plugins/TabSRMM/src/msgs.h index 13f64e33e2..3486988b96 100644 --- a/plugins/TabSRMM/src/include/msgs.h +++ b/plugins/TabSRMM/src/msgs.h @@ -26,9 +26,6 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: msgs.h 13587 2011-04-12 13:54:26Z george.hazan $
- *
- *
*/
#ifndef _MSGS_H
@@ -47,11 +44,6 @@ #define CF_TEXTT CF_UNICODETEXT
-#include <richedit.h>
-#include <richole.h>
-#include "m_avatars.h"
-#include "m_message.h"
-
#define MSGERROR_CANCEL 0
#define MSGERROR_RETRY 1
#define MSGERROR_SENDLATER 2
diff --git a/plugins/TabSRMM/src/include/nen.h b/plugins/TabSRMM/src/nen.h index 106238b320..d21f2533b6 100644 --- a/plugins/TabSRMM/src/include/nen.h +++ b/plugins/TabSRMM/src/nen.h @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: nen.h 13750 2011-08-03 20:10:43Z george.hazan $
- *
* This implements the event notification module for tabSRMM. The code
* is largely based on the NewEventNotify plugin for Miranda NG. See
* notices below for original copyright
@@ -43,9 +41,6 @@ #ifndef _NEN_H_
#define _NEN_H_
-//#include "m_popup.h"
-//#include "m_popupw.h"
-
#define MODULE "tabSRMM_NEN"
int tabSRMM_ShowPopup(WPARAM wParam, LPARAM lParam, WORD eventType, int windowOpen, struct TContainerData *pContainer, HWND hwndChild, const char *szProto, struct TWindowData *dat);
diff --git a/plugins/TabSRMM/src/include/resource.h b/plugins/TabSRMM/src/resource.h index 8008176c14..8008176c14 100644 --- a/plugins/TabSRMM/src/include/resource.h +++ b/plugins/TabSRMM/src/resource.h diff --git a/plugins/TabSRMM/src/selectcontainer.cpp b/plugins/TabSRMM/src/selectcontainer.cpp index cf5acbf816..dd9eb22145 100644 --- a/plugins/TabSRMM/src/selectcontainer.cpp +++ b/plugins/TabSRMM/src/selectcontainer.cpp @@ -26,14 +26,11 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: selectcontainer.cpp 12351 2010-08-21 21:44:54Z Michael.Kunz@s2005.TU-Chemnitz.de $
- *
* dialog to manage containers (attaching sessions to containers etc.)
*
*/
#include "commonheaders.h"
-#pragma hdrstop
INT_PTR CALLBACK SelectContainerDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam)
{
@@ -55,7 +52,7 @@ INT_PTR CALLBACK SelectContainerDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, L if (lParam) {
struct TWindowData *dat = (struct TWindowData *)GetWindowLongPtr((HWND)lParam, GWLP_USERDATA);
if (dat) {
- mir_sntprintf(szNewTitle, safe_sizeof(szNewTitle), TranslateT("Select container for %s"), dat->cache->getNick());
+ mir_sntprintf(szNewTitle, SIZEOF(szNewTitle), TranslateT("Select container for %s"), dat->cache->getNick());
SetWindowText(hwndDlg, szNewTitle);
}
}
diff --git a/plugins/TabSRMM/src/sendlater.cpp b/plugins/TabSRMM/src/sendlater.cpp index 632db61eab..4b62744ec7 100644 --- a/plugins/TabSRMM/src/sendlater.cpp +++ b/plugins/TabSRMM/src/sendlater.cpp @@ -26,13 +26,10 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: sendlater.cpp 14225 2012-05-08 19:49:18Z george.hazan $
- *
* the sendlater class implementation
*/
#include "commonheaders.h"
-#pragma hdrstop
#define U_PREF_UNICODE PREF_UNICODE
/*
diff --git a/plugins/TabSRMM/src/include/sendlater.h b/plugins/TabSRMM/src/sendlater.h index a81c08f4ae..e0d4b91ec8 100644 --- a/plugins/TabSRMM/src/include/sendlater.h +++ b/plugins/TabSRMM/src/sendlater.h @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: sendlater.h 11707 2010-05-05 13:53:11Z silvercircle $
- *
* the sendlater class
*/
diff --git a/plugins/TabSRMM/src/sendqueue.cpp b/plugins/TabSRMM/src/sendqueue.cpp index 98b36e2d06..49a095064e 100644 --- a/plugins/TabSRMM/src/sendqueue.cpp +++ b/plugins/TabSRMM/src/sendqueue.cpp @@ -26,19 +26,14 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: sendqueue.cpp 13750 2011-08-03 20:10:43Z george.hazan $
- *
* Implements a queued, asynchronous sending system for tabSRMM.
*
*/
#include "commonheaders.h"
-#pragma hdrstop
SendQueue *sendQueue = 0;
-extern const TCHAR *pszIDCSAVE_save, *pszIDCSAVE_close;
-
static char *pss_msg = "/SendMsg";
static char *pss_msgw = "/SendMsgW";
@@ -788,7 +783,7 @@ int SendQueue::ackMessage(TWindowData *dat, WPARAM wParam, LPARAM lParam) SkinPlaySound("SendError");
TCHAR *szAckMsg = mir_a2t((char *)ack->lParam);
- mir_sntprintf(m_jobs[iFound].szErrorMsg, safe_sizeof(m_jobs[iFound].szErrorMsg),
+ mir_sntprintf(m_jobs[iFound].szErrorMsg, SIZEOF(m_jobs[iFound].szErrorMsg),
TranslateT("Delivery failure: %s"), szAckMsg);
m_jobs[iFound].iStatus = SQ_ERROR;
mir_free(szAckMsg);
@@ -937,10 +932,10 @@ int SendQueue::doSendLater(int iJobIndex, TWindowData *dat, HANDLE hContact, boo _tcsftime(tszTimestamp, 30, formatTime, _localtime32((__time32_t *)&now));
tszTimestamp[29] = 0;
mir_snprintf(szKeyName, 20, "S%d", now);
- mir_sntprintf(tszHeader, safe_sizeof(tszHeader), TranslateT("\n(Sent delayed. Original timestamp %s)"), tszTimestamp);
+ mir_sntprintf(tszHeader, SIZEOF(tszHeader), TranslateT("\n(Sent delayed. Original timestamp %s)"), tszTimestamp);
}
else
- mir_sntprintf(tszHeader, safe_sizeof(tszHeader), _T("M%d|"), time(0));
+ mir_sntprintf(tszHeader, SIZEOF(tszHeader), _T("M%d|"), time(0));
if (job->dwFlags & PREF_UTF || !(job->dwFlags & PREF_UNICODE)) {
char *utf_header = mir_utf8encodeT(tszHeader);
diff --git a/plugins/TabSRMM/src/include/sendqueue.h b/plugins/TabSRMM/src/sendqueue.h index 8fdb8205d7..428ee49b32 100644 --- a/plugins/TabSRMM/src/include/sendqueue.h +++ b/plugins/TabSRMM/src/sendqueue.h @@ -19,9 +19,6 @@ 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.
-
-$Id: sendqueue.h 12065 2010-06-25 17:30:24Z silvercircle $
-
*/
#ifndef __SENDQUEUE_H
diff --git a/plugins/TabSRMM/src/sidebar.cpp b/plugins/TabSRMM/src/sidebar.cpp index cadb433190..18b045794e 100644 --- a/plugins/TabSRMM/src/sidebar.cpp +++ b/plugins/TabSRMM/src/sidebar.cpp @@ -26,18 +26,12 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: sidebar.cpp 12647 2010-09-09 22:17:49Z silvercircle $
- *
* the contact switch bar on the left (or right) side
*
*/
#include "commonheaders.h"
-extern int TSAPI TBStateConvert2Flat(int state);
-extern int TSAPI RBStateConvert2Flat(int state);
-extern void TSAPI FillTabBackground(const HDC hdc, int iStateId, const TWindowData* dat, RECT* rc);
-
TSideBarLayout CSideBar::m_layouts[CSideBar::NR_LAYOUTS] = {
{
LPGENT("Like tabs, vertical text orientation"),
diff --git a/plugins/TabSRMM/src/include/sidebar.h b/plugins/TabSRMM/src/sidebar.h index 415b96c5ac..116806b2d3 100644 --- a/plugins/TabSRMM/src/include/sidebar.h +++ b/plugins/TabSRMM/src/sidebar.h @@ -26,8 +26,6 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: sidebar.h 11744 2010-05-13 20:34:30Z silvercircle $
- *
* the contact switch bar on the left (or right) side
*
*/
diff --git a/plugins/TabSRMM/src/srmm.cpp b/plugins/TabSRMM/src/srmm.cpp index ab760a1e0e..ed6accf488 100644 --- a/plugins/TabSRMM/src/srmm.cpp +++ b/plugins/TabSRMM/src/srmm.cpp @@ -26,21 +26,12 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: srmm.cpp 13596 2011-04-15 19:07:23Z george.hazan $
- *
* plugin loading functions and global exports.
*
*/
#include "commonheaders.h"
-extern int LoadSendRecvMessageModule(void);
-extern int SplitmsgShutdown(void);
-extern void LogErrorMessage(HWND hwndDlg, struct TWindowData *dat, int i, TCHAR *szMsg);
-extern int Chat_Load(), Chat_Unload();
-extern void FreeLogFonts();
-
-
HINSTANCE g_hInst;
LOGFONT lfDefault = {0};
@@ -53,19 +44,16 @@ TIME_API tmi = {0}; PLUGININFOEX pluginInfo = {
sizeof(PLUGININFOEX),
-#ifdef __GNUWIN32__
- "TabSRMM (MINGW32)",
-#else
- "TabSRMM",
-#endif
- PLUGIN_MAKE_VERSION(_VER_MAJOR, _VER_MINOR, _VER_REVISION, _VER_BUILD),
- "IM and group chat module for Miranda NG.",
- "The Miranda developers team and contributors",
- "silvercircle _at_ gmail _dot_ com",
- "2000-2010 Miranda Project and contributors. See readme.txt for more.",
- "http://miranda-ng.org/",
+ __PLUGIN_NAME,
+ PLUGIN_MAKE_VERSION(__MAJOR_VERSION, __MINOR_VERSION, __RELEASE_NUM, __BUILD_NUM),
+ __DESCRIPTION,
+ __AUTHOR,
+ __AUTHOREMAIL,
+ __COPYRIGHT,
+ __AUTHORWEB,
UNICODE_AWARE,
- {0x6ca5f042, 0x7a7f, 0x47cc, { 0xa7, 0x15, 0xfc, 0x8c, 0x46, 0xfb, 0xf4, 0x34 }} //{6CA5F042-7A7F-47cc-A715-FC8C46FBF434}
+ // {6CA5F042-7A7F-47CC-A715-FC8C46FBF434}
+ {0x6ca5f042, 0x7a7f, 0x47cc, {0xa7, 0x15, 0xfc, 0x8c, 0x46, 0xfb, 0xf4, 0x34}}
};
BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
@@ -219,7 +207,7 @@ int _DebugPopup(HANDLE hContact, const TCHAR *fmt, ...) tn.szProto = NULL;
tn.cbSize = sizeof(tn);
- mir_sntprintf(szTitle, safe_sizeof(szTitle), TranslateT("tabSRMM Message (%s)"), (hContact != 0) ? (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR) : TranslateT("Global"));
+ mir_sntprintf(szTitle, SIZEOF(szTitle), TranslateT("tabSRMM Message (%s)"), (hContact != 0) ? (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR) : TranslateT("Global"));
tn.tszInfoTitle = szTitle;
tn.tszInfo = debug;
tn.dwInfoFlags = NIIF_INFO;
@@ -250,7 +238,7 @@ INT_PTR CALLBACK DlgProcAbout(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPar mir_snprintf(buildstr, 50, "[Build #%d]", build_nr);
}
TCHAR *szBuildstr = mir_a2t(buildstr);
- mir_sntprintf(tStr, safe_sizeof(tStr), _T("TabSRMM\n%s %d.%d.%d.%d (Unicode) %s"),
+ mir_sntprintf(tStr, SIZEOF(tStr), _T("TabSRMM\n%s %d.%d.%d.%d (Unicode) %s"),
_T("Version"), HIBYTE(HIWORD(v)), LOBYTE(HIWORD(v)), HIBYTE(LOWORD(v)), LOBYTE(LOWORD(v)),
szBuildstr);
SetDlgItemText(hwndDlg, IDC_HEADERBAR, tStr);
diff --git a/plugins/TabSRMM/src/tabctrl.cpp b/plugins/TabSRMM/src/tabctrl.cpp index d5c9b5a9f4..658584de6d 100644 --- a/plugins/TabSRMM/src/tabctrl.cpp +++ b/plugins/TabSRMM/src/tabctrl.cpp @@ -25,18 +25,14 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: tabctrl.cpp 12643 2010-09-09 03:57:16Z silvercircle $
- *
* a custom tab control, skinable, aero support, single/multi row, button
* tabs support, proper rendering for bottom row tabs and more.
*
*/
#include "commonheaders.h"
-#pragma hdrstop
static WNDPROC OldTabControlClassProc;
-extern ButtonSet g_ButtonSet;
static LRESULT CALLBACK TabControlSubclassProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam);
diff --git a/plugins/TabSRMM/src/taskbar.cpp b/plugins/TabSRMM/src/taskbar.cpp index 73f05e0172..37b7b6a746 100644 --- a/plugins/TabSRMM/src/taskbar.cpp +++ b/plugins/TabSRMM/src/taskbar.cpp @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: taskbar.cpp 13178 2010-12-05 21:29:17Z silvercircle $
- *
* Windows 7 taskbar integration
*
* - overlay icons
diff --git a/plugins/TabSRMM/src/include/taskbar.h b/plugins/TabSRMM/src/taskbar.h index 9267f6a76a..b2390bc827 100644 --- a/plugins/TabSRMM/src/include/taskbar.h +++ b/plugins/TabSRMM/src/taskbar.h @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: taskbar.h 12227 2010-07-23 16:57:25Z silvercircle $
- *
* - Windows 7 taskbar integration class
* - Proxy window class, needed to support custom aero peek tab
* thumbnails
diff --git a/plugins/TabSRMM/src/templates.cpp b/plugins/TabSRMM/src/templates.cpp index e98e222075..94b7f53425 100644 --- a/plugins/TabSRMM/src/templates.cpp +++ b/plugins/TabSRMM/src/templates.cpp @@ -26,14 +26,11 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: templates.cpp 13034 2010-10-24 20:39:04Z silvercircle $
- *
* Simple editor for the message log templates
*
*/
#include "commonheaders.h"
-#pragma hdrstop
/*
* hardcoded default set of templates for both LTR and RTL.
@@ -372,7 +369,7 @@ INT_PTR CALLBACK DlgProcTemplateEditor(HWND hwndDlg, UINT msg, WPARAM wParam, LP dat->dwFlags = MWF_LOG_ALL;
dat->dwFlags = (teInfo->rtl ? dat->dwFlags | MWF_LOG_RTL : dat->dwFlags & ~MWF_LOG_RTL);
dat->dwFlags = (iIndex == 0 || iIndex == 1) ? dat->dwFlags & ~MWF_LOG_GROUPMODE : dat->dwFlags | MWF_LOG_GROUPMODE;
- mir_sntprintf(dat->szMyNickname, safe_sizeof(dat->szMyNickname), _T("My Nickname"));
+ mir_sntprintf(dat->szMyNickname, SIZEOF(dat->szMyNickname), _T("My Nickname"));
StreamInEvents(hwndDlg, 0, 1, 1, &dbei);
SendDlgItemMessage(hwndDlg, IDC_PREVIEW, EM_SETSEL, -1, -1);
if (teInfo->changed)
diff --git a/plugins/TabSRMM/src/include/templates.h b/plugins/TabSRMM/src/templates.h index c2b84b1cbd..71b84b4ac6 100644 --- a/plugins/TabSRMM/src/include/templates.h +++ b/plugins/TabSRMM/src/templates.h @@ -20,10 +20,7 @@ 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.
-$Id: templates.h 11044 2009-12-11 09:16:30Z silvercircle $
-
templates for the message log...
-
*/
struct TemplateEditorInfo {
diff --git a/plugins/TabSRMM/src/themeio.cpp b/plugins/TabSRMM/src/themeio.cpp index b54801461e..0a0d32197a 100644 --- a/plugins/TabSRMM/src/themeio.cpp +++ b/plugins/TabSRMM/src/themeio.cpp @@ -26,22 +26,15 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: themeio.cpp 13412 2011-03-08 19:13:11Z george.hazan $
- *
* Import and export theme settings between files and the database
*
*/
#include "commonheaders.h"
-#pragma hdrstop
#define CURRENT_THEME_VERSION 5
#define THEME_COOKIE 25099837
-extern char *TemplateNames[];
-extern TTemplateSet LTR_Active, RTL_Active;
-
-
static struct _tagExtSettings {
char* szIniSection;
char* szIniName;
@@ -218,12 +211,12 @@ void TSAPI WriteThemeToINI(const TCHAR *szIniFilenameT, struct TWindowData *dat) }
def = SRMSGDEFSET_BKGCOLOUR;
- for (i=0; i < safe_sizeof(_extSettings); i++) {
+ for (i=0; i < SIZEOF(_extSettings); i++) {
WritePrivateProfileStringA(_extSettings[i].szIniSection, _extSettings[i].szIniName,
_itoa(M->GetDword(_extSettings[i].szDbModule, _extSettings[i].szDbSetting, _extSettings[i].dwDef), szBuf, 10), szIniFilename);
}
- for (i=0; i < safe_sizeof(_extSettings_v5); i++) {
+ for (i=0; i < SIZEOF(_extSettings_v5); i++) {
WritePrivateProfileStringA(_extSettings_v5[i].szIniSection, _extSettings_v5[i].szIniName,
_itoa(M->GetDword(_extSettings_v5[i].szDbModule, _extSettings_v5[i].szDbSetting, _extSettings_v5[i].dwDef), szBuf, 10), szIniFilename);
}
@@ -324,13 +317,13 @@ void TSAPI ReadThemeFromINI(const TCHAR *szIniFilenameT, TContainerData *dat, in if (dwFlags & THEME_READ_FONTS) {
COLORREF defclr;
- for (i=0; i < safe_sizeof(_extSettings); i++) {
+ for (i=0; i < SIZEOF(_extSettings); i++) {
M->WriteDword(_extSettings[i].szDbModule, _extSettings[i].szDbSetting,
GetPrivateProfileIntA(_extSettings[i].szIniSection, _extSettings[i].szIniName, _extSettings[i].dwDef, szIniFilename));
}
if (version >= 5) {
- for (i=0; i < safe_sizeof(_extSettings_v5); i++) {
+ for (i=0; i < SIZEOF(_extSettings_v5); i++) {
M->WriteDword(_extSettings_v5[i].szDbModule, _extSettings_v5[i].szDbSetting,
GetPrivateProfileIntA(_extSettings_v5[i].szIniSection, _extSettings_v5[i].szIniName, _extSettings_v5[i].dwDef, szIniFilename));
}
diff --git a/plugins/TabSRMM/src/themes.cpp b/plugins/TabSRMM/src/themes.cpp index a40902dc0d..1e49f95f38 100644 --- a/plugins/TabSRMM/src/themes.cpp +++ b/plugins/TabSRMM/src/themes.cpp @@ -26,16 +26,12 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: themes.cpp 12512 2010-08-28 22:03:43Z silvercircle $
- *
* Implements the skinning engine and most parts of the aero support in
* tabSRMM 3.x+
*
*/
#include "commonheaders.h"
-#include <stdexcept>
-#pragma hdrstop
static SKINDESC my_default_skin[] = {
IDR_SKIN_AERO, _T("tabskin_aero.png"),
@@ -2582,7 +2578,7 @@ void CSkin::extractSkinsAndLogo(bool fForceOverwrite) const m_fAeroSkinsValid = true;
try {
- for (int i = 0; i < safe_sizeof(my_default_skin); i++)
+ for (int i = 0; i < SIZEOF(my_default_skin); i++)
Utils::extractResource(g_hInst, my_default_skin[i].ulID, _T("SKIN_GLYPH"), tszBasePath, my_default_skin[i].tszName, fForceOverwrite);
}
catch(CRTException& ex) {
diff --git a/plugins/TabSRMM/src/include/themes.h b/plugins/TabSRMM/src/themes.h index ca899ffdb7..62b8efad81 100644 --- a/plugins/TabSRMM/src/include/themes.h +++ b/plugins/TabSRMM/src/themes.h @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: themes.h 11997 2010-06-14 20:12:34Z silvercircle $
- *
* The class CSkin implements the skinning engine and loads skins from
* their skin definition files (.tsk).
*
diff --git a/plugins/TabSRMM/src/translator.cpp b/plugins/TabSRMM/src/translator.cpp index 2aec8e1002..990d688dec 100644 --- a/plugins/TabSRMM/src/translator.cpp +++ b/plugins/TabSRMM/src/translator.cpp @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: translator.cpp 12999 2010-10-22 07:32:53Z silvercircle $
- *
* handle pretranslated strings
*
*/
diff --git a/plugins/TabSRMM/src/include/translator.h b/plugins/TabSRMM/src/translator.h index 61590c6b16..38f56b52b7 100644 --- a/plugins/TabSRMM/src/include/translator.h +++ b/plugins/TabSRMM/src/translator.h @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: translator.h 12299 2010-08-10 02:39:36Z silvercircle $
- *
* string handling
*
*/
diff --git a/plugins/TabSRMM/src/trayicon.cpp b/plugins/TabSRMM/src/trayicon.cpp index a653564415..48d6cb2417 100644 --- a/plugins/TabSRMM/src/trayicon.cpp +++ b/plugins/TabSRMM/src/trayicon.cpp @@ -30,15 +30,11 @@ *
* (C) 2005-2009 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: trayicon.cpp 13447 2011-03-14 19:55:07Z george.hazan $
- *
* The code that creates and animates the tray icon.
*
*/
#include "commonheaders.h"
-#pragma hdrstop
-//#include "m_toptoolbar.h"
static BOOL isAnimThreadRunning = TRUE;
static HANDLE hTrayAnimThread = 0;
@@ -244,7 +240,7 @@ void TSAPI AddContactToFavorites(HANDLE hContact, const TCHAR *szNickname, const TCHAR szFinalNick[100];
if (szNickname == NULL) {
- mir_sntprintf(szFinalNick, safe_sizeof(szFinalNick), _T("%s"), (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR));
+ mir_sntprintf(szFinalNick, SIZEOF(szFinalNick), _T("%s"), (TCHAR *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR));
}
else {
_tcsncpy(szFinalNick, szNickname, 100);
@@ -269,7 +265,7 @@ void TSAPI AddContactToFavorites(HANDLE hContact, const TCHAR *szNickname, const if (acc && acc->tszAccountName) {
mii.cbSize = sizeof(mii);
- mir_sntprintf(szMenuEntry, safe_sizeof(szMenuEntry), _T("%s: %s (%s)"), acc->tszAccountName, szFinalNick, szStatus);
+ mir_sntprintf(szMenuEntry, SIZEOF(szMenuEntry), _T("%s: %s (%s)"), acc->tszAccountName, szFinalNick, szStatus);
if (mode) {
if (hMenu == PluginConfig.g_hMenuRecent) {
if (CheckMenuItem(hMenu, (UINT_PTR)hContact, MF_BYCOMMAND | MF_UNCHECKED) == 0) {
diff --git a/plugins/TabSRMM/src/typingnotify.cpp b/plugins/TabSRMM/src/typingnotify.cpp index 6f65934041..8344486540 100644 --- a/plugins/TabSRMM/src/typingnotify.cpp +++ b/plugins/TabSRMM/src/typingnotify.cpp @@ -1,5 +1,5 @@ #include "commonheaders.h"
-#pragma hdrstop
+
HANDLE hTypingNotify;
static INT_PTR EnableDisableMenuCommand(WPARAM wParam,LPARAM lParam)
diff --git a/plugins/TabSRMM/src/include/typingnotify.h b/plugins/TabSRMM/src/typingnotify.h index 03fb9851b7..03fb9851b7 100644 --- a/plugins/TabSRMM/src/include/typingnotify.h +++ b/plugins/TabSRMM/src/typingnotify.h diff --git a/plugins/TabSRMM/src/userprefs.cpp b/plugins/TabSRMM/src/userprefs.cpp index e176f14dbd..7a99d15480 100644 --- a/plugins/TabSRMM/src/userprefs.cpp +++ b/plugins/TabSRMM/src/userprefs.cpp @@ -26,9 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: userprefs.cpp 12893 2010-10-04 06:19:57Z silvercircle $
- *
- *
* global/local message log options
* local (per user) template overrides
* view mode (ieview/default)
@@ -38,16 +35,11 @@ #include "commonheaders.h"
-#pragma hdrstop
-#include <uxtheme.h>
#define UPREF_ACTION_APPLYOPTIONS 1
#define UPREF_ACTION_REMAKELOG 2
#define UPREF_ACTION_SWITCHLOGVIEWER 4
-extern HANDLE hUserPrefsWindowList;
-extern struct TCpTable cpTable[];
-
static HWND hCpCombo;
static BOOL CALLBACK FillCpCombo(LPCTSTR str)
@@ -489,7 +481,7 @@ INT_PTR CALLBACK DlgProcUserPrefsFrame(HWND hwndDlg, UINT msg, WPARAM wParam, LP GetClientRect(hwndDlg, &rcClient);
- mir_sntprintf(szBuffer, safe_sizeof(szBuffer), TranslateT("Set messaging options for %s"),
+ mir_sntprintf(szBuffer, SIZEOF(szBuffer), TranslateT("Set messaging options for %s"),
(TCHAR *) CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR));
SetWindowText(hwndDlg, szBuffer);
diff --git a/plugins/TabSRMM/src/utils.cpp b/plugins/TabSRMM/src/utils.cpp index 34f1914e6d..741cea3ea2 100644 --- a/plugins/TabSRMM/src/utils.cpp +++ b/plugins/TabSRMM/src/utils.cpp @@ -26,14 +26,11 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: utils.cpp 13428 2011-03-10 13:15:44Z borkra $
- *
* generic utility functions
*
*/
#include "commonheaders.h"
-#include <string>
#define MWF_LOG_BBCODE 1
#define MWF_LOG_TEXTFORMAT 0x2000000
diff --git a/plugins/TabSRMM/src/include/utils.h b/plugins/TabSRMM/src/utils.h index f3918c1c87..41284bcffb 100644 --- a/plugins/TabSRMM/src/include/utils.h +++ b/plugins/TabSRMM/src/utils.h @@ -26,8 +26,6 @@ *
* (C) 2005-2010 by silvercircle _at_ gmail _dot_ com and contributors
*
- * $Id: utils.h 12833 2010-09-27 23:45:55Z silvercircle $
- *
* utility functions for TabSRMM
*
*/
diff --git a/plugins/TabSRMM/src/version.h b/plugins/TabSRMM/src/version.h new file mode 100644 index 0000000000..77e96ab0aa --- /dev/null +++ b/plugins/TabSRMM/src/version.h @@ -0,0 +1,14 @@ +#define __MAJOR_VERSION 3
+#define __MINOR_VERSION 1
+#define __RELEASE_NUM 99
+#define __BUILD_NUM 8
+
+#define __FILEVERSION_STRING __MAJOR_VERSION,__MINOR_VERSION,__RELEASE_NUM,__BUILD_NUM
+
+#define __PLUGIN_NAME "TabSRMM"
+#define __FILENAME "TabSRMM.dll"
+#define __DESCRIPTION "IM and group chat module for Miranda NG."
+#define __AUTHOR "The Miranda developers team and contributors"
+#define __AUTHOREMAIL "silvercircle@gmail.com"
+#define __AUTHORWEB "http://miranda-ng.org/"
+#define __COPYRIGHT "© 2000-2010 Miranda Project and contributors. See readme.txt for more."
|