diff options
author | George Hazan <george.hazan@gmail.com> | 2013-07-08 22:10:14 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2013-07-08 22:10:14 +0000 |
commit | bb952e431866d131bae95c08e579ec8a00f00343 (patch) | |
tree | 60881668cf328b50906346c5f66ce47da2d9ad88 /protocols/IcqOscarJ/src/utilities.cpp | |
parent | c181af64bab27eb50e684c64c0a3caa49f8bbe39 (diff) |
core protocol helpers for creating protocol evengs, services & threads
git-svn-id: http://svn.miranda-ng.org/main/trunk@5286 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/IcqOscarJ/src/utilities.cpp')
-rw-r--r-- | protocols/IcqOscarJ/src/utilities.cpp | 46 |
1 files changed, 1 insertions, 45 deletions
diff --git a/protocols/IcqOscarJ/src/utilities.cpp b/protocols/IcqOscarJ/src/utilities.cpp index 593fa6408c..99d9b690dc 100644 --- a/protocols/IcqOscarJ/src/utilities.cpp +++ b/protocols/IcqOscarJ/src/utilities.cpp @@ -1082,7 +1082,7 @@ void CIcqProto::SendProtoAck(HANDLE hContact, DWORD dwCookie, int nAckResult, in pArgs->nAckType = nAckType;
pArgs->pszMessage = (LPARAM)null_strdup(pszMessage);
- ForkThread(( IcqThreadFunc )&CIcqProto::ProtocolAckThread, pArgs );
+ ForkThread((MyThreadFunc)&CIcqProto::ProtocolAckThread, pArgs );
}
void CIcqProto::SetCurrentStatus(int nStatus)
@@ -1829,17 +1829,6 @@ char* __fastcall ICQTranslateUtfStatic(const char *src, char *buf, size_t bufsiz return buf;
}
-void CIcqProto::ForkThread( IcqThreadFunc pFunc, void* arg )
-{
- CloseHandle(( HANDLE )mir_forkthreadowner(( pThreadFuncOwner )*( void** )&pFunc, this, arg, NULL ));
-}
-
-HANDLE CIcqProto::ForkThreadEx( IcqThreadFunc pFunc, void* arg, UINT* threadID )
-{
- return ( HANDLE )mir_forkthreadowner(( pThreadFuncOwner )*( void** )&pFunc, this, arg, threadID );
-}
-
-
char* CIcqProto::GetUserStoredPassword(char *szBuffer, int cbSize)
{
if (!getSettingStringStatic(NULL, "Password", szBuffer, cbSize))
@@ -2117,36 +2106,3 @@ DWORD CIcqProto::ReportGenericSendError(HANDLE hContact, int nType, const char* SendProtoAck(hContact, dwCookie, ACKRESULT_FAILED, nType, Translate(szErrorMsg));
return dwCookie;
}
-
-/////////////////////////////////////////////////////////////////////////////////////////
-
-void CIcqProto::CreateProtoService(const char* szService, IcqServiceFunc serviceProc)
-{
- char temp[MAX_PATH*2];
-
- null_snprintf(temp, sizeof(temp), "%s%s", m_szModuleName, szService);
- CreateServiceFunctionObj( temp, ( MIRANDASERVICEOBJ )*( void** )&serviceProc, this );
-}
-
-void CIcqProto::CreateProtoServiceParam(const char* szService, IcqServiceFuncParam serviceProc, LPARAM lParam)
-{
- char temp[MAX_PATH*2];
-
- null_snprintf(temp, sizeof(temp), "%s%s", m_szModuleName, szService);
- CreateServiceFunctionObjParam( temp, ( MIRANDASERVICEOBJPARAM )*( void** )&serviceProc, this, lParam );
-}
-
-
-HANDLE CIcqProto::HookProtoEvent(const char* szEvent, IcqEventFunc pFunc)
-{
- return ::HookEventObj(szEvent, (MIRANDAHOOKOBJ)*(void**)&pFunc, this);
-}
-
-
-HANDLE CIcqProto::CreateProtoEvent(const char* szEvent)
-{
- char str[MAX_PATH + 32];
- strcpy(str, m_szModuleName);
- strcat(str, szEvent);
- return CreateHookableEvent(str);
-}
|