diff options
author | George Hazan <george.hazan@gmail.com> | 2013-06-27 12:41:48 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2013-06-27 12:41:48 +0000 |
commit | 79a1a399448f6942966054a347b1125bf38a3b68 (patch) | |
tree | 14297e0f02869d6bae44056807870342e31651fa /plugins/YAPP/src | |
parent | d114b204282ced93e141c4a95fb11ccdb5cee45c (diff) |
switch from custom YAPP constants to ones from m_popup.h
git-svn-id: http://svn.miranda-ng.org/main/trunk@5150 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/YAPP/src')
-rw-r--r-- | plugins/YAPP/src/common.h | 6 | ||||
-rw-r--r-- | plugins/YAPP/src/popwin.cpp | 10 |
2 files changed, 5 insertions, 11 deletions
diff --git a/plugins/YAPP/src/common.h b/plugins/YAPP/src/common.h index ed6370c42b..209c441358 100644 --- a/plugins/YAPP/src/common.h +++ b/plugins/YAPP/src/common.h @@ -89,10 +89,4 @@ typedef int (CALLBACK *PFNLVCOMPARE)(LPARAM, LPARAM, LPARAM); #define PDF_TCHAR PDF_UNICODE
-// windowProc messages
-#define PM_INIT (WM_USER + 0x0202) // message sent to your windowProc after the window has been initialized
-#define PM_DIENOTIFY (WM_USER + 0x0200) // message sent to your windowProc just before the window is destroyed (can be used e.g. to free your opaque data)
-
-#define PM_DESTROY (WM_USER + 0x0201) // send to the popup hWnd (use PostMessage generally, or SendMessage inside your windowProc) to kill it
-
void ShowPopup(PopupData &pd_in);
\ No newline at end of file diff --git a/plugins/YAPP/src/popwin.cpp b/plugins/YAPP/src/popwin.cpp index 15b48f7f31..5e2a766daf 100644 --- a/plugins/YAPP/src/popwin.cpp +++ b/plugins/YAPP/src/popwin.cpp @@ -288,7 +288,7 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa }
}
#endif
- PostMessage(hwnd, PM_INIT, (WPARAM)hwnd, 0);
+ PostMessage(hwnd, UM_INITPOPUP, (WPARAM)hwnd, 0);
return 0;
case WM_MOUSEMOVE:
if (pwd && !pwd->mouse_in) {
@@ -316,7 +316,7 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa if (pwd->mouse_in || (options.global_hover && global_mouse_in))
SetTimer(hwnd, ID_CLOSETIMER, 800, 0); // reset timer if mouse in window - allow another 800 ms
else {
- PostMessage(hwnd, PM_DESTROY, 0, 0);
+ PostMessage(hwnd, UM_DESTROYPOPUP, 0, 0);
}
return TRUE;
} else if (wParam == ID_MOVETIMER) {
@@ -525,7 +525,7 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa RemoveWindowFromStack(hwnd);
- SendMessage(hwnd, PM_DIENOTIFY, 0, 0);
+ SendMessage(hwnd, UM_FREEPLUGINDATA, 0, 0);
if (pd) {
pd->SetIcon(NULL);
@@ -729,7 +729,7 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa return TRUE;
// drop through
- case PM_DESTROY:
+ case UM_DESTROYPOPUP:
PostMPMessage(MUM_DELETEPOPUP, 0, (LPARAM)hwnd);
return TRUE;
}
@@ -739,7 +739,7 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa // provide a way to close popups, if no PluginWindowProc is provided
if (uMsg == WM_CONTEXTMENU) {
- SendMessage(hwnd, PM_DESTROY, 0, 0);
+ SendMessage(hwnd, UM_DESTROYPOPUP, 0, 0);
return TRUE;
}
|