From f9eb107520e9dad37b06eb5c737b39d7bc15c751 Mon Sep 17 00:00:00 2001 From: Alexey Kulakov Date: Wed, 27 Jun 2012 17:22:43 +0000 Subject: Added File As Message plugin git-svn-id: http://svn.miranda-ng.org/main/trunk@655 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/FileAsMessage/m_Snapping_windows.h | 42 ++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 plugins/FileAsMessage/m_Snapping_windows.h (limited to 'plugins/FileAsMessage/m_Snapping_windows.h') diff --git a/plugins/FileAsMessage/m_Snapping_windows.h b/plugins/FileAsMessage/m_Snapping_windows.h new file mode 100644 index 0000000000..3aa505fe74 --- /dev/null +++ b/plugins/FileAsMessage/m_Snapping_windows.h @@ -0,0 +1,42 @@ +#ifndef SNAPPING_WINDOWS_H +#define SNAPPING_WINDOWS_H + +/* +If you want to use SnappingWindows in you plugin you should add this code in WindowProc: + +BOOL CALLBACK YouWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) +{ + CallSnappingWindowProc(hwnd,msg,wParam,lParam); + // + switch (msg) + { + case:..... + ........... + } + return ...... +} + + +*/ + +struct SnapWindowProc_t +{ + HWND hWnd; + // + SIZE m_szMoveOffset; + WPARAM wParam; + LPARAM lParam; + // + int Reserved1; + int Reserved2; + int Reserved3; +}; + +#define CallSnappingWindowProc(hwnd,nMessage,wParam,lParam) {static struct SnapWindowProc_t SnapInfo;\ + if ((nMessage == WM_MOVING) || (nMessage == WM_NCLBUTTONDOWN) || (nMessage == WM_SYSCOMMAND)){\ + SnapInfo.hWnd = hwnd;\ + SnapInfo.wParam = wParam;\ + SnapInfo.lParam = lParam;\ + CallService("Utils/SnapWindowProc",(WPARAM)&SnapInfo,nMessage);}} + +#endif //SNAPPING_WINDOWS_H \ No newline at end of file -- cgit v1.2.3