summaryrefslogtreecommitdiff
path: root/protocols/IcqOscarJ/src/init.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2014-02-16 18:08:37 +0000
committerGeorge Hazan <george.hazan@gmail.com>2014-02-16 18:08:37 +0000
commit253783569bef2320d04fe1d310709c64c64fd3a1 (patch)
tree55181ccfc8d93cd78aa8ded73bc7ab289e6ec8b9 /protocols/IcqOscarJ/src/init.cpp
parentb3783bb50a312fa59d302aeede929377c18a6ec1 (diff)
- custom list of time zones removed;
- adaptation of ICQ for new Time API; - code cleaning git-svn-id: http://svn.miranda-ng.org/main/trunk@8140 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/IcqOscarJ/src/init.cpp')
-rw-r--r--protocols/IcqOscarJ/src/init.cpp28
1 files changed, 15 insertions, 13 deletions
diff --git a/protocols/IcqOscarJ/src/init.cpp b/protocols/IcqOscarJ/src/init.cpp
index 938d7ab41b..1aa4c37c28 100644
--- a/protocols/IcqOscarJ/src/init.cpp
+++ b/protocols/IcqOscarJ/src/init.cpp
@@ -34,10 +34,12 @@
HINSTANCE hInst;
int hLangpack;
+TIME_API tmi;
CLIST_INTERFACE *pcli;
+
BOOL bPopupService = FALSE;
-HANDLE hExtraXStatus;
+HANDLE hExtraXStatus;
PLUGININFOEX pluginInfo = {
sizeof(PLUGININFOEX),
@@ -49,7 +51,7 @@ PLUGININFOEX pluginInfo = {
__COPYRIGHT,
__AUTHORWEB,
UNICODE_AWARE, //doesn't replace anything built-in
- {0x73a9615c, 0x7d4e, 0x4555, {0xba, 0xdb, 0xee, 0x5, 0xdc, 0x92, 0x8e, 0xff}} // {73A9615C-7D4E-4555-BADB-EE05DC928EFF}
+ { 0x73a9615c, 0x7d4e, 0x4555, { 0xba, 0xdb, 0xee, 0x5, 0xdc, 0x92, 0x8e, 0xff } } // {73A9615C-7D4E-4555-BADB-EE05DC928EFF}
};
extern "C" PLUGININFOEX __declspec(dllexport) *MirandaPluginInfoEx(DWORD mirandaVersion)
@@ -57,9 +59,9 @@ extern "C" PLUGININFOEX __declspec(dllexport) *MirandaPluginInfoEx(DWORD miranda
return &pluginInfo;
}
-extern "C" __declspec(dllexport) const MUUID MirandaInterfaces[] = {MIID_PROTOCOL, MIID_LAST};
+extern "C" __declspec(dllexport) const MUUID MirandaInterfaces[] = { MIID_PROTOCOL, MIID_LAST };
-extern "C" BOOL WINAPI DllMain(HINSTANCE hinstDLL,DWORD fdwReason,LPVOID lpvReserved)
+extern "C" BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
{
hInst = hinstDLL;
return TRUE;
@@ -67,17 +69,17 @@ extern "C" BOOL WINAPI DllMain(HINSTANCE hinstDLL,DWORD fdwReason,LPVOID lpvRese
/////////////////////////////////////////////////////////////////////////////////////////
-static PROTO_INTERFACE* icqProtoInit( const char* pszProtoName, const TCHAR* tszUserName )
+static PROTO_INTERFACE* icqProtoInit(const char* pszProtoName, const TCHAR* tszUserName)
{
CIcqProto *ppro = new CIcqProto(pszProtoName, tszUserName);
g_Instances.insert(ppro);
return ppro;
}
-static int icqProtoUninit( PROTO_INTERFACE* ppro )
+static int icqProtoUninit(PROTO_INTERFACE* ppro)
{
- g_Instances.remove(( CIcqProto* )ppro);
- delete ( CIcqProto* )ppro;
+ g_Instances.remove((CIcqProto*)ppro);
+ delete (CIcqProto*)ppro;
return 0;
}
@@ -89,17 +91,18 @@ int ModuleLoad(WPARAM wParam, LPARAM lParam)
extern "C" int __declspec(dllexport) Load(void)
{
- mir_getLP( &pluginInfo );
+ mir_getLP(&pluginInfo);
mir_getCLI();
+ mir_getTMI(&tmi);
srand(time(NULL));
_tzset();
// Register the module
PROTOCOLDESCRIPTOR pd = { sizeof(pd) };
- pd.szName = ICQ_PROTOCOL_NAME;
- pd.type = PROTOTYPE_PROTOCOL;
- pd.fnInit = icqProtoInit;
+ pd.szName = ICQ_PROTOCOL_NAME;
+ pd.type = PROTOTYPE_PROTOCOL;
+ pd.fnInit = icqProtoInit;
pd.fnUninit = icqProtoUninit;
CallService(MS_PROTO_REGISTERMODULE, 0, (LPARAM)&pd);
@@ -122,7 +125,6 @@ extern "C" int __declspec(dllexport) Load(void)
return 0;
}
-
extern "C" int __declspec(dllexport) Unload(void)
{
// destroying contact menu