Mercurial > pidgin.yaz
annotate src/win32/IdleTracker/idletrack.c @ 8225:9790cda80d52
[gaim-migrate @ 8948]
Various bits o' chat code cleanup for oscar.
Mostly I just wanted to re-use some code for incoming i18n chat messages.
committer: Tailor Script <tailor@pidgin.im>
author | Mark Doliner <mark@kingant.net> |
---|---|
date | Wed, 11 Feb 2004 04:06:16 +0000 |
parents | 59ffe137176d |
children | 9f6a28af7164 |
rev | line source |
---|---|
4533
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
1 /* |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
2 * idletrack.c |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
3 * |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
4 * Authors: mrgentry @ http://www.experts-exchange.com |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
5 * Herman Bloggs <hermanator12002@yahoo.com> |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
6 * Date: February, 2003 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
7 * Description: Track user inactivity. |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
8 */ |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
9 #include <windows.h> |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
10 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
11 #define EXPORT __declspec(dllexport) |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
12 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
13 static HANDLE hMapObject = NULL; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
14 static DWORD *lastTime = NULL; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
15 static HHOOK keyHook = NULL; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
16 static HHOOK mouseHook = NULL; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
17 static HINSTANCE g_hInstance = NULL; |
4548
ae85f27e4948
[gaim-migrate @ 4827]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
4533
diff
changeset
|
18 static POINT g_point; |
4533
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
19 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
20 static DWORD* setup_shared_mem() { |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
21 BOOL fInit; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
22 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
23 // Set up the shared memory. |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
24 hMapObject = CreateFileMapping((HANDLE) 0xFFFFFFFF, // use paging file |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
25 NULL, // no security attributes |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
26 PAGE_READWRITE, // read/write access |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
27 0, // size: high 32-bits |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
28 sizeof(DWORD), // size: low 32-bits |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
29 "timermem"); // name of map object |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
30 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
31 if (hMapObject == NULL) |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
32 return NULL; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
33 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
34 // The first process to attach initializes memory. |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
35 fInit = (GetLastError() != ERROR_ALREADY_EXISTS); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
36 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
37 // Get a pointer to the file-mapped shared memory. |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
38 lastTime = (DWORD*) MapViewOfFile(hMapObject, // object to map view of |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
39 FILE_MAP_WRITE, // read/write access |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
40 0, // high offset: map from |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
41 0, // low offset: beginning |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
42 0); // default: map entire file |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
43 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
44 if (lastTime == NULL) |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
45 return NULL; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
46 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
47 *lastTime = GetTickCount(); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
48 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
49 return lastTime; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
50 } |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
51 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
52 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
53 LRESULT CALLBACK KeyboardProc(int code, WPARAM wParam, LPARAM lParam) { |
6561
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
54 if (!(code < 0)) { |
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
55 if (lastTime == NULL) |
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
56 lastTime = setup_shared_mem(); |
4533
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
57 |
6561
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
58 if (lastTime) |
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
59 *lastTime = GetTickCount(); |
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
60 } |
5336
5480a73b2696
[gaim-migrate @ 5712]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
4548
diff
changeset
|
61 return CallNextHookEx(keyHook, code, wParam, lParam); |
4533
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
62 } |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
63 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
64 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
65 LRESULT CALLBACK MouseProc(int code, WPARAM wParam, LPARAM lParam) { |
4548
ae85f27e4948
[gaim-migrate @ 4827]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
4533
diff
changeset
|
66 /* We need to verify that the Mouse pointer has actually moved. */ |
6561
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
67 if(!(code < 0) && |
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
68 !((g_point.x == ((MOUSEHOOKSTRUCT*)lParam)->pt.x) && |
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
69 (g_point.y == ((MOUSEHOOKSTRUCT*)lParam)->pt.y))) { |
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
70 g_point.x = ((MOUSEHOOKSTRUCT*)lParam)->pt.x; |
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
71 g_point.y = ((MOUSEHOOKSTRUCT*)lParam)->pt.y; |
4533
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
72 |
6561
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
73 if (lastTime == NULL) |
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
74 lastTime = setup_shared_mem(); |
4533
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
75 |
6561
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
76 if (lastTime) |
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
77 *lastTime = GetTickCount(); |
33ceba0dfd9b
[gaim-migrate @ 7083]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
5336
diff
changeset
|
78 } |
5336
5480a73b2696
[gaim-migrate @ 5712]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
4548
diff
changeset
|
79 return CallNextHookEx(mouseHook, code, wParam, lParam); |
4533
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
80 } |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
81 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
82 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
83 EXPORT DWORD wgaim_get_lastactive() { |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
84 if (lastTime == NULL) |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
85 lastTime = setup_shared_mem(); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
86 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
87 if (lastTime) |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
88 return *lastTime; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
89 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
90 return 0; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
91 } |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
92 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
93 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
94 EXPORT BOOL wgaim_set_idlehooks() { |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
95 // Set up the shared memory. |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
96 lastTime = setup_shared_mem(); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
97 if (lastTime == NULL) |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
98 return FALSE; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
99 *lastTime = GetTickCount(); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
100 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
101 // Set up the keyboard hook. |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
102 keyHook = SetWindowsHookEx(WH_KEYBOARD, KeyboardProc, g_hInstance, 0); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
103 if (keyHook == NULL) { |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
104 UnmapViewOfFile(lastTime); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
105 CloseHandle(hMapObject); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
106 return FALSE; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
107 } |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
108 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
109 // Set up the mouse hook. |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
110 mouseHook = SetWindowsHookEx(WH_MOUSE, MouseProc, g_hInstance, 0); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
111 if (mouseHook == NULL) { |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
112 UnhookWindowsHookEx(keyHook); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
113 UnmapViewOfFile(lastTime); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
114 CloseHandle(hMapObject); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
115 return FALSE; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
116 } |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
117 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
118 return TRUE; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
119 } |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
120 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
121 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
122 EXPORT void wgaim_remove_idlehooks() { |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
123 if (keyHook) |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
124 UnhookWindowsHookEx(keyHook); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
125 if (mouseHook) |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
126 UnhookWindowsHookEx(mouseHook); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
127 if (lastTime) |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
128 UnmapViewOfFile(lastTime); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
129 if (hMapObject) |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
130 CloseHandle(hMapObject); |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
131 } |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
132 |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
133 int WINAPI DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved) { |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
134 switch(dwReason) { |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
135 case DLL_PROCESS_ATTACH: |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
136 g_hInstance = hInstance; |
4548
ae85f27e4948
[gaim-migrate @ 4827]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
4533
diff
changeset
|
137 g_point.x = 0; |
ae85f27e4948
[gaim-migrate @ 4827]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
4533
diff
changeset
|
138 g_point.y = 0; |
4533
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
139 break; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
140 case DLL_PROCESS_DETACH: |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
141 break; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
142 } |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
143 return TRUE; |
516061abad03
[gaim-migrate @ 4812]
Herman Bloggs <hermanator12002@yahoo.com>
parents:
diff
changeset
|
144 } |