diff options
author | George Hazan <george.hazan@gmail.com> | 2014-02-10 20:47:51 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2014-02-10 20:47:51 +0000 |
commit | 68d3fd47bb9b75e65859d14199ffee01f16ac9a7 (patch) | |
tree | fcc340ad7067561e57733b287f193a7dbed93dd4 /src/core/stdfile | |
parent | 7193759b046338c6f47ff2edb34743a1465791cd (diff) |
HCONTACT is not needed anymore
git-svn-id: http://svn.miranda-ng.org/main/trunk@8086 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'src/core/stdfile')
-rw-r--r-- | src/core/stdfile/file.cpp | 22 | ||||
-rw-r--r-- | src/core/stdfile/file.h | 8 | ||||
-rw-r--r-- | src/core/stdfile/filerecvdlg.cpp | 2 |
3 files changed, 16 insertions, 16 deletions
diff --git a/src/core/stdfile/file.cpp b/src/core/stdfile/file.cpp index 7cf600a641..9bc353b73d 100644 --- a/src/core/stdfile/file.cpp +++ b/src/core/stdfile/file.cpp @@ -30,7 +30,7 @@ int PFTS_CompareWithTchar(PROTOFILETRANSFERSTATUS* ft, const PROTOCHAR* s, TCHAR static HGENMENU hSRFileMenuItem;
-TCHAR *GetContactID(HCONTACT hContact)
+TCHAR *GetContactID(MCONTACT hContact)
{
TCHAR *theValue = {0};
char *szProto = GetContactProto(hContact);
@@ -62,7 +62,7 @@ TCHAR *GetContactID(HCONTACT hContact) static INT_PTR SendFileCommand(WPARAM wParam, LPARAM)
{
struct FileSendData fsd;
- fsd.hContact = (HCONTACT)wParam;
+ fsd.hContact = (MCONTACT)wParam;
fsd.ppFiles = NULL;
CreateDialogParam(hInst, MAKEINTRESOURCE(IDD_FILESEND), NULL, DlgProcSendFile, (LPARAM)&fsd);
return 0;
@@ -71,7 +71,7 @@ static INT_PTR SendFileCommand(WPARAM wParam, LPARAM) static INT_PTR SendSpecificFiles(WPARAM wParam, LPARAM lParam)
{
FileSendData fsd;
- fsd.hContact = (HCONTACT)wParam;
+ fsd.hContact = (MCONTACT)wParam;
char** ppFiles = (char**)lParam;
int count = 0;
@@ -92,7 +92,7 @@ static INT_PTR SendSpecificFiles(WPARAM wParam, LPARAM lParam) static INT_PTR SendSpecificFilesT(WPARAM wParam, LPARAM lParam)
{
FileSendData fsd;
- fsd.hContact = (HCONTACT)wParam;
+ fsd.hContact = (MCONTACT)wParam;
fsd.ppFiles = (const TCHAR**)lParam;
CreateDialogParam(hInst, MAKEINTRESOURCE(IDD_FILESEND), NULL, DlgProcSendFile, (LPARAM)&fsd);
return 0;
@@ -101,7 +101,7 @@ static INT_PTR SendSpecificFilesT(WPARAM wParam, LPARAM lParam) static INT_PTR GetReceivedFilesFolder(WPARAM wParam, LPARAM lParam)
{
TCHAR buf[MAX_PATH];
- GetContactReceivedFilesDir((HCONTACT)wParam, buf, MAX_PATH, TRUE);
+ GetContactReceivedFilesDir((MCONTACT)wParam, buf, MAX_PATH, TRUE);
char* dir = mir_t2a(buf);
lstrcpynA((char*)lParam, dir, MAX_PATH);
mir_free(dir);
@@ -114,7 +114,7 @@ static INT_PTR RecvFileCommand(WPARAM, LPARAM lParam) return 0;
}
-void PushFileEvent(HCONTACT hContact, HANDLE hdbe, LPARAM lParam)
+void PushFileEvent(MCONTACT hContact, HANDLE hdbe, LPARAM lParam)
{
CLISTEVENT cle = {0};
cle.cbSize = sizeof(cle);
@@ -148,7 +148,7 @@ static int FileEventAdded(WPARAM wParam, LPARAM lParam) if (dbei.flags & (DBEF_SENT|DBEF_READ) || dbei.eventType != EVENTTYPE_FILE || dwSignature == 0)
return 0;
- PushFileEvent((HCONTACT)wParam, (HANDLE)lParam, 0);
+ PushFileEvent((MCONTACT)wParam, (HANDLE)lParam, 0);
return 0;
}
@@ -288,7 +288,7 @@ void UpdateProtoFileTransferStatus(PROTOFILETRANSFERSTATUS *dest, PROTOFILETRANS static void RemoveUnreadFileEvents(void)
{
- for (HCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
+ for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
HANDLE hDbEvent = db_event_firstUnread(hContact);
while (hDbEvent) {
DBEVENTINFO dbei = { sizeof(dbei) };
@@ -303,12 +303,12 @@ static void RemoveUnreadFileEvents(void) static int SRFilePreBuildMenu(WPARAM wParam, LPARAM)
{
bool bEnabled = false;
- char *szProto = GetContactProto((HCONTACT)wParam);
+ char *szProto = GetContactProto((MCONTACT)wParam);
if (szProto != NULL) {
if ( CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_FILESEND) {
if ( CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_4, 0) & PF4_OFFLINEFILES)
bEnabled = true;
- else if (db_get_w((HCONTACT)wParam, szProto, "Status", ID_STATUS_OFFLINE) != ID_STATUS_OFFLINE)
+ else if (db_get_w((MCONTACT)wParam, szProto, "Status", ID_STATUS_OFFLINE) != ID_STATUS_OFFLINE)
bEnabled = true;
}
}
@@ -339,7 +339,7 @@ INT_PTR FtMgrShowCommand(WPARAM, LPARAM) INT_PTR openContRecDir(WPARAM wparam, LPARAM)
{
TCHAR szContRecDir[MAX_PATH];
- HCONTACT hContact = (HCONTACT)wparam;
+ MCONTACT hContact = (MCONTACT)wparam;
GetContactReceivedFilesDir(hContact, szContRecDir, SIZEOF(szContRecDir), TRUE);
ShellExecute(0, _T("open"), szContRecDir, 0, 0, SW_SHOW);
return 0;
diff --git a/src/core/stdfile/file.h b/src/core/stdfile/file.h index aa390a774a..2c21d5987f 100644 --- a/src/core/stdfile/file.h +++ b/src/core/stdfile/file.h @@ -38,7 +38,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #define M_PRESHUTDOWN (WM_USER+201)
struct FileSendData {
- HCONTACT hContact;
+ MCONTACT hContact;
const TCHAR **ppFiles;
};
@@ -46,7 +46,7 @@ struct FileSendData { struct FileDlgData {
HWND hwndTransfer;
HANDLE fs;
- HCONTACT hContact;
+ MCONTACT hContact;
HANDLE hDbEvent;
HANDLE hNotifyEvent;
TCHAR **files;
@@ -85,7 +85,7 @@ INT_PTR CALLBACK DlgProcSendFile(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l INT_PTR CALLBACK DlgProcRecvFile(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
void RemoveInvalidFilenameChars(TCHAR *tszString);
void RemoveInvalidPathChars(TCHAR *tszString);
-void GetContactReceivedFilesDir(HCONTACT hContact, TCHAR *szDir, int cchDir, BOOL substVars);
+void GetContactReceivedFilesDir(MCONTACT hContact, TCHAR *szDir, int cchDir, BOOL substVars);
void GetReceivedFilesDir(TCHAR *szDir, int cchDir);
int BrowseForFolder(HWND hwnd, TCHAR *szPath);
//fileexistsdlg.c
@@ -113,4 +113,4 @@ HWND FtMgr_AddTransfer(struct FileDlgData *dat); void FreeFileDlgData(FileDlgData* dat);
-TCHAR *GetContactID(HCONTACT hContact);
+TCHAR *GetContactID(MCONTACT hContact);
diff --git a/src/core/stdfile/filerecvdlg.cpp b/src/core/stdfile/filerecvdlg.cpp index b98aa94ea6..f2f19d5ded 100644 --- a/src/core/stdfile/filerecvdlg.cpp +++ b/src/core/stdfile/filerecvdlg.cpp @@ -131,7 +131,7 @@ static void patchDir(TCHAR *str, size_t strSize) lstrcpy(str+len, _T("\\"));
}
-void GetContactReceivedFilesDir(HCONTACT hContact, TCHAR *szDir, int cchDir, BOOL patchVars)
+void GetContactReceivedFilesDir(MCONTACT hContact, TCHAR *szDir, int cchDir, BOOL patchVars)
{
DBVARIANT dbv;
TCHAR szTemp[MAX_PATH];
|