diff options
author | George Hazan <george.hazan@gmail.com> | 2012-07-07 17:46:01 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2012-07-07 17:46:01 +0000 |
commit | 26aed6878b3c891b618eb83469de75a623e80361 (patch) | |
tree | 108f91e1dd896301e24c3a0ee0b2c90f81f78635 /src | |
parent | e02832e86a0dd5a95fb4c0db43b17c9eee87724d (diff) |
- forgotten /Core module: stdaway
git-svn-id: http://svn.miranda-ng.org/main/trunk@816 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'src')
-rw-r--r-- | src/core/modules.cpp | 6 | ||||
-rw-r--r-- | src/core/stdaway/awaymsg.cpp (renamed from src/modules/srawaymsg/awaymsg.cpp) | 13 | ||||
-rw-r--r-- | src/core/stdaway/commonheaders.cpp | 2 | ||||
-rw-r--r-- | src/core/stdaway/commonheaders.h | 93 | ||||
-rw-r--r-- | src/core/stdaway/main.cpp | 75 | ||||
-rw-r--r-- | src/core/stdaway/resource.rc | 121 | ||||
-rw-r--r-- | src/core/stdaway/sendmsg.cpp (renamed from src/modules/srawaymsg/sendmsg.cpp) | 305 | ||||
-rw-r--r-- | src/core/stdaway/stdaway_10.vcxproj | 218 | ||||
-rw-r--r-- | src/core/stdaway/stdaway_10.vcxproj.filters | 47 | ||||
-rw-r--r-- | src/core/stdaway/version.h | 14 | ||||
-rw-r--r-- | src/core/stdaway/version.rc | 38 | ||||
-rw-r--r-- | src/core/stduserinfo/contacts.cpp (renamed from src/modules/contacts/contacts.cpp) | 12 | ||||
-rw-r--r-- | src/miranda32_10.vcxproj | 9 | ||||
-rw-r--r-- | src/miranda32_10.vcxproj.filters | 15 | ||||
-rw-r--r-- | src/modules/plugins/newplugins.cpp | 9 | ||||
-rw-r--r-- | src/resource.rc | 56 |
16 files changed, 777 insertions, 256 deletions
diff --git a/src/core/modules.cpp b/src/core/modules.cpp index 462d6b27c3..423bd3471a 100644 --- a/src/core/modules.cpp +++ b/src/core/modules.cpp @@ -49,7 +49,6 @@ int LoadSkinIcons(void); int LoadSkinSounds(void);
int LoadSkinHotkeys(void);
int LoadUserInfoModule(void); // ui: user info
-int LoadAwayMsgModule(void); // ui: setting away messages
int LoadVisibilityModule(void); // ui: visibility control
int LoadCLUIModule(void); // ui: CList UI
int LoadPluginOptionsModule(void); // ui: plugin viewer
@@ -57,7 +56,6 @@ int LoadAddContactModule(void); // ui: authcontrol contacts int LoadUtilsModule(void); // ui: utils (has a few window classes, like HyperLink)
int LoadCLCModule(void); // window class: CLC control
int LoadButtonModule(void); // window class: button class
-int LoadContactsModule(void); // random: contact
int LoadFontserviceModule(void); // ui: font manager
int LoadIcoLibModule(void); // ui: icons manager
int LoadServiceModePlugin(void);
@@ -118,7 +116,6 @@ int LoadDefaultModules(void) NetlibInitSsl();
if ( LoadProtocolsModule()) return 1;
LoadDbAccounts(); // retrieves the account array from a database
- if ( LoadContactsModule()) return 1;
if ( LoadContactListModule()) return 1;
if ( LoadAddContactModule()) return 1;
if ( LoadNewPluginsModule()) return 1; // will call Load(void) on everything, clist will load first
@@ -129,11 +126,10 @@ int LoadDefaultModules(void) //order becomes less important below here
if ( LoadFindAddModule()) return 1;
- if ( LoadAwayMsgModule()) return 1;
if ( LoadIgnoreModule()) return 1;
if ( LoadVisibilityModule()) return 1;
- for (int i=1; i < 10; i++) {
+ for (int i=0; i < 11; i++) {
if ( pluginDefault[i].pImpl )
continue;
diff --git a/src/modules/srawaymsg/awaymsg.cpp b/src/core/stdaway/awaymsg.cpp index e9d80789e3..ccc0ae740c 100644 --- a/src/modules/srawaymsg/awaymsg.cpp +++ b/src/core/stdaway/awaymsg.cpp @@ -20,7 +20,8 @@ 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.
*/
-#include "..\..\core\commonheaders.h"
+
+#include "commonheaders.h"
int LoadAwayMessageSending(void);
@@ -51,10 +52,10 @@ static INT_PTR CALLBACK ReadAwayMsgDlgProc(HWND hwndDlg, UINT message, WPARAM wP {
TCHAR str[256], format[128];
- TCHAR* contactName = cli.pfnGetContactDisplayName(dat->hContact, 0);
+ TCHAR* contactName = pcli->pfnGetContactDisplayName(dat->hContact, 0);
char* szProto = (char*)CallService(MS_PROTO_GETCONTACTBASEPROTO, (WPARAM)dat->hContact, 0);
WORD dwStatus = DBGetContactSettingWord(dat->hContact, szProto, "Status", ID_STATUS_OFFLINE);
- TCHAR* status = cli.pfnGetStatusModeDescription(dwStatus, 0);
+ TCHAR* status = pcli->pfnGetStatusModeDescription(dwStatus, 0);
GetWindowText(hwndDlg, format, SIZEOF(format));
mir_sntprintf(str, SIZEOF(str), format, status, contactName);
@@ -144,10 +145,10 @@ static int AwayMsgPreBuildMenu(WPARAM wParam, LPARAM) int chatRoom = szProto ? DBGetContactSettingByte((HANDLE)wParam, szProto, "ChatRoom", 0) : 0;
if ( !chatRoom) {
int status = DBGetContactSettingWord((HANDLE)wParam, szProto, "Status", ID_STATUS_OFFLINE);
- mir_sntprintf(str, SIZEOF(str), TranslateT("Re&ad %s Message"), cli.pfnGetStatusModeDescription(status, 0));
+ mir_sntprintf(str, SIZEOF(str), TranslateT("Re&ad %s Message"), pcli->pfnGetStatusModeDescription(status, 0));
clmi.ptszName = str;
- if (CallProtoServiceInt(NULL,szProto, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_MODEMSGRECV) {
- if (CallProtoServiceInt(NULL,szProto, PS_GETCAPS, PFLAGNUM_3, 0) & Proto_Status2Flag(status)) {
+ if (CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_MODEMSGRECV) {
+ if (CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_3, 0) & Proto_Status2Flag(status)) {
clmi.flags = CMIM_FLAGS | CMIM_NAME | CMIF_NOTOFFLINE | CMIM_ICON | CMIF_TCHAR;
clmi.hIcon = LoadSkinProtoIcon(szProto, status);
} } } }
diff --git a/src/core/stdaway/commonheaders.cpp b/src/core/stdaway/commonheaders.cpp new file mode 100644 index 0000000000..95b2201163 --- /dev/null +++ b/src/core/stdaway/commonheaders.cpp @@ -0,0 +1,2 @@ +#include "commonheaders.h"
+
diff --git a/src/core/stdaway/commonheaders.h b/src/core/stdaway/commonheaders.h new file mode 100644 index 0000000000..c9ed5a65d2 --- /dev/null +++ b/src/core/stdaway/commonheaders.h @@ -0,0 +1,93 @@ +/*
+
+Miranda IM: the free IM client for Microsoft* Windows*
+
+Copyright 2000-2009 Miranda ICQ/IM project,
+all portions of this codebase are copyrighted to the people
+listed in contributors.txt.
+
+This program is free software; you can redistribute it and/or
+modify it under the terms of the GNU General Public License
+as published by the Free Software Foundation; either version 2
+of the License, or (at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+*/
+
+// to enable all 0.9.0 core functions
+#define MIRANDA_VER 0x0A00
+
+#define WINVER 0x0700
+#define _WIN32_WINNT 0x0700
+#define _WIN32_IE 0x0601
+
+#include <tchar.h>
+#include <winsock2.h>
+#include <shlobj.h>
+#include <uxtheme.h>
+#include <commctrl.h>
+#include <vssym32.h>
+
+#include <stdio.h>
+#include <time.h>
+#include <stddef.h>
+#include <process.h>
+#include <io.h>
+#include <limits.h>
+#include <string.h>
+#include <locale.h>
+#include <direct.h>
+#include <malloc.h>
+
+#include <win2k.h>
+
+#include <m_system.h>
+#include <m_system_cpp.h>
+#include <m_core.h>
+#include <newpluginapi.h>
+#include <m_database.h>
+#include <m_netlib.h>
+#include <m_clc.h>
+#include <m_clui.h>
+#include <m_crypto.h>
+#include <m_langpack.h>
+#include <m_clist.h>
+#include <m_clistint.h>
+#include <m_avatars.h>
+#include <m_button.h>
+#include <m_protosvc.h>
+#include <m_protomod.h>
+#include <m_protocols.h>
+#include <m_protoint.h>
+#include <m_plugins.h>
+#include <m_options.h>
+#include <m_skin.h>
+#include <m_contacts.h>
+#include <m_message.h>
+#include <m_userinfo.h>
+#include <m_history.h>
+#include <m_addcontact.h>
+#include <m_findadd.h>
+#include <m_file.h>
+#include <m_email.h>
+#include <m_awaymsg.h>
+#include <m_idle.h>
+#include <m_ignore.h>
+#include <m_icolib.h>
+#include <m_modernopt.h>
+#include <m_help.h>
+#include <m_timezones.h>
+
+#include "version.h"
+
+#include "../../resource.h"
+#include "../stdplug.h"
+
+extern HINSTANCE hInst;
diff --git a/src/core/stdaway/main.cpp b/src/core/stdaway/main.cpp new file mode 100644 index 0000000000..7b9b12772d --- /dev/null +++ b/src/core/stdaway/main.cpp @@ -0,0 +1,75 @@ +/*
+
+Standard away message processing module for Myranda IM
+
+Copyright (C) 2012 George Hazan
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License along
+with this program; if not, write to the Free Software Foundation, Inc.,
+51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+*/
+
+#include "commonheaders.h"
+
+int LoadAwayMsgModule(void);
+
+CLIST_INTERFACE* pcli;
+HINSTANCE hInst;
+int hLangpack;
+
+PLUGININFOEX pluginInfo = {
+ sizeof(PLUGININFOEX),
+ __PLUGIN_NAME,
+ MIRANDA_VERSION_DWORD,
+ __DESCRIPTION,
+ __AUTHOR,
+ __AUTHOREMAIL,
+ __COPYRIGHT,
+ __AUTHORWEB,
+ UNICODE_AWARE,
+ // {E58558E3-83E7-44EF-8E39-D9E0541956DF}
+ { 0xe58558e3, 0x83e7, 0x44ef, {0x8e, 0x39, 0xd9, 0xe0, 0x54, 0x19, 0x56, 0xdf}}
+};
+
+static const MUUID interfaces[] = { MIID_SRAWAY, MIID_LAST };
+
+BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
+{
+ hInst = hinstDLL;
+ return TRUE;
+}
+
+extern "C" __declspec(dllexport) PLUGININFOEX* MirandaPluginInfoEx(DWORD mirandaVersion)
+{
+ return &pluginInfo;
+}
+
+extern "C" __declspec(dllexport) const MUUID* MirandaPluginInterfaces(void)
+{
+ return interfaces;
+}
+
+extern "C" int __declspec(dllexport) Load(void)
+{
+ mir_getLP(&pluginInfo);
+
+ pcli = ( CLIST_INTERFACE* )CallService(MS_CLIST_RETRIEVE_INTERFACE, 0, (LPARAM)hInst);
+
+ LoadAwayMsgModule();
+ return 0;
+}
+
+extern "C" int __declspec(dllexport) Unload(void)
+{
+ return 0;
+}
diff --git a/src/core/stdaway/resource.rc b/src/core/stdaway/resource.rc new file mode 100644 index 0000000000..67ab10e988 --- /dev/null +++ b/src/core/stdaway/resource.rc @@ -0,0 +1,121 @@ +// Microsoft Visual C++ generated resource script.
+//
+#include "..\..\resource.h"
+
+#define APSTUDIO_READONLY_SYMBOLS
+/////////////////////////////////////////////////////////////////////////////
+//
+// Generated from the TEXTINCLUDE 2 resource.
+//
+#include <windows.h>
+#include <winres.h>
+
+/////////////////////////////////////////////////////////////////////////////
+#undef APSTUDIO_READONLY_SYMBOLS
+
+/////////////////////////////////////////////////////////////////////////////
+// English (United States) resources
+
+#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
+LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
+#pragma code_page(1252)
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Dialog
+//
+
+IDD_OPT_AWAYMSG DIALOGEX 0, 0, 263, 151
+STYLE DS_SETFONT | DS_FIXEDSYS | WS_CHILD | WS_VISIBLE
+EXSTYLE WS_EX_CONTROLPARENT
+FONT 8, "MS Shell Dlg", 0, 0, 0x1
+BEGIN
+ GROUPBOX "Status Messages",IDC_STATIC,4,5,255,142
+ COMBOBOX IDC_STATUS,12,19,240,97,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP
+ CONTROL "Do not reply to requests for this message",IDC_DONTREPLY,
+ "Button",BS_AUTOCHECKBOX | WS_TABSTOP,24,37,227,10
+ CONTROL "Do not pop up dialog asking for new message",IDC_NODIALOG,
+ "Button",BS_AUTOCHECKBOX | WS_TABSTOP,24,50,227,10
+ CONTROL "By default, use the same message as last time",IDC_USEPREVIOUS,
+ "Button",BS_AUTORADIOBUTTON,23,65,227,10
+ CONTROL "By default, use this message:",IDC_USESPECIFIC,"Button",BS_AUTORADIOBUTTON,23,78,227,10
+ EDITTEXT IDC_MSG,33,91,219,38,ES_MULTILINE | ES_AUTOVSCROLL | ES_WANTRETURN | WS_VSCROLL
+ LTEXT "Use %time% for the current time, %date% for the current date",IDC_STATIC,33,131,219,8
+END
+
+IDD_MODERNOPT_STATUS DIALOGEX 0, 0, 369, 113
+STYLE DS_SETFONT | DS_FIXEDSYS | WS_CHILD
+EXSTYLE WS_EX_CONTROLPARENT
+FONT 8, "MS Shell Dlg", 0, 0, 0x0
+BEGIN
+ COMBOBOX IDC_STATUS,2,54,16,97,CBS_DROPDOWNLIST | NOT WS_VISIBLE | WS_VSCROLL | WS_TABSTOP
+ CONTROL "Do not reply to requests for this message",IDC_DONTREPLY,
+ "Button",BS_AUTOCHECKBOX | NOT WS_VISIBLE | WS_TABSTOP,0,33,10,10
+ CONTROL "Do not pop up dialog asking for new message",IDC_NODIALOG,
+ "Button",BS_AUTOCHECKBOX | WS_TABSTOP,105,93,264,10
+ CONTROL "By default, use the same message as last time",IDC_USEPREVIOUS,
+ "Button",BS_AUTORADIOBUTTON,105,13,227,10
+ CONTROL "By default, use this message:",IDC_USESPECIFIC,"Button",BS_AUTORADIOBUTTON,105,26,227,10
+ EDITTEXT IDC_MSG,125,39,244,38,ES_MULTILINE | ES_AUTOVSCROLL | ES_WANTRETURN | WS_VSCROLL
+ CTEXT "Use %time% for the current time, %date% for the current date",IDC_STATIC,125,78,244,8,SS_CENTERIMAGE
+ LTEXT "Status messages:",IDC_TXT_TITLE1,0,0,246,8
+ LISTBOX IDC_LST_STATUS,10,13,90,95,LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP
+END
+
+#endif // APSTUDIO_INVOKED
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// DESIGNINFO
+//
+
+#ifdef APSTUDIO_INVOKED
+GUIDELINES DESIGNINFO
+BEGIN
+ IDD_OPT_AWAYMSG, DIALOG
+ BEGIN
+ LEFTMARGIN, 4
+ RIGHTMARGIN, 259
+ TOPMARGIN, 4
+ BOTTOMMARGIN, 147
+ END
+
+ IDD_MODERNOPT_STATUS, DIALOG
+ BEGIN
+ VERTGUIDE, 10
+ VERTGUIDE, 100
+ VERTGUIDE, 105
+ VERTGUIDE, 218
+ BOTTOMMARGIN, 103
+ HORZGUIDE, 8
+ HORZGUIDE, 13
+ END
+END
+#endif // APSTUDIO_INVOKED
+
+
+#ifdef APSTUDIO_INVOKED
+/////////////////////////////////////////////////////////////////////////////
+//
+// TEXTINCLUDE
+//
+
+1 TEXTINCLUDE
+BEGIN
+ "..\..\resource.h\0"
+END
+
+2 TEXTINCLUDE
+BEGIN
+ "#include <windows.h>\r\n"
+ "#include <winres.h>\r\n"
+ "\0"
+END
+
+3 TEXTINCLUDE
+BEGIN
+ "\r\n"
+ "\0"
+END
+
+#endif // APSTUDIO_INVOKED
diff --git a/src/modules/srawaymsg/sendmsg.cpp b/src/core/stdaway/sendmsg.cpp index 56649c5297..721a99af9b 100644 --- a/src/modules/srawaymsg/sendmsg.cpp +++ b/src/core/stdaway/sendmsg.cpp @@ -20,13 +20,23 @@ 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.
*/
-#include "..\..\core\commonheaders.h"
-extern bool prochotkey;
+#include "commonheaders.h"
+
static DWORD protoModeMsgFlags;
static HWND hwndStatusMsg;
+static bool Proto_IsAccountEnabled(PROTOACCOUNT* pa)
+{
+ return pa && ((pa->bIsEnabled && !pa->bDynDisabled) || pa->bOldProto);
+}
+
+static bool Proto_IsAccountLocked(PROTOACCOUNT* pa)
+{
+ return pa && DBGetContactSettingByte(NULL, pa->szModuleName, "LockMainStatus", 0) != 0;
+}
+
static const TCHAR *GetDefaultMessage(int status)
{
switch(status) {
@@ -69,38 +79,44 @@ static const char *StatusModeToDbSetting(int status, const char *suffix) return str;
}
+static bool GetStatusModeByte(int status, const char *suffix)
+{
+ return db_get_b(NULL, "SRAway", StatusModeToDbSetting(status, suffix), 0) != 0;
+}
+
+static void SetStatusModeByte(int status, const char *suffix, BYTE value)
+{
+ db_set_b(NULL, "SRAway", StatusModeToDbSetting(status, suffix), value);
+}
+
static TCHAR* GetAwayMessage(int statusMode, char *szProto)
{
- DBVARIANT dbv;
-
- if (szProto && !(CallProtoServiceInt(NULL,szProto, PS_GETCAPS, PFLAGNUM_3, 0) & Proto_Status2Flag(statusMode)))
+ if (szProto && !(CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_3, 0) & Proto_Status2Flag(statusMode)))
return NULL;
- if (DBGetContactSettingByte(NULL, "SRAway", StatusModeToDbSetting(statusMode, "Ignore"), 0))
+ if ( GetStatusModeByte(statusMode, "Ignore"))
return NULL;
- if (DBGetContactSettingByte(NULL, "SRAway", StatusModeToDbSetting(statusMode, "UsePrev"), 0))
- {
- if (DBGetContactSettingTString(NULL, "SRAway", StatusModeToDbSetting(statusMode, "Msg"), &dbv))
+ DBVARIANT dbv;
+ if ( GetStatusModeByte(statusMode, "UsePrev")) {
+ if ( DBGetContactSettingTString(NULL, "SRAway", StatusModeToDbSetting(statusMode, "Msg"), &dbv))
dbv.ptszVal = mir_tstrdup(GetDefaultMessage(statusMode));
}
else {
- int i;
- TCHAR substituteStr[128];
- if (DBGetContactSettingTString(NULL, "SRAway", StatusModeToDbSetting(statusMode, "Default"), &dbv))
+ if ( DBGetContactSettingTString(NULL, "SRAway", StatusModeToDbSetting(statusMode, "Default"), &dbv))
dbv.ptszVal = mir_tstrdup(GetDefaultMessage(statusMode));
- for (i=0; dbv.ptszVal[i]; i++)
- {
- if (dbv.ptszVal[i] != '%') continue;
- if ( !_tcsnicmp(dbv.ptszVal + i, _T("%time%"), 6))
- {
+ for (int i=0; dbv.ptszVal[i]; i++) {
+ if (dbv.ptszVal[i] != '%')
+ continue;
+
+ TCHAR substituteStr[128];
+ if ( !_tcsnicmp(dbv.ptszVal + i, _T("%time%"), 6)) {
MIRANDA_IDLE_INFO mii = {0};
mii.cbSize = sizeof(mii);
CallService(MS_IDLE_GETIDLEINFO, 0, (LPARAM)&mii);
- if (mii.idleType == 1)
- {
+ if (mii.idleType == 1) {
int mm;
SYSTEMTIME t;
GetLocalTime(&t);
@@ -115,6 +131,7 @@ static TCHAR* GetAwayMessage(int statusMode, char *szProto) else if ( !_tcsnicmp(dbv.ptszVal + i, _T("%date%"), 6))
GetDateFormat(LOCALE_USER_DEFAULT, DATE_SHORTDATE, NULL, NULL, substituteStr, SIZEOF(substituteStr));
else continue;
+
if (lstrlen(substituteStr) > 6)
dbv.ptszVal = (TCHAR*)mir_realloc(dbv.ptszVal, (lstrlen(dbv.ptszVal) + 1 + lstrlen(substituteStr) - 6) * sizeof(TCHAR));
MoveMemory(dbv.ptszVal + i + lstrlen(substituteStr), dbv.ptszVal + i + 6, (lstrlen(dbv.ptszVal) - i - 5) * sizeof(TCHAR));
@@ -170,19 +187,21 @@ static LRESULT CALLBACK MessageEditSubclassProc(HWND hwnd, UINT msg, WPARAM wPar void ChangeAllProtoMessages(char *szProto, int statusMode, TCHAR *msg)
{
- if (szProto == NULL)
- {
- for (int i=0; i < accounts.getCount(); i++)
+ if (szProto == NULL) {
+ int nAccounts;
+ PROTOACCOUNT** accounts;
+ ProtoEnumAccounts(&nAccounts, &accounts);
+
+ for (int i=0; i < nAccounts; i++)
{
PROTOACCOUNT* pa = accounts[i];
if ( !Proto_IsAccountEnabled(pa)) continue;
- if ((CallProtoServiceInt(NULL,pa->szModuleName, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_MODEMSGSEND) &&
+ if ((CallProtoService(pa->szModuleName, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_MODEMSGSEND) &&
!Proto_IsAccountLocked(pa))
- CallProtoServiceInt(NULL,pa->szModuleName, PS_SETAWAYMSGT, statusMode, (LPARAM)msg);
+ CallProtoService(pa->szModuleName, PS_SETAWAYMSGT, statusMode, (LPARAM)msg);
}
}
- else
- CallProtoServiceInt(NULL,szProto, PS_SETAWAYMSGT, statusMode, (LPARAM)msg);
+ else CallProtoService(szProto, PS_SETAWAYMSGT, statusMode, (LPARAM)msg);
}
struct SetAwayMsgData
@@ -205,8 +224,7 @@ static INT_PTR CALLBACK SetAwayMsgDlgProc(HWND hwndDlg, UINT message, WPARAM wPa {
SetAwayMsgData* dat = (SetAwayMsgData*)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
- switch(message)
- {
+ switch(message) {
case WM_INITDIALOG:
{
SetAwasMsgNewData *newdat = (SetAwasMsgNewData*)lParam;
@@ -221,7 +239,7 @@ static INT_PTR CALLBACK SetAwayMsgDlgProc(HWND hwndDlg, UINT message, WPARAM wPa {
TCHAR str[256], format[128];
GetWindowText(hwndDlg, format, SIZEOF(format));
- mir_sntprintf(str, SIZEOF(str), format, cli.pfnGetStatusModeDescription(dat->statusMode, 0));
+ mir_sntprintf(str, SIZEOF(str), format, pcli->pfnGetStatusModeDescription(dat->statusMode, 0));
SetWindowText(hwndDlg, str);
}
GetDlgItemText(hwndDlg, IDOK, dat->okButtonFormat, SIZEOF(dat->okButtonFormat));
@@ -240,14 +258,12 @@ static INT_PTR CALLBACK SetAwayMsgDlgProc(HWND hwndDlg, UINT message, WPARAM wPa return TRUE;
case WM_TIMER:
- if (--dat->countdown >= 0)
- {
- TCHAR str[64];
+ if (--dat->countdown >= 0) {
+ TCHAR str[64];
mir_sntprintf(str, SIZEOF(str), dat->okButtonFormat, dat->countdown);
SetDlgItemText(hwndDlg, IDOK, str);
}
- else
- {
+ else {
KillTimer(hwndDlg, 1);
PostMessage(hwndDlg, WM_CLOSE, 0, 0);
}
@@ -263,24 +279,20 @@ static INT_PTR CALLBACK SetAwayMsgDlgProc(HWND hwndDlg, UINT message, WPARAM wPa break;
case WM_COMMAND:
- switch(LOWORD(wParam))
- {
+ switch(LOWORD(wParam)) {
case IDOK:
- if (dat->countdown < 0)
- {
+ if (dat->countdown < 0) {
TCHAR str[1024];
GetDlgItemText(hwndDlg, IDC_MSG, str, SIZEOF(str));
ChangeAllProtoMessages(dat->szProto, dat->statusMode, str);
DBWriteContactSettingTString(NULL, "SRAway", StatusModeToDbSetting(dat->statusMode, "Msg"), str);
DestroyWindow(hwndDlg);
}
- else
- PostMessage(hwndDlg, WM_CLOSE, 0, 0);
+ else PostMessage(hwndDlg, WM_CLOSE, 0, 0);
break;
case IDC_MSG:
- if (dat->countdown >= 0)
- {
+ if (dat->countdown >= 0) {
KillTimer(hwndDlg, 1);
SetDlgItemText(hwndDlg, IDOK, TranslateT("OK"));
dat->countdown = -1;
@@ -323,19 +335,16 @@ static int StatusModeChange(WPARAM wParam, LPARAM lParam) else
{
// If its a single protocol check the PFLAGNUM_3 for the single protocol
- if ( !(CallProtoServiceInt(NULL,szProto, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_MODEMSGSEND) ||
- !(CallProtoServiceInt(NULL,szProto, PS_GETCAPS, PFLAGNUM_3, 0) & Proto_Status2Flag(statusMode)))
+ if ( !(CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_MODEMSGSEND) ||
+ !(CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_3, 0) & Proto_Status2Flag(statusMode)))
return 0;
}
SystemParametersInfo(SPI_GETSCREENSAVERRUNNING, 0, &bScreenSaverRunning, FALSE);
- if (DBGetContactSettingByte(NULL, "SRAway", StatusModeToDbSetting(statusMode, "Ignore"), 0))
- {
+ if (GetStatusModeByte(statusMode, "Ignore"))
ChangeAllProtoMessages(szProto, statusMode, NULL);
- }
- else if (bScreenSaverRunning || (( !GetAsyncKeyState(VK_CONTROL) || prochotkey) &&
- DBGetContactSettingByte(NULL, "SRAway", StatusModeToDbSetting(statusMode, "NoDlg"), 0)))
- {
+
+ else if (bScreenSaverRunning || ( !GetAsyncKeyState(VK_CONTROL) && GetStatusModeByte(statusMode, "NoDlg"))) {
TCHAR *msg = GetAwayMessage(statusMode, szProto);
ChangeAllProtoMessages(szProto, statusMode, msg);
mir_free(msg);
@@ -373,42 +382,34 @@ struct AwayMsgDlgData static INT_PTR CALLBACK DlgProcAwayMsgOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam)
{
- struct AwayMsgDlgData *dat;
-
+ AwayMsgDlgData *dat = (AwayMsgDlgData*)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
HWND hLst = GetDlgItem(hwndDlg, IDC_LST_STATUS);
- dat = (struct AwayMsgDlgData*)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
- switch (msg)
- {
- case WM_INITDIALOG:
+ switch (msg) {
+ case WM_INITDIALOG:
+ TranslateDialogDefault(hwndDlg);
{
- TranslateDialogDefault(hwndDlg);
dat = (AwayMsgDlgData*)mir_alloc(sizeof(AwayMsgDlgData));
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, (LONG_PTR)dat);
dat->oldPage = -1;
for (int i=0; i < SIZEOF(statusModes); i++)
{
- int j;
if ( !(protoModeMsgFlags & Proto_Status2Flag(statusModes[i])))
continue;
- if (hLst)
- {
- j = SendDlgItemMessage(hwndDlg, IDC_LST_STATUS, LB_ADDSTRING, 0, (LPARAM)cli.pfnGetStatusModeDescription(statusModes[i], 0));
+ int j;
+ if (hLst) {
+ j = SendDlgItemMessage(hwndDlg, IDC_LST_STATUS, LB_ADDSTRING, 0, (LPARAM)pcli->pfnGetStatusModeDescription(statusModes[i], 0));
SendDlgItemMessage(hwndDlg, IDC_LST_STATUS, LB_SETITEMDATA, j, statusModes[i]);
}
- else
- {
- j = SendDlgItemMessage(hwndDlg, IDC_STATUS, CB_ADDSTRING, 0, (LPARAM)cli.pfnGetStatusModeDescription(statusModes[i], 0));
+ else {
+ j = SendDlgItemMessage(hwndDlg, IDC_STATUS, CB_ADDSTRING, 0, (LPARAM)pcli->pfnGetStatusModeDescription(statusModes[i], 0));
SendDlgItemMessage(hwndDlg, IDC_STATUS, CB_SETITEMDATA, j, statusModes[i]);
}
- dat->info[j].ignore = DBGetContactSettingByte(NULL, "SRAway",
- StatusModeToDbSetting(statusModes[i], "Ignore"), 0);
- dat->info[j].noDialog = DBGetContactSettingByte(NULL, "SRAway",
- StatusModeToDbSetting(statusModes[i], "NoDlg"), 0);
- dat->info[j].usePrevious = DBGetContactSettingByte(NULL, "SRAway",
- StatusModeToDbSetting(statusModes[i], "UsePrev"), 0);
+ dat->info[j].ignore = GetStatusModeByte(statusModes[i], "Ignore");
+ dat->info[j].noDialog = GetStatusModeByte(statusModes[i], "NoDlg");
+ dat->info[j].usePrevious = GetStatusModeByte(statusModes[i], "UsePrev");
DBVARIANT dbv;
if (DBGetContactSettingTString(NULL, "SRAway", StatusModeToDbSetting(statusModes[i], "Default"), &dbv))
@@ -422,16 +423,17 @@ static INT_PTR CALLBACK DlgProcAwayMsgOpts(HWND hwndDlg, UINT msg, WPARAM wParam else
SendDlgItemMessage(hwndDlg, IDC_STATUS, CB_SETCURSEL, 0, 0);
SendMessage(hwndDlg, WM_COMMAND, hLst ? MAKEWPARAM(IDC_LST_STATUS, LBN_SELCHANGE) : MAKEWPARAM(IDC_STATUS, CBN_SELCHANGE), 0);
- return TRUE;
}
- case WM_MEASUREITEM:
+ return TRUE;
+
+ case WM_MEASUREITEM:
{
LPMEASUREITEMSTRUCT mis = (LPMEASUREITEMSTRUCT)lParam;
if (mis->CtlID == IDC_LST_STATUS)
mis->itemHeight = 20;
break;
}
- case WM_DRAWITEM:
+ case WM_DRAWITEM:
{
LPDRAWITEMSTRUCT dis = (LPDRAWITEMSTRUCT)lParam;
if (dis->CtlID != IDC_LST_STATUS) break;
@@ -440,13 +442,11 @@ static INT_PTR CALLBACK DlgProcAwayMsgOpts(HWND hwndDlg, UINT msg, WPARAM wParam TCHAR buf[128];
SendDlgItemMessage(hwndDlg, IDC_LST_STATUS, LB_GETTEXT, dis->itemID, (LPARAM)buf);
- if (dis->itemState & (ODS_SELECTED|ODS_FOCUS))
- {
+ if (dis->itemState & (ODS_SELECTED|ODS_FOCUS)) {
FillRect(dis->hDC, &dis->rcItem, GetSysColorBrush(COLOR_HIGHLIGHT));
SetTextColor(dis->hDC, GetSysColor(COLOR_HIGHLIGHTTEXT));
}
- else
- {
+ else {
FillRect(dis->hDC, &dis->rcItem, GetSysColorBrush(COLOR_WINDOW));
SetTextColor(dis->hDC, GetSysColor(COLOR_WINDOWTEXT));
}
@@ -458,83 +458,77 @@ static INT_PTR CALLBACK DlgProcAwayMsgOpts(HWND hwndDlg, UINT msg, WPARAM wParam DrawText(dis->hDC, buf, -1, &rc, DT_LEFT | DT_SINGLELINE | DT_VCENTER | DT_NOPREFIX);
break;
}
- case WM_COMMAND:
- switch(LOWORD(wParam))
- {
- case IDC_LST_STATUS:
- case IDC_STATUS:
- if ((HIWORD(wParam) == CBN_SELCHANGE) || (HIWORD(wParam) == LBN_SELCHANGE))
- {
- int i = hLst ?
- SendDlgItemMessage(hwndDlg, IDC_LST_STATUS, LB_GETCURSEL, 0, 0) :
- SendDlgItemMessage(hwndDlg, IDC_STATUS, CB_GETCURSEL, 0, 0);
- if (dat->oldPage != -1)
- {
- dat->info[dat->oldPage].ignore = IsDlgButtonChecked(hwndDlg, IDC_DONTREPLY);
- dat->info[dat->oldPage].noDialog = IsDlgButtonChecked(hwndDlg, IDC_NODIALOG);
- dat->info[dat->oldPage].usePrevious = IsDlgButtonChecked(hwndDlg, IDC_USEPREVIOUS);
- GetDlgItemText(hwndDlg, IDC_MSG, dat->info[dat->oldPage].msg, SIZEOF(dat->info[dat->oldPage].msg));
- }
- CheckDlgButton(hwndDlg, IDC_DONTREPLY, i < 0 ? 0 : dat->info[i].ignore);
- CheckDlgButton(hwndDlg, IDC_NODIALOG, i < 0 ? 0 : dat->info[i].noDialog);
- CheckDlgButton(hwndDlg, IDC_USEPREVIOUS, i < 0 ? 0 : dat->info[i].usePrevious);
- CheckDlgButton(hwndDlg, IDC_USESPECIFIC, i < 0 ? 0 : !dat->info[i].usePrevious);
-
- SetDlgItemText(hwndDlg, IDC_MSG, i < 0 ? _T("") : dat->info[i].msg);
-
- EnableWindow(GetDlgItem(hwndDlg, IDC_NODIALOG), i < 0 ? 0 : !dat->info[i].ignore);
- EnableWindow(GetDlgItem(hwndDlg, IDC_USEPREVIOUS), i < 0 ? 0 : !dat->info[i].ignore);
- EnableWindow(GetDlgItem(hwndDlg, IDC_USESPECIFIC), i < 0 ? 0 : !dat->info[i].ignore);
- EnableWindow(GetDlgItem(hwndDlg, IDC_MSG), i < 0 ? 0 : !(dat->info[i].ignore || dat->info[i].usePrevious));
- dat->oldPage = i;
- }
- return 0;
+ case WM_COMMAND:
+ switch(LOWORD(wParam)) {
+ case IDC_LST_STATUS:
+ case IDC_STATUS:
+ if ((HIWORD(wParam) == CBN_SELCHANGE) || (HIWORD(wParam) == LBN_SELCHANGE)) {
+ int i = hLst ?
+ SendDlgItemMessage(hwndDlg, IDC_LST_STATUS, LB_GETCURSEL, 0, 0) :
+ SendDlgItemMessage(hwndDlg, IDC_STATUS, CB_GETCURSEL, 0, 0);
+ if (dat->oldPage != -1) {
+ dat->info[dat->oldPage].ignore = IsDlgButtonChecked(hwndDlg, IDC_DONTREPLY);
+ dat->info[dat->oldPage].noDialog = IsDlgButtonChecked(hwndDlg, IDC_NODIALOG);
+ dat->info[dat->oldPage].usePrevious = IsDlgButtonChecked(hwndDlg, IDC_USEPREVIOUS);
+ GetDlgItemText(hwndDlg, IDC_MSG, dat->info[dat->oldPage].msg, SIZEOF(dat->info[dat->oldPage].msg));
+ }
+ CheckDlgButton(hwndDlg, IDC_DONTREPLY, i < 0 ? 0 : dat->info[i].ignore);
+ CheckDlgButton(hwndDlg, IDC_NODIALOG, i < 0 ? 0 : dat->info[i].noDialog);
+ CheckDlgButton(hwndDlg, IDC_USEPREVIOUS, i < 0 ? 0 : dat->info[i].usePrevious);
+ CheckDlgButton(hwndDlg, IDC_USESPECIFIC, i < 0 ? 0 : !dat->info[i].usePrevious);
+
+ SetDlgItemText(hwndDlg, IDC_MSG, i < 0 ? _T("") : dat->info[i].msg);
+
+ EnableWindow(GetDlgItem(hwndDlg, IDC_NODIALOG), i < 0 ? 0 : !dat->info[i].ignore);
+ EnableWindow(GetDlgItem(hwndDlg, IDC_USEPREVIOUS), i < 0 ? 0 : !dat->info[i].ignore);
+ EnableWindow(GetDlgItem(hwndDlg, IDC_USESPECIFIC), i < 0 ? 0 : !dat->info[i].ignore);
+ EnableWindow(GetDlgItem(hwndDlg, IDC_MSG), i < 0 ? 0 : !(dat->info[i].ignore || dat->info[i].usePrevious));
+ dat->oldPage = i;
+ }
+ return 0;
- case IDC_DONTREPLY:
- case IDC_USEPREVIOUS:
- case IDC_USESPECIFIC:
- SendMessage(hwndDlg, WM_COMMAND, MAKEWPARAM(IDC_STATUS, CBN_SELCHANGE), 0);
- break;
+ case IDC_DONTREPLY:
+ case IDC_USEPREVIOUS:
+ case IDC_USESPECIFIC:
+ SendMessage(hwndDlg, WM_COMMAND, MAKEWPARAM(IDC_STATUS, CBN_SELCHANGE), 0);
+ break;
- case IDC_MSG:
- if (HIWORD(wParam) != EN_CHANGE || (HWND)lParam != GetFocus()) return 0;
- break;
- }
- SendMessage(GetParent(hwndDlg), PSM_CHANGED, 0, 0);
+ case IDC_MSG:
+ if (HIWORD(wParam) != EN_CHANGE || (HWND)lParam != GetFocus())
+ return 0;
break;
+ }
+ SendMessage(GetParent(hwndDlg), PSM_CHANGED, 0, 0);
+ break;
- case WM_NOTIFY:
- switch(((LPNMHDR)lParam)->idFrom)
- {
- case 0:
- switch(((LPNMHDR)lParam)->code)
- {
- case PSN_APPLY:
- { int i, status;
- SendMessage(hwndDlg, WM_COMMAND, MAKEWPARAM(IDC_STATUS, CBN_SELCHANGE), 0);
- i = hLst ?
- (SendDlgItemMessage(hwndDlg, IDC_LST_STATUS, LB_GETCOUNT, 0, 0) - 1) :
- (SendDlgItemMessage(hwndDlg, IDC_STATUS, CB_GETCOUNT, 0, 0) - 1);
- for (; i>=0; i--)
- {
- status = hLst ?
- SendDlgItemMessage(hwndDlg, IDC_LST_STATUS, LB_GETITEMDATA, i, 0):
- SendDlgItemMessage(hwndDlg, IDC_STATUS, CB_GETITEMDATA, i, 0);
- DBWriteContactSettingByte(NULL, "SRAway", StatusModeToDbSetting(status, "Ignore"), (BYTE)dat->info[i].ignore);
- DBWriteContactSettingByte(NULL, "SRAway", StatusModeToDbSetting(status, "NoDlg"), (BYTE)dat->info[i].noDialog);
- DBWriteContactSettingByte(NULL, "SRAway", StatusModeToDbSetting(status, "UsePrev"), (BYTE)dat->info[i].usePrevious);
- DBWriteContactSettingTString(NULL, "SRAway", StatusModeToDbSetting(status, "Default"), dat->info[i].msg);
- }
- return TRUE;
- }
+ case WM_NOTIFY:
+ switch(((LPNMHDR)lParam)->idFrom) {
+ case 0:
+ switch(((LPNMHDR)lParam)->code) {
+ case PSN_APPLY:
+ SendMessage(hwndDlg, WM_COMMAND, MAKEWPARAM(IDC_STATUS, CBN_SELCHANGE), 0);
+ {
+ int i = hLst ? (SendDlgItemMessage(hwndDlg, IDC_LST_STATUS, LB_GETCOUNT, 0, 0) - 1) :
+ (SendDlgItemMessage(hwndDlg, IDC_STATUS, CB_GETCOUNT, 0, 0) - 1);
+ for (; i >= 0; i--) {
+ int status = hLst ?
+ SendDlgItemMessage(hwndDlg, IDC_LST_STATUS, LB_GETITEMDATA, i, 0):
+ SendDlgItemMessage(hwndDlg, IDC_STATUS, CB_GETITEMDATA, i, 0);
+ SetStatusModeByte(status, "Ignore", (BYTE)dat->info[i].ignore);
+ SetStatusModeByte(status, "NoDlg", (BYTE)dat->info[i].noDialog);
+ SetStatusModeByte(status, "UsePrev", (BYTE)dat->info[i].usePrevious);
+ db_set_ts(NULL, "SRAway", StatusModeToDbSetting(status, "Default"), dat->info[i].msg);
}
- break;
+ return TRUE;
+ }
}
break;
+ }
+ break;
- case WM_DESTROY:
- mir_free(dat);
- break;
+ case WM_DESTROY:
+ mir_free(dat);
+ break;
}
return FALSE;
}
@@ -577,8 +571,6 @@ static int AwayMsgSendModernOptInit(WPARAM wParam, LPARAM) obj.iBoldControls = (int*)iBoldControls;
obj.lpzTemplate = MAKEINTRESOURCEA(IDD_MODERNOPT_STATUS);
obj.pfnDlgProc = DlgProcAwayMsgOpts;
-// obj.lpzClassicGroup = "Status";
-// obj.lpzClassicPage = "Messages";
obj.lpzHelpUrl = "http://wiki.miranda-im.org/";
CallService(MS_MODERNOPT_ADDOBJECT, wParam, (LPARAM)&obj);
return 0;
@@ -587,10 +579,15 @@ static int AwayMsgSendModernOptInit(WPARAM wParam, LPARAM) static int AwayMsgSendAccountsChanged(WPARAM, LPARAM)
{
protoModeMsgFlags = 0;
- for (int i=0; i < accounts.getCount(); i++)
- {
- if ( !Proto_IsAccountEnabled(accounts[i])) continue;
- protoModeMsgFlags |= CallProtoServiceInt(NULL,accounts[i]->szModuleName, PS_GETCAPS, PFLAGNUM_3, 0);
+
+ int nAccounts;
+ PROTOACCOUNT** accounts;
+ ProtoEnumAccounts(&nAccounts, &accounts);
+ for (int i=0; i < nAccounts; i++) {
+ if ( !Proto_IsAccountEnabled(accounts[i]))
+ continue;
+
+ protoModeMsgFlags |= CallProtoService(accounts[i]->szModuleName, PS_GETCAPS, PFLAGNUM_3, 0);
}
return 0;
@@ -626,10 +623,8 @@ int LoadAwayMessageSending(void) {
HookEvent(ME_SYSTEM_MODULESLOADED, AwayMsgSendModulesLoaded);
HookEvent(ME_PROTO_ACCLISTCHANGED, AwayMsgSendAccountsChanged);
-
-
+
CreateServiceFunction(MS_AWAYMSG_GETSTATUSMSG, sttGetAwayMessage);
CreateServiceFunction(MS_AWAYMSG_GETSTATUSMSGW, sttGetAwayMessageT);
-
return 0;
}
diff --git a/src/core/stdaway/stdaway_10.vcxproj b/src/core/stdaway/stdaway_10.vcxproj new file mode 100644 index 0000000000..ac5c17f3d0 --- /dev/null +++ b/src/core/stdaway/stdaway_10.vcxproj @@ -0,0 +1,218 @@ +<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup Label="ProjectConfigurations">
+ <ProjectConfiguration Include="Debug|Win32">
+ <Configuration>Debug</Configuration>
+ <Platform>Win32</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Debug|x64">
+ <Configuration>Debug</Configuration>
+ <Platform>x64</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Release|Win32">
+ <Configuration>Release</Configuration>
+ <Platform>Win32</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Release|x64">
+ <Configuration>Release</Configuration>
+ <Platform>x64</Platform>
+ </ProjectConfiguration>
+ </ItemGroup>
+ <PropertyGroup Label="Globals">
+ <ProjectName>stdaway</ProjectName>
+ <ProjectGuid>{C14D6E0D-810E-4599-A6E0-17298AFA0501}</ProjectGuid>
+ </PropertyGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
+ <ConfigurationType>DynamicLibrary</ConfigurationType>
+ <CharacterSet>Unicode</CharacterSet>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+ <ConfigurationType>DynamicLibrary</ConfigurationType>
+ <CharacterSet>Unicode</CharacterSet>
+ <WholeProgramOptimization>true</WholeProgramOptimization>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
+ <ConfigurationType>DynamicLibrary</ConfigurationType>
+ <CharacterSet>Unicode</CharacterSet>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+ <ConfigurationType>DynamicLibrary</ConfigurationType>
+ <CharacterSet>Unicode</CharacterSet>
+ <WholeProgramOptimization>true</WholeProgramOptimization>
+ </PropertyGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+ <ImportGroup Label="ExtensionSettings">
+ </ImportGroup>
+ <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
+ <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+ </ImportGroup>
+ <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
+ <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+ </ImportGroup>
+ <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
+ <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+ </ImportGroup>
+ <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+ <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+ </ImportGroup>
+ <PropertyGroup Label="UserMacros" />
+ <PropertyGroup>
+ <_ProjectFileVersion>10.0.40219.1</_ProjectFileVersion>
+ <OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)$(Configuration)\Core\</OutDir>
+ <IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)$(Configuration)\Obj\$(ProjectName)\</IntDir>
+ <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(SolutionDir)$(Configuration)\Core\</OutDir>
+ <IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(SolutionDir)$(Configuration)\Obj\$(ProjectName)\</IntDir>
+ <OutDir Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(SolutionDir)$(Configuration)64\Core\</OutDir>
+ <IntDir Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(SolutionDir)$(Configuration)64\Obj\$(ProjectName)\</IntDir>
+ <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(SolutionDir)$(Configuration)64\Core\</OutDir>
+ <IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(SolutionDir)$(Configuration)64\Obj\$(ProjectName)\</IntDir>
+ <IgnoreImportLibrary>true</IgnoreImportLibrary>
+ </PropertyGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+ <ClCompile>
+ <Optimization>Full</Optimization>
+ <InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
+ <FavorSizeOrSpeed>Size</FavorSizeOrSpeed>
+ <AdditionalIncludeDirectories>..\..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+ <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;ADDCONTACTPLUS_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <StringPooling>true</StringPooling>
+ <BufferSecurityCheck>false</BufferSecurityCheck>
+ <FunctionLevelLinking>true</FunctionLevelLinking>
+ <FloatingPointModel>Fast</FloatingPointModel>
+ <WarningLevel>Level3</WarningLevel>
+ <DisableSpecificWarnings>4996;%(DisableSpecificWarnings)</DisableSpecificWarnings>
+ <PrecompiledHeader>Use</PrecompiledHeader>
+ <PrecompiledHeaderFile>commonheaders.h</PrecompiledHeaderFile>
+ </ClCompile>
+ <ResourceCompile>
+ <PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <AdditionalIncludeDirectories>..\..\..\include\msapi;..\..\..\include</AdditionalIncludeDirectories>
+ </ResourceCompile>
+ <Link>
+ <AdditionalDependencies>miranda32.lib;ws2_32.lib;comctl32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+ <GenerateDebugInformation>true</GenerateDebugInformation>
+ <OptimizeReferences>true</OptimizeReferences>
+ <EnableCOMDATFolding>true</EnableCOMDATFolding>
+ <BaseAddress>0x3ae00000</BaseAddress>
+ <RandomizedBaseAddress>false</RandomizedBaseAddress>
+ <ImportLibrary>$(IntDir)$(TargetName).lib</ImportLibrary>
+ <SubSystem>Windows</SubSystem>
+ <AdditionalLibraryDirectories>$(SolutionDir)\lib</AdditionalLibraryDirectories>
+ </Link>
+ </ItemDefinitionGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
+ <ClCompile>
+ <Optimization>Disabled</Optimization>
+ <AdditionalIncludeDirectories>..\..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+ <PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;_USRDLL;ADDCONTACTPLUS_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <StringPooling>false</StringPooling>
+ <MinimalRebuild>true</MinimalRebuild>
+ <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
+ <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
+ <FunctionLevelLinking>true</FunctionLevelLinking>
+ <WarningLevel>Level3</WarningLevel>
+ <DebugInformationFormat>EditAndContinue</DebugInformationFormat>
+ <DisableSpecificWarnings>4996;%(DisableSpecificWarnings)</DisableSpecificWarnings>
+ <PrecompiledHeader>Use</PrecompiledHeader>
+ <PrecompiledHeaderFile>commonheaders.h</PrecompiledHeaderFile>
+ <ExceptionHandling>false</ExceptionHandling>
+ </ClCompile>
+ <ResourceCompile>
+ <PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <AdditionalIncludeDirectories>..\..\..\include\msapi;..\..\..\include</AdditionalIncludeDirectories>
+ </ResourceCompile>
+ <Link>
+ <AdditionalDependencies>miranda32.lib;ws2_32.lib;comctl32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+ <GenerateDebugInformation>true</GenerateDebugInformation>
+ <BaseAddress>0x3ae00000</BaseAddress>
+ <RandomizedBaseAddress>false</RandomizedBaseAddress>
+ <ImportLibrary>$(IntDir)$(TargetName).lib</ImportLibrary>
+ <SubSystem>Windows</SubSystem>
+ <AdditionalLibraryDirectories>$(SolutionDir)\lib</AdditionalLibraryDirectories>
+ </Link>
+ </ItemDefinitionGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+ <ClCompile>
+ <Optimization>Full</Optimization>
+ <InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
+ <FavorSizeOrSpeed>Size</FavorSizeOrSpeed>
+ <AdditionalIncludeDirectories>..\..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+ <PreprocessorDefinitions>WIN64;NDEBUG;_WINDOWS;_USRDLL;ADDCONTACTPLUS_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <StringPooling>true</StringPooling>
+ <BufferSecurityCheck>false</BufferSecurityCheck>
+ <FunctionLevelLinking>true</FunctionLevelLinking>
+ <FloatingPointModel>Fast</FloatingPointModel>
+ <WarningLevel>Level3</WarningLevel>
+ <DisableSpecificWarnings>4996;%(DisableSpecificWarnings)</DisableSpecificWarnings>
+ <PrecompiledHeader>Use</PrecompiledHeader>
+ <PrecompiledHeaderFile>commonheaders.h</PrecompiledHeaderFile>
+ </ClCompile>
+ <ResourceCompile>
+ <PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <AdditionalIncludeDirectories>..\..\..\include\msapi;..\..\..\include</AdditionalIncludeDirectories>
+ </ResourceCompile>
+ <Link>
+ <AdditionalDependencies>miranda64.lib;ws2_32.lib;comctl32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+ <GenerateDebugInformation>true</GenerateDebugInformation>
+ <OptimizeReferences>true</OptimizeReferences>
+ <EnableCOMDATFolding>true</EnableCOMDATFolding>
+ <BaseAddress>0x3ae00000</BaseAddress>
+ <RandomizedBaseAddress>false</RandomizedBaseAddress>
+ <ImportLibrary>$(IntDir)$(TargetName).lib</ImportLibrary>
+ <SubSystem>Windows</SubSystem>
+ <AdditionalLibraryDirectories>$(SolutionDir)\lib</AdditionalLibraryDirectories>
+ </Link>
+ </ItemDefinitionGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
+ <ClCompile>
+ <Optimization>Disabled</Optimization>
+ <AdditionalIncludeDirectories>..\..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+ <PreprocessorDefinitions>WIN64;_DEBUG;_WINDOWS;_USRDLL;ADDCONTACTPLUS_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <StringPooling>false</StringPooling>
+ <MinimalRebuild>true</MinimalRebuild>
+ <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
+ <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
+ <FunctionLevelLinking>true</FunctionLevelLinking>
+ <WarningLevel>Level3</WarningLevel>
+ <DisableSpecificWarnings>4996;%(DisableSpecificWarnings)</DisableSpecificWarnings>
+ <PrecompiledHeader>Use</PrecompiledHeader>
+ <PrecompiledHeaderFile>commonheaders.h</PrecompiledHeaderFile>
+ </ClCompile>
+ <ResourceCompile>
+ <PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <AdditionalIncludeDirectories>..\..\..\include\msapi;..\..\..\include</AdditionalIncludeDirectories>
+ </ResourceCompile>
+ <Link>
+ <AdditionalDependencies>miranda64.lib;ws2_32.lib;comctl32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+ <GenerateDebugInformation>true</GenerateDebugInformation>
+ <BaseAddress>0x3ae00000</BaseAddress>
+ <RandomizedBaseAddress>false</RandomizedBaseAddress>
+ <ImportLibrary>$(IntDir)$(TargetName).lib</ImportLibrary>
+ <SubSystem>Windows</SubSystem>
+ <AdditionalLibraryDirectories>$(SolutionDir)\lib</AdditionalLibraryDirectories>
+ </Link>
+ </ItemDefinitionGroup>
+ <ItemGroup>
+ <ClCompile Include="awaymsg.cpp" />
+ <ClCompile Include="commonheaders.cpp">
+ <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
+ <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
+ <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
+ <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
+ </ClCompile>
+ <ClCompile Include="main.cpp" />
+ <ClCompile Include="sendmsg.cpp" />
+ </ItemGroup>
+ <ItemGroup>
+ <ClInclude Include="..\stdplug.h" />
+ <ClInclude Include="commonheaders.h" />
+ </ItemGroup>
+ <ItemGroup>
+ <ResourceCompile Include="resource.rc" />
+ <ResourceCompile Include="version.rc" />
+ </ItemGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+ <ImportGroup Label="ExtensionTargets">
+ </ImportGroup>
+</Project>
\ No newline at end of file diff --git a/src/core/stdaway/stdaway_10.vcxproj.filters b/src/core/stdaway/stdaway_10.vcxproj.filters new file mode 100644 index 0000000000..5bd397eed2 --- /dev/null +++ b/src/core/stdaway/stdaway_10.vcxproj.filters @@ -0,0 +1,47 @@ +<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup>
+ <Filter Include="Source Files">
+ <UniqueIdentifier>{5c074c9e-6c66-4233-bbd3-a50170fccf47}</UniqueIdentifier>
+ <Extensions>cpp;c;cxx;rc;def;r;odl;idl;hpj;bat</Extensions>
+ </Filter>
+ <Filter Include="Header Files">
+ <UniqueIdentifier>{e30af2c4-42d4-4342-8eb9-2dbca157c6bb}</UniqueIdentifier>
+ <Extensions>h;hpp;hxx;hm;inl</Extensions>
+ </Filter>
+ <Filter Include="Resource Files">
+ <UniqueIdentifier>{9208a050-ffae-47fa-bc98-4ca4f79d37d7}</UniqueIdentifier>
+ <Extensions>ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe</Extensions>
+ </Filter>
+ </ItemGroup>
+ <ItemGroup>
+ <ClCompile Include="commonheaders.cpp">
+ <Filter>Source Files</Filter>
+ </ClCompile>
+ <ClCompile Include="main.cpp">
+ <Filter>Source Files</Filter>
+ </ClCompile>
+ <ClCompile Include="awaymsg.cpp">
+ <Filter>Source Files</Filter>
+ </ClCompile>
+ <ClCompile Include="sendmsg.cpp">
+ <Filter>Source Files</Filter>
+ </ClCompile>
+ </ItemGroup>
+ <ItemGroup>
+ <ClInclude Include="..\stdplug.h">
+ <Filter>Header Files</Filter>
+ </ClInclude>
+ <ClInclude Include="commonheaders.h">
+ <Filter>Header Files</Filter>
+ </ClInclude>
+ </ItemGroup>
+ <ItemGroup>
+ <ResourceCompile Include="version.rc">
+ <Filter>Resource Files</Filter>
+ </ResourceCompile>
+ <ResourceCompile Include="resource.rc">
+ <Filter>Resource Files</Filter>
+ </ResourceCompile>
+ </ItemGroup>
+</Project>
\ No newline at end of file diff --git a/src/core/stdaway/version.h b/src/core/stdaway/version.h new file mode 100644 index 0000000000..dfb0703db4 --- /dev/null +++ b/src/core/stdaway/version.h @@ -0,0 +1,14 @@ +
+#include <m_version.h>
+
+#define __FILEVERSION_STRING MIRANDA_VERSION_FILEVERSION
+#define __VERSION_STRING MIRANDA_VERSION_STRING
+
+#define __PLUGIN_NAME "stdaway"
+#define __INTERNAL_NAME "stdaway"
+#define __FILENAME "stdaway.dll"
+#define __DESCRIPTION "Core module for the away messages processing."
+#define __AUTHOR "Myranda team"
+#define __AUTHOREMAIL ""
+#define __AUTHORWEB "http://nightly.miranda.im"
+#define __COPYRIGHT "© 2012 Myranda team"
diff --git a/src/core/stdaway/version.rc b/src/core/stdaway/version.rc new file mode 100644 index 0000000000..e637f0cb33 --- /dev/null +++ b/src/core/stdaway/version.rc @@ -0,0 +1,38 @@ +// Microsoft Visual C++ generated resource script.
+//
+#include "afxres.h"
+#include "version.h"
+
+#ifdef _WIN32
+LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
+#endif //_WIN32
+
+VS_VERSION_INFO VERSIONINFO
+ FILEVERSION __FILEVERSION_STRING
+ PRODUCTVERSION __FILEVERSION_STRING
+ FILEFLAGSMASK 0x17L
+#ifdef _DEBUG
+ FILEFLAGS 0x1L
+#else
+ FILEFLAGS 0x0L
+#endif
+ FILEOS 0x4L
+ FILETYPE 0x0L
+ FILESUBTYPE 0x0L
+BEGIN
+ BLOCK "StringFileInfo"
+ BEGIN
+ BLOCK "000004b0"
+ BEGIN
+ VALUE "FileDescription", __DESCRIPTION
+ VALUE "InternalName", __PLUGIN_NAME
+ VALUE "LegalCopyright", __COPYRIGHT
+ VALUE "OriginalFilename", __FILENAME
+ VALUE "ProductName", __PLUGIN_NAME
+ END
+ END
+ BLOCK "VarFileInfo"
+ BEGIN
+ VALUE "Translation", 0x0, 1200
+ END
+END
diff --git a/src/modules/contacts/contacts.cpp b/src/core/stduserinfo/contacts.cpp index dbdd874fbb..03c546b64c 100644 --- a/src/modules/contacts/contacts.cpp +++ b/src/core/stduserinfo/contacts.cpp @@ -15,7 +15,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.
*/
-#include "..\..\core\commonheaders.h"
+#include "commonheaders.h"
#define NAMEORDERCOUNT 8
static TCHAR* nameOrderDescr[ NAMEORDERCOUNT ] =
@@ -34,12 +34,12 @@ BYTE nameOrder[NAMEORDERCOUNT]; static int GetDatabaseString(CONTACTINFO *ci, const char* setting, DBVARIANT* dbv)
{
- if (strcmp(ci->szProto, "CList") && CallProtoServiceInt(NULL,ci->szProto, PS_GETCAPS, PFLAGNUM_4, 0) & PF4_INFOSETTINGSVC)
+ if (strcmp(ci->szProto, "CList") && CallProtoService(ci->szProto, PS_GETCAPS, PFLAGNUM_4, 0) & PF4_INFOSETTINGSVC)
{
DBCONTACTGETSETTING cgs = { ci->szProto, setting, dbv };
dbv->type = (ci->dwFlag & CNF_UNICODE) ? DBVT_WCHAR : DBVT_ASCIIZ;
- int res = CallProtoServiceInt(NULL,ci->szProto, PS_GETINFOSETTING, (WPARAM)ci->hContact, (LPARAM)&cgs);
+ int res = CallProtoService(ci->szProto, PS_GETINFOSETTING, (WPARAM)ci->hContact, (LPARAM)&cgs);
if (res != CALLSERVICE_NOTFOUND) return res;
}
@@ -197,7 +197,7 @@ static INT_PTR GetContactInfo(WPARAM, LPARAM lParam) { case CNF_UNIQUEID:
{
- char *uid = (char*)CallProtoServiceInt(NULL,ci->szProto, PS_GETCAPS, PFLAG_UNIQUEIDSETTING, 0);
+ char *uid = (char*)CallProtoService(ci->szProto, PS_GETCAPS, PFLAG_UNIQUEIDSETTING, 0);
if ((INT_PTR)uid != CALLSERVICE_NOTFOUND && uid)
if ( !ProcessDatabaseValueDefault(ci, uid))
return 0;
@@ -208,7 +208,7 @@ static INT_PTR GetContactInfo(WPARAM, LPARAM lParam) { {
if ( !ProcessDatabaseValueDefault(ci, "display_uid"))
return 0;
- char *uid = (char*)CallProtoServiceInt(NULL,ci->szProto, PS_GETCAPS, PFLAG_UNIQUEIDSETTING, 0);
+ char *uid = (char*)CallProtoService(ci->szProto, PS_GETCAPS, PFLAG_UNIQUEIDSETTING, 0);
if ((INT_PTR)uid != CALLSERVICE_NOTFOUND && uid)
if ( !ProcessDatabaseValueDefault(ci, uid))
return 0;
@@ -252,7 +252,7 @@ static INT_PTR GetContactInfo(WPARAM, LPARAM lParam) { case 5: // Unique id
{
// protocol must define a PFLAG_UNIQUEIDSETTING
- char *uid = (char*)CallProtoServiceInt(NULL,ci->szProto, PS_GETCAPS, PFLAG_UNIQUEIDSETTING, 0);
+ char *uid = (char*)CallProtoService(ci->szProto, PS_GETCAPS, PFLAG_UNIQUEIDSETTING, 0);
if ((INT_PTR)uid != CALLSERVICE_NOTFOUND && uid) {
if ( !GetDatabaseString(ci, uid, &dbv)) {
if (dbv.type == DBVT_BYTE || dbv.type == DBVT_WORD || dbv.type == DBVT_DWORD) {
diff --git a/src/miranda32_10.vcxproj b/src/miranda32_10.vcxproj index 36b42b7b1f..fbc56a0a9e 100644 --- a/src/miranda32_10.vcxproj +++ b/src/miranda32_10.vcxproj @@ -289,9 +289,6 @@ <ClCompile Include="modules\button\button.cpp">
<PrecompiledHeaderFile>..\..\core\commonheaders.h</PrecompiledHeaderFile>
</ClCompile>
- <ClCompile Include="modules\contacts\contacts.cpp">
- <PrecompiledHeaderFile>..\..\core\commonheaders.h</PrecompiledHeaderFile>
- </ClCompile>
<ClCompile Include="modules\database\database.cpp">
<PrecompiledHeaderFile>..\..\core\commonheaders.h</PrecompiledHeaderFile>
</ClCompile>
@@ -442,12 +439,6 @@ <ClCompile Include="modules\skin\sounds.cpp">
<PrecompiledHeaderFile>..\..\core\commonheaders.h</PrecompiledHeaderFile>
</ClCompile>
- <ClCompile Include="modules\srawaymsg\awaymsg.cpp">
- <PrecompiledHeaderFile>..\..\core\commonheaders.h</PrecompiledHeaderFile>
- </ClCompile>
- <ClCompile Include="modules\srawaymsg\sendmsg.cpp">
- <PrecompiledHeaderFile>..\..\core\commonheaders.h</PrecompiledHeaderFile>
- </ClCompile>
<ClCompile Include="modules\utils\bmpfilter.cpp">
<PrecompiledHeaderFile>..\..\core\commonheaders.h</PrecompiledHeaderFile>
</ClCompile>
diff --git a/src/miranda32_10.vcxproj.filters b/src/miranda32_10.vcxproj.filters index 3f127520ac..0cd6716a60 100644 --- a/src/miranda32_10.vcxproj.filters +++ b/src/miranda32_10.vcxproj.filters @@ -16,9 +16,6 @@ <Filter Include="Modules\button">
<UniqueIdentifier>{880105c7-0ef2-41ee-9541-fe2c9e5a7679}</UniqueIdentifier>
</Filter>
- <Filter Include="Modules\contacts">
- <UniqueIdentifier>{3e919355-7099-4252-be9f-46e5b4f6bbc7}</UniqueIdentifier>
- </Filter>
<Filter Include="Modules\database">
<UniqueIdentifier>{a4463881-5b8c-497a-b5f4-5832dbc5fbfa}</UniqueIdentifier>
</Filter>
@@ -46,9 +43,6 @@ <Filter Include="Modules\skin">
<UniqueIdentifier>{474a2558-48fd-45d5-b8e8-3a07d780f02a}</UniqueIdentifier>
</Filter>
- <Filter Include="Modules\srawaymsg">
- <UniqueIdentifier>{ede3d43b-a5cf-462a-90df-4ddd7a091234}</UniqueIdentifier>
- </Filter>
<Filter Include="Modules\utils">
<UniqueIdentifier>{4549cb1a-17d4-49a2-82e9-3acd7e17f5bc}</UniqueIdentifier>
</Filter>
@@ -290,9 +284,6 @@ <ClCompile Include="modules\button\button.cpp">
<Filter>Modules\button</Filter>
</ClCompile>
- <ClCompile Include="modules\contacts\contacts.cpp">
- <Filter>Modules\contacts</Filter>
- </ClCompile>
<ClCompile Include="modules\database\database.cpp">
<Filter>Modules\database</Filter>
</ClCompile>
@@ -398,12 +389,6 @@ <ClCompile Include="modules\skin\sounds.cpp">
<Filter>Modules\skin</Filter>
</ClCompile>
- <ClCompile Include="modules\srawaymsg\awaymsg.cpp">
- <Filter>Modules\srawaymsg</Filter>
- </ClCompile>
- <ClCompile Include="modules\srawaymsg\sendmsg.cpp">
- <Filter>Modules\srawaymsg</Filter>
- </ClCompile>
<ClCompile Include="modules\utils\bmpfilter.cpp">
<Filter>Modules\utils</Filter>
</ClCompile>
diff --git a/src/modules/plugins/newplugins.cpp b/src/modules/plugins/newplugins.cpp index b6120c4e01..cfccdfaf62 100644 --- a/src/modules/plugins/newplugins.cpp +++ b/src/modules/plugins/newplugins.cpp @@ -58,11 +58,12 @@ MuuidReplacement pluginDefault[] = { MIID_IDLE, _T("stdidle"), NULL }, // 7
{ MIID_AUTOAWAY, _T("stdautoaway"), NULL }, // 8
{ MIID_USERONLINE, _T("stduseronline"), NULL }, // 9
+ { MIID_SRAWAY, _T("stdaway"), NULL }, // 10
- { MIID_CLIST, NULL, NULL }, // 10
- { MIID_CHAT, NULL, NULL }, // 11
- { MIID_SRMM, NULL, NULL }, // 12
- { MIID_DATABASE, NULL, NULL }, // 13
+ { MIID_CLIST, NULL, NULL }, // 11
+ { MIID_CHAT, NULL, NULL }, // 12
+ { MIID_SRMM, NULL, NULL }, // 13
+ { MIID_DATABASE, NULL, NULL }, // 14
};
static BOOL bModuleInitialized = FALSE;
diff --git a/src/resource.rc b/src/resource.rc index 62fa74bcb3..87ffa8965a 100644 --- a/src/resource.rc +++ b/src/resource.rc @@ -352,24 +352,6 @@ BEGIN LTEXT "You are never visible to this person",IDC_STATIC,26,224,279,8,SS_NOPREFIX | SS_CENTERIMAGE
END
-IDD_OPT_AWAYMSG DIALOGEX 0, 0, 263, 151
-STYLE DS_SETFONT | DS_FIXEDSYS | WS_CHILD | WS_VISIBLE
-EXSTYLE WS_EX_CONTROLPARENT
-FONT 8, "MS Shell Dlg", 0, 0, 0x1
-BEGIN
- GROUPBOX "Status Messages",IDC_STATIC,4,5,255,142
- COMBOBOX IDC_STATUS,12,19,240,97,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP
- CONTROL "Do not reply to requests for this message",IDC_DONTREPLY,
- "Button",BS_AUTOCHECKBOX | WS_TABSTOP,24,37,227,10
- CONTROL "Do not pop up dialog asking for new message",IDC_NODIALOG,
- "Button",BS_AUTOCHECKBOX | WS_TABSTOP,24,50,227,10
- CONTROL "By default, use the same message as last time",IDC_USEPREVIOUS,
- "Button",BS_AUTORADIOBUTTON,23,65,227,10
- CONTROL "By default, use this message:",IDC_USESPECIFIC,"Button",BS_AUTORADIOBUTTON,23,78,227,10
- EDITTEXT IDC_MSG,33,91,219,38,ES_MULTILINE | ES_AUTOVSCROLL | ES_WANTRETURN | WS_VSCROLL
- LTEXT "Use %time% for the current time, %date% for the current date",IDC_STATIC,33,131,219,8
-END
-
IDD_ICONINDEX DIALOGEX 0, 0, 219, 197
STYLE DS_SETFONT | DS_MODALFRAME | DS_3DLOOK | DS_FIXEDSYS | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
EXSTYLE WS_EX_CONTROLPARENT
@@ -728,25 +710,6 @@ BEGIN CONTROL "",IDC_PLUGLIST,"SysListView32",LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_SORTASCENDING | LVS_AUTOARRANGE | LVS_NOSORTHEADER | WS_BORDER | WS_TABSTOP,0,0,369,128
END
-IDD_MODERNOPT_STATUS DIALOGEX 0, 0, 369, 113
-STYLE DS_SETFONT | DS_FIXEDSYS | WS_CHILD
-EXSTYLE WS_EX_CONTROLPARENT
-FONT 8, "MS Shell Dlg", 0, 0, 0x0
-BEGIN
- COMBOBOX IDC_STATUS,2,54,16,97,CBS_DROPDOWNLIST | NOT WS_VISIBLE | WS_VSCROLL | WS_TABSTOP
- CONTROL "Do not reply to requests for this message",IDC_DONTREPLY,
- "Button",BS_AUTOCHECKBOX | NOT WS_VISIBLE | WS_TABSTOP,0,33,10,10
- CONTROL "Do not pop up dialog asking for new message",IDC_NODIALOG,
- "Button",BS_AUTOCHECKBOX | WS_TABSTOP,105,93,264,10
- CONTROL "By default, use the same message as last time",IDC_USEPREVIOUS,
- "Button",BS_AUTORADIOBUTTON,105,13,227,10
- CONTROL "By default, use this message:",IDC_USESPECIFIC,"Button",BS_AUTORADIOBUTTON,105,26,227,10
- EDITTEXT IDC_MSG,125,39,244,38,ES_MULTILINE | ES_AUTOVSCROLL | ES_WANTRETURN | WS_VSCROLL
- CTEXT "Use %time% for the current time, %date% for the current date",IDC_STATIC,125,78,244,8,SS_CENTERIMAGE
- LTEXT "Status messages:",IDC_TXT_TITLE1,0,0,246,8
- LISTBOX IDC_LST_STATUS,10,13,90,95,LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP
-END
-
IDD_MODERNOPT_IGNORE DIALOGEX 0, 0, 369, 210
STYLE DS_SETFONT | DS_FIXEDSYS | WS_CHILD
EXSTYLE WS_EX_CONTROLPARENT
@@ -948,14 +911,6 @@ BEGIN VERTGUIDE, 305
END
- IDD_OPT_AWAYMSG, DIALOG
- BEGIN
- LEFTMARGIN, 4
- RIGHTMARGIN, 259
- TOPMARGIN, 4
- BOTTOMMARGIN, 147
- END
-
IDD_ICONINDEX, DIALOG
BEGIN
LEFTMARGIN, 4
@@ -1067,17 +1022,6 @@ BEGIN VERTGUIDE, 65
END
- IDD_MODERNOPT_STATUS, DIALOG
- BEGIN
- VERTGUIDE, 10
- VERTGUIDE, 100
- VERTGUIDE, 105
- VERTGUIDE, 218
- BOTTOMMARGIN, 103
- HORZGUIDE, 8
- HORZGUIDE, 13
- END
-
IDD_MODERNOPT_IDLE, DIALOG
BEGIN
VERTGUIDE, 10
|