summaryrefslogtreecommitdiff
path: root/plugins/FTPFileYM/src
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2014-02-10 08:04:30 +0000
committerGeorge Hazan <george.hazan@gmail.com>2014-02-10 08:04:30 +0000
commitddba4ede6b451d0cfcd0d32b5180fbd0689966bf (patch)
tree5d74f37a7013d13b92c182628d6b68a58e148ae4 /plugins/FTPFileYM/src
parentc39340bf493a1745a41317bbf937fc7eb6cbb26a (diff)
- HANDLE hContact => HCONTACT
- GCF_* prefix was added to chat constants to avoid name conflicts git-svn-id: http://svn.miranda-ng.org/main/trunk@8078 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/FTPFileYM/src')
-rw-r--r--plugins/FTPFileYM/src/dialog.cpp2
-rw-r--r--plugins/FTPFileYM/src/ftpfile.cpp12
-rw-r--r--plugins/FTPFileYM/src/job_generic.cpp4
-rw-r--r--plugins/FTPFileYM/src/job_generic.h4
-rw-r--r--plugins/FTPFileYM/src/job_packer.cpp4
-rw-r--r--plugins/FTPFileYM/src/job_packer.h2
-rw-r--r--plugins/FTPFileYM/src/job_upload.cpp2
-rw-r--r--plugins/FTPFileYM/src/job_upload.h2
-rw-r--r--plugins/FTPFileYM/src/mir_db.cpp26
-rw-r--r--plugins/FTPFileYM/src/mir_db.h26
10 files changed, 42 insertions, 42 deletions
diff --git a/plugins/FTPFileYM/src/dialog.cpp b/plugins/FTPFileYM/src/dialog.cpp
index 8c8236b09b..fa6a1f6dbd 100644
--- a/plugins/FTPFileYM/src/dialog.cpp
+++ b/plugins/FTPFileYM/src/dialog.cpp
@@ -229,7 +229,7 @@ INT_PTR CALLBACK UploadDialog::UploadDlgProc(HWND hwndDlg, UINT msg, WPARAM wPar
}
case WM_COMMAND:
{
- HANDLE hContact = uDlg->tabs[uDlg->activeTab]->job->hContact;
+ HCONTACT hContact = uDlg->tabs[uDlg->activeTab]->job->hContact;
if (hContact != NULL)
{
if (CallService(MS_CLIST_MENUPROCESSCOMMAND, MAKEWPARAM(LOWORD(wParam),MPCF_CONTACTMENU), (LPARAM)hContact))
diff --git a/plugins/FTPFileYM/src/ftpfile.cpp b/plugins/FTPFileYM/src/ftpfile.cpp
index 7f44b271e4..8e91fba3fa 100644
--- a/plugins/FTPFileYM/src/ftpfile.cpp
+++ b/plugins/FTPFileYM/src/ftpfile.cpp
@@ -35,7 +35,7 @@ extern Options &opt;
int PrebuildContactMenu(WPARAM wParam, LPARAM lParam);
void PrebuildMainMenu();
int TabsrmmButtonPressed(WPARAM wParam, LPARAM lParam);
-int UploadFile(HANDLE hContact, int iFtpNum, UploadJob::EMode mode);
+int UploadFile(HCONTACT hContact, int iFtpNum, UploadJob::EMode mode);
static PLUGININFOEX pluginInfoEx =
{
@@ -210,7 +210,7 @@ int PrebuildContactMenu(WPARAM wParam, LPARAM lParam)
{
bool bIsContact = false;
- char *szProto = GetContactProto((HANDLE)wParam);
+ char *szProto = GetContactProto((HCONTACT)wParam);
if (szProto) bIsContact = (CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_1, 0) & PF1_IM) ? true : false;
bool bHideRoot = opt.bHideInactive;
@@ -236,7 +236,7 @@ void PrebuildMainMenu()
int TabsrmmButtonPressed(WPARAM wParam, LPARAM lParam)
{
CustomButtonClickData *cbc = (CustomButtonClickData *)lParam;
- HANDLE hContact = (HANDLE)wParam;
+ HCONTACT hContact = (HCONTACT)wParam;
if (!strcmp(cbc->pszModule, MODULE) && cbc->dwButtonId == 1 && hContact)
{
@@ -292,7 +292,7 @@ int TabsrmmButtonPressed(WPARAM wParam, LPARAM lParam)
return 0;
}
-int UploadFile(HANDLE hContact, int iFtpNum, GenericJob::EMode mode, void **objects, int objCount, DWORD flags)
+int UploadFile(HCONTACT hContact, int iFtpNum, GenericJob::EMode mode, void **objects, int objCount, DWORD flags)
{
if (!ftpList[iFtpNum]->isValid())
{
@@ -334,7 +334,7 @@ int UploadFile(HANDLE hContact, int iFtpNum, GenericJob::EMode mode, void **obje
return 0;
}
-int UploadFile(HANDLE hContact, int iFtpNum, GenericJob::EMode mode)
+int UploadFile(HCONTACT hContact, int iFtpNum, GenericJob::EMode mode)
{
return UploadFile(hContact, iFtpNum, mode, NULL, 0, 0);
}
@@ -363,7 +363,7 @@ INT_PTR ShowManagerService(WPARAM wParam, LPARAM lParam)
INT_PTR ContactMenuService(WPARAM wParam, LPARAM lParam)
{
- HANDLE hContact = (HANDLE)wParam;
+ HCONTACT hContact = (HCONTACT)wParam;
int ftpNum = lParam & (1|2|4);
int mode = lParam & (UploadJob::FTP_RAWFILE | UploadJob::FTP_ZIPFILE | UploadJob::FTP_ZIPFOLDER);
return UploadFile(hContact, ftpNum, (UploadJob::EMode)mode);
diff --git a/plugins/FTPFileYM/src/job_generic.cpp b/plugins/FTPFileYM/src/job_generic.cpp
index a723c45931..bfac7ccf79 100644
--- a/plugins/FTPFileYM/src/job_generic.cpp
+++ b/plugins/FTPFileYM/src/job_generic.cpp
@@ -21,8 +21,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
extern UploadDialog *uDlg;
extern ServerList &ftpList;
-GenericJob::GenericJob(HANDLE _hContact, int _iFtpNum, EMode _mode)
-:hContact(_hContact),iFtpNum(_iFtpNum),mode(_mode),status(STATUS_CREATED),ftp(ftpList[iFtpNum])
+GenericJob::GenericJob(HCONTACT _hContact, int _iFtpNum, EMode _mode) :
+ hContact(_hContact),iFtpNum(_iFtpNum),mode(_mode),status(STATUS_CREATED),ftp(ftpList[iFtpNum])
{
this->stzFilePath[0] = 0;
this->stzFileName[0] = 0;
diff --git a/plugins/FTPFileYM/src/job_generic.h b/plugins/FTPFileYM/src/job_generic.h
index 618d891a82..0003045300 100644
--- a/plugins/FTPFileYM/src/job_generic.h
+++ b/plugins/FTPFileYM/src/job_generic.h
@@ -66,7 +66,7 @@ public:
STATUS_COMPLETED
};
- HANDLE hContact;
+ HCONTACT hContact;
int iFtpNum, fileID;
ServerList::FTP *ftp;
TCHAR stzFilePath[1024];
@@ -79,7 +79,7 @@ public:
vector<TCHAR *> files;
TCHAR * operator[] (int i) const { return files[i];}
- GenericJob(HANDLE hContact, int iFtpNum, EMode mode);
+ GenericJob(HCONTACT hContact, int iFtpNum, EMode mode);
GenericJob(GenericJob *job);
virtual ~GenericJob();
diff --git a/plugins/FTPFileYM/src/job_packer.cpp b/plugins/FTPFileYM/src/job_packer.cpp
index 8002d2b0ed..a57d9dc402 100644
--- a/plugins/FTPFileYM/src/job_packer.cpp
+++ b/plugins/FTPFileYM/src/job_packer.cpp
@@ -25,8 +25,8 @@ int PackerJob::iRunningJobCount = 0;
extern UploadDialog *uDlg;
extern Options &opt;
-PackerJob::PackerJob(HANDLE _hContact, int _iFtpNum, EMode _mode)
-:GenericJob(_hContact, _iFtpNum, _mode),uiFileSize(0),uiReaded(0),lastUpdateTick(0)
+PackerJob::PackerJob(HCONTACT _hContact, int _iFtpNum, EMode _mode) :
+ GenericJob(_hContact, _iFtpNum, _mode),uiFileSize(0),uiReaded(0),lastUpdateTick(0)
{ }
void PackerJob::getZipFilePath()
diff --git a/plugins/FTPFileYM/src/job_packer.h b/plugins/FTPFileYM/src/job_packer.h
index 2c2c22ddc6..37c7edc055 100644
--- a/plugins/FTPFileYM/src/job_packer.h
+++ b/plugins/FTPFileYM/src/job_packer.h
@@ -46,7 +46,7 @@ private:
bool isCanceled();
public:
- PackerJob(HANDLE hContact, int iFtpNum, EMode mode);
+ PackerJob(HCONTACT hContact, int iFtpNum, EMode mode);
virtual ~PackerJob() {};
virtual void start();
diff --git a/plugins/FTPFileYM/src/job_upload.cpp b/plugins/FTPFileYM/src/job_upload.cpp
index df01b5e1aa..2d0a596da9 100644
--- a/plugins/FTPFileYM/src/job_upload.cpp
+++ b/plugins/FTPFileYM/src/job_upload.cpp
@@ -25,7 +25,7 @@ int UploadJob::iRunningJobCount = 0;
extern UploadDialog *uDlg;
extern ServerList &ftpList;
-UploadJob::UploadJob(HANDLE _hContact, int _iFtpNum, EMode _mode) :
+UploadJob::UploadJob(HCONTACT _hContact, int _iFtpNum, EMode _mode) :
GenericJob(_hContact, _iFtpNum, _mode),fp(NULL)
{
this->szFileLink[0] = 0;
diff --git a/plugins/FTPFileYM/src/job_upload.h b/plugins/FTPFileYM/src/job_upload.h
index fa29e3c640..0679773cfd 100644
--- a/plugins/FTPFileYM/src/job_upload.h
+++ b/plugins/FTPFileYM/src/job_upload.h
@@ -65,7 +65,7 @@ public:
char szFileLink[256];
static Event jobDone;
- UploadJob(HANDLE _hContact, int _iFtpNum, EMode _mode);
+ UploadJob(HCONTACT _hContact, int _iFtpNum, EMode _mode);
UploadJob(UploadJob *job);
UploadJob(PackerJob *job);
virtual ~UploadJob();
diff --git a/plugins/FTPFileYM/src/mir_db.cpp b/plugins/FTPFileYM/src/mir_db.cpp
index 13d1d645a7..bf21c1f472 100644
--- a/plugins/FTPFileYM/src/mir_db.cpp
+++ b/plugins/FTPFileYM/src/mir_db.cpp
@@ -18,63 +18,63 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include "common.h"
-int DB::setByteF(HANDLE hContact, char *szModule, char *szSetting, int id, int iValue)
+int DB::setByteF(HCONTACT hContact, char *szModule, char *szSetting, int id, int iValue)
{
char formSet[256];
mir_snprintf(formSet, sizeof(formSet), szSetting, id);
return db_set_b(hContact, szModule, formSet, iValue);
}
-int DB::setWordF(HANDLE hContact, char *szModule, char *szSetting, int id, int iValue)
+int DB::setWordF(HCONTACT hContact, char *szModule, char *szSetting, int id, int iValue)
{
char formSet[256];
mir_snprintf(formSet, sizeof(formSet), szSetting, id);
return db_set_w(hContact, szModule, formSet, iValue);
}
-int DB::setDwordF(HANDLE hContact, char *szModule, char *szSetting, int id, int iValue)
+int DB::setDwordF(HCONTACT hContact, char *szModule, char *szSetting, int id, int iValue)
{
char formSet[256];
mir_snprintf(formSet, sizeof(formSet), szSetting, id);
return db_set_dw(hContact, szModule, formSet, iValue);
}
-int DB::setAStringF(HANDLE hContact, char *szModule, char *szSetting, int id, char *szValue)
+int DB::setAStringF(HCONTACT hContact, char *szModule, char *szSetting, int id, char *szValue)
{
char formSet[256];
mir_snprintf(formSet, sizeof(formSet), szSetting, id);
return db_set_s(hContact, szModule, formSet, szValue);
}
-int DB::setStringF(HANDLE hContact, char *szModule, char *szSetting, int id, TCHAR *stzValue)
+int DB::setStringF(HCONTACT hContact, char *szModule, char *szSetting, int id, TCHAR *stzValue)
{
char formSet[256];
mir_snprintf(formSet, sizeof(formSet), szSetting, id);
return db_set_ts(hContact, szModule, formSet, stzValue);
}
-int DB::getByteF(HANDLE hContact, char *szModule, char *szSetting, int id, int iErrorValue)
+int DB::getByteF(HCONTACT hContact, char *szModule, char *szSetting, int id, int iErrorValue)
{
char formSet[256];
mir_snprintf(formSet, sizeof(formSet), szSetting, id);
return db_get_b(hContact, szModule, formSet, iErrorValue);
}
-int DB::getWordF(HANDLE hContact, char *szModule, char *szSetting, int id, int iErrorValue)
+int DB::getWordF(HCONTACT hContact, char *szModule, char *szSetting, int id, int iErrorValue)
{
char formSet[256];
mir_snprintf(formSet, sizeof(formSet), szSetting, id);
return db_get_w(hContact, szModule, formSet, iErrorValue);
}
-int DB::getDwordF(HANDLE hContact, char *szModule, char *szSetting, int id, int iErrorValue)
+int DB::getDwordF(HCONTACT hContact, char *szModule, char *szSetting, int id, int iErrorValue)
{
char formSet[256];
mir_snprintf(formSet, sizeof(formSet), szSetting, id);
return db_get_dw(hContact, szModule, formSet, iErrorValue);
}
-int DB::getAString(HANDLE hContact, char *szModule, char *szSetting, char *buff)
+int DB::getAString(HCONTACT hContact, char *szModule, char *szSetting, char *buff)
{
DBVARIANT dbv;
if (!db_get_s(hContact, szModule, szSetting, &dbv))
@@ -88,14 +88,14 @@ int DB::getAString(HANDLE hContact, char *szModule, char *szSetting, char *buff)
return 1;
}
-int DB::getAStringF(HANDLE hContact, char *szModule, char *szSetting, int id, char *buff)
+int DB::getAStringF(HCONTACT hContact, char *szModule, char *szSetting, int id, char *buff)
{
char formSet[256];
mir_snprintf(formSet, sizeof(formSet), szSetting, id);
return getAString(hContact, szModule, formSet, buff);
}
-int DB::getString(HANDLE hContact, char *szModule, char *szSetting, TCHAR *buff)
+int DB::getString(HCONTACT hContact, char *szModule, char *szSetting, TCHAR *buff)
{
DBVARIANT dbv;
if (!db_get_ts(hContact, szModule, szSetting, &dbv))
@@ -109,14 +109,14 @@ int DB::getString(HANDLE hContact, char *szModule, char *szSetting, TCHAR *buff)
return 1;
}
-int DB::getStringF(HANDLE hContact, char *szModule, char *szSetting, int id, TCHAR *buff)
+int DB::getStringF(HCONTACT hContact, char *szModule, char *szSetting, int id, TCHAR *buff)
{
char formSet[256];
mir_snprintf(formSet, sizeof(formSet), szSetting, id);
return getString(hContact, szModule, formSet, buff);
}
-int DB::deleteSettingF(HANDLE hContact, char *szModule, char *szSetting, int id)
+int DB::deleteSettingF(HCONTACT hContact, char *szModule, char *szSetting, int id)
{
char formSet[256];
mir_snprintf(formSet, sizeof(formSet), szSetting, id);
diff --git a/plugins/FTPFileYM/src/mir_db.h b/plugins/FTPFileYM/src/mir_db.h
index d46b16fb06..e5175fdc0a 100644
--- a/plugins/FTPFileYM/src/mir_db.h
+++ b/plugins/FTPFileYM/src/mir_db.h
@@ -23,22 +23,22 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
class DB
{
public:
- static int setByteF(HANDLE hContact, char *szModule, char *szSetting, int id, int iValue);
- static int setWordF(HANDLE hContact, char *szModule, char *szSetting, int id, int iValue);
- static int setDwordF(HANDLE hContact, char *szModule, char *szSetting, int id, int iValue);
+ static int setByteF(HCONTACT hContact, char *szModule, char *szSetting, int id, int iValue);
+ static int setWordF(HCONTACT hContact, char *szModule, char *szSetting, int id, int iValue);
+ static int setDwordF(HCONTACT hContact, char *szModule, char *szSetting, int id, int iValue);
- static int setAStringF(HANDLE hContact, char *szModule, char *szSetting, int id, char *szValue);
- static int setStringF(HANDLE hContact, char *szModule, char *szSetting, int id, TCHAR *stzValue);
+ static int setAStringF(HCONTACT hContact, char *szModule, char *szSetting, int id, char *szValue);
+ static int setStringF(HCONTACT hContact, char *szModule, char *szSetting, int id, TCHAR *stzValue);
- static int getByteF(HANDLE hContact, char *szModule, char *szSetting, int id, int iErrorValue = -1);
- static int getWordF(HANDLE hContact, char *szModule, char *szSetting, int id, int iErrorValue = -1);
- static int getDwordF(HANDLE hContact, char *szModule, char *szSetting, int id, int iErrorValue = -1);
+ static int getByteF(HCONTACT hContact, char *szModule, char *szSetting, int id, int iErrorValue = -1);
+ static int getWordF(HCONTACT hContact, char *szModule, char *szSetting, int id, int iErrorValue = -1);
+ static int getDwordF(HCONTACT hContact, char *szModule, char *szSetting, int id, int iErrorValue = -1);
// !!!!!!!!!!!!!!!!!!! dangerous as hell
- static int getAString(HANDLE hContact, char *szModule, char *szSetting, char *buff);
- static int getAStringF(HANDLE hContact, char *szModule, char *szSetting, int id, char *buff);
- static int getString(HANDLE hContact, char *szModule, char *szSetting, TCHAR *buff);
- static int getStringF(HANDLE hContact, char *szModule, char *szSetting, int id, TCHAR *buff);
+ static int getAString(HCONTACT hContact, char *szModule, char *szSetting, char *buff);
+ static int getAStringF(HCONTACT hContact, char *szModule, char *szSetting, int id, char *buff);
+ static int getString(HCONTACT hContact, char *szModule, char *szSetting, TCHAR *buff);
+ static int getStringF(HCONTACT hContact, char *szModule, char *szSetting, int id, TCHAR *buff);
- static int deleteSettingF(HANDLE hContact, char *szModule, char *szSetting, int id);
+ static int deleteSettingF(HCONTACT hContact, char *szModule, char *szSetting, int id);
};