From 809aa14dd2119e7b0de93846eb38bbb83073dad6 Mon Sep 17 00:00:00 2001 From: Kirill Volinsky Date: Thu, 14 Mar 2013 08:11:57 +0000 Subject: removed not used headers m_yapp.h moved to ExtAPI git-svn-id: http://svn.miranda-ng.org/main/trunk@4013 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/ExternalAPI/m_yapp.h | 29 +++++++++++++++++++++ plugins/YAPP/res/version.rc | 14 +++++----- plugins/YAPP/res/yapp.rc | 16 ++---------- plugins/YAPP/src/common.h | 48 ++++++++++------------------------- plugins/YAPP/src/m_yapp.h | 29 --------------------- plugins/YAPP/src/message_pump.cpp | 4 --- plugins/YAPP/src/message_pump.h | 25 ++++++++++++++++++ plugins/YAPP/src/notify_imp.cpp | 4 --- plugins/YAPP/src/options.cpp | 4 --- plugins/YAPP/src/popwin.cpp | 3 --- plugins/YAPP/src/services.cpp | 5 ---- plugins/YAPP/src/version.h | 24 +++++------------- plugins/YAPP/src/yapp.cpp | 15 +++-------- plugins/YAPP/src/yapp_history.cpp | 1 - plugins/YAPP/src/yapp_history.h | 2 -- plugins/YAPP/src/yapp_history_dlg.cpp | 2 -- plugins/YAPP/yapp_10.vcxproj | 8 +++--- plugins/YAPP/yapp_11.vcxproj | 8 +++--- 18 files changed, 96 insertions(+), 145 deletions(-) create mode 100644 plugins/ExternalAPI/m_yapp.h delete mode 100644 plugins/YAPP/src/m_yapp.h diff --git a/plugins/ExternalAPI/m_yapp.h b/plugins/ExternalAPI/m_yapp.h new file mode 100644 index 0000000000..26d9be0e2e --- /dev/null +++ b/plugins/ExternalAPI/m_yapp.h @@ -0,0 +1,29 @@ +#ifndef __m_yapp_h__ +#define __m_yapp_h__ + +#define NFOPT_POPUP2_BACKCOLOR "Popup2/BackColor" +#define NFOPT_POPUP2_TEXTCOLOR "Popup2/TextColor" +#define NFOPT_POPUP2_TIMEOUT "Popup2/Timeout" +#define NFOPT_POPUP2_LCLICKSVC "Popup2/LClickSvc" +#define NFOPT_POPUP2_LCLICKCOOKIE "Popup2/LClickCookie" +#define NFOPT_POPUP2_RCLICKSVC "Popup2/RClickSvc" +#define NFOPT_POPUP2_RCLICKCOOKIE "Popup2/RClickCookie" +#define NFOPT_POPUP2_STATUSMODE "Popup2/StatusMode" +#define NFOPT_POPUP2_PLUGINDATA "Popup2/PluginData" +#define NFOPT_POPUP2_WNDPROC "Popup2/WndProc" + +#define NFOPT_POPUP2_BACKCOLOR_S "Popup2/BackColor/Save" +#define NFOPT_POPUP2_TEXTCOLOR_S "Popup2/TextColor/Save" +#define NFOPT_POPUP2_TIMEOUT_S "Popup2/Timeout/Save" + +#define MS_POPUP2_SHOW "Popup2/Show" +#define MS_POPUP2_UPDATE "Popup2/Update" +#define MS_POPUP2_REMOVE "Popup2/Remove" + +#ifndef POPUP2_NOHELPERS + #define MPopup2Show(a) (CallService(MS_POPUP2_SHOW, 0, (LPARAM)(a))) + #define MPopup2Update(a) (CallService(MS_POPUP2_UPDATE, 0, (LPARAM)(a))) + #define MPopup2Remove(a) (CallService(MS_POPUP2_REMOVE, 0, (LPARAM)(a))) +#endif + +#endif // __m_yapp_h__ diff --git a/plugins/YAPP/res/version.rc b/plugins/YAPP/res/version.rc index 3ad9c3a4b3..5bfbab4754 100644 --- a/plugins/YAPP/res/version.rc +++ b/plugins/YAPP/res/version.rc @@ -1,32 +1,34 @@ +// Microsoft Visual C++ generated resource script. +// #ifdef APSTUDIO_INVOKED #error this file is not editable by Microsoft Visual C++ #endif //APSTUDIO_INVOKED -#include +#include "afxres.h" #include "..\src\version.h" VS_VERSION_INFO VERSIONINFO FILEVERSION __FILEVERSION_STRING PRODUCTVERSION __FILEVERSION_STRING - FILEFLAGSMASK 0x3fL + FILEFLAGSMASK 0x17L #ifdef _DEBUG FILEFLAGS 0x1L #else FILEFLAGS 0x0L #endif - FILEOS 0x40004L - FILETYPE 0x1L + FILEOS 0x4L + FILETYPE 0x0L FILESUBTYPE 0x0L BEGIN BLOCK "StringFileInfo" BEGIN BLOCK "000004b0" BEGIN - VALUE "Author", __AUTHOR - VALUE "FileDescription", __DESC + VALUE "FileDescription", __DESCRIPTION VALUE "InternalName", __PLUGIN_NAME VALUE "LegalCopyright", __COPYRIGHT VALUE "OriginalFilename", __FILENAME + VALUE "ProductName", __PLUGIN_NAME END END BLOCK "VarFileInfo" diff --git a/plugins/YAPP/res/yapp.rc b/plugins/YAPP/res/yapp.rc index 18421e003e..1bbcc4526c 100644 --- a/plugins/YAPP/res/yapp.rc +++ b/plugins/YAPP/res/yapp.rc @@ -29,7 +29,7 @@ LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US 1 TEXTINCLUDE BEGIN - "resource.h\0" + "..\\src\\resource.h\0" END 2 TEXTINCLUDE @@ -46,18 +46,6 @@ END #endif // APSTUDIO_INVOKED -#endif // English (U.S.) resources -///////////////////////////////////////////////////////////////////////////// - - -///////////////////////////////////////////////////////////////////////////// -// English (Australia) resources - -#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENA) -#ifdef _WIN32 -LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_AUS -#pragma code_page(1252) -#endif //_WIN32 ///////////////////////////////////////////////////////////////////////////// // @@ -190,7 +178,7 @@ END // Icon with lowest ID value placed first to ensure application icon // remains consistent on all systems. IDI_POPUP_HISTORY ICON "PPh2.ico" -#endif // English (Australia) resources +#endif // English (U.S.) resources ///////////////////////////////////////////////////////////////////////////// diff --git a/plugins/YAPP/src/common.h b/plugins/YAPP/src/common.h index e8aa204340..e4973da944 100644 --- a/plugins/YAPP/src/common.h +++ b/plugins/YAPP/src/common.h @@ -26,28 +26,20 @@ #endif -#include - #define WIN32_LEAN_AND_MEAN // Exclude rarely-used stuff from Windows headers -// Windows Header Files: + #include #include #include - -#define MIRANDA_VER 0x0A00 +#include #include -#include #include #include #include -#include -#include -#include #include #include #include -#include #include #include #include @@ -55,6 +47,17 @@ #include #include +#include +#include //need this for special renderers + +#include "version.h" +#include "message_pump.h" +#include "options.h" +#include "popwin.h" +#include "notify.h" +#include "services.h" +#include "resource.h" +#include "yapp_history.h" #define MODULE "YAPP" @@ -80,31 +83,6 @@ typedef int (CALLBACK *PFNLVCOMPARE)(LPARAM, LPARAM, LPARAM); #endif -struct PopupData -{ - int cbSize; - int flags; // OR of PDF_* flags below - HANDLE hContact; - HICON hIcon; - union { - char *pszTitle; - TCHAR *ptzTitle; - wchar_t *pwzTitle; - }; - union { - char *pszText; - TCHAR *ptzText; - wchar_t *pwzText; - }; - COLORREF colorBack; // if colorBack and colorText are equal, defaults will be used - COLORREF colorText; - WNDPROC windowProc; // optional custom window procedure - int timeout; // -1 == infinite, 0 == default, otherwise timeout in seconds - void *opaque; - - void SetIcon(HICON); -}; - #define PDF_UNICODE 0x0001 #define PDF_ICOLIB 0x0002 diff --git a/plugins/YAPP/src/m_yapp.h b/plugins/YAPP/src/m_yapp.h deleted file mode 100644 index 26d9be0e2e..0000000000 --- a/plugins/YAPP/src/m_yapp.h +++ /dev/null @@ -1,29 +0,0 @@ -#ifndef __m_yapp_h__ -#define __m_yapp_h__ - -#define NFOPT_POPUP2_BACKCOLOR "Popup2/BackColor" -#define NFOPT_POPUP2_TEXTCOLOR "Popup2/TextColor" -#define NFOPT_POPUP2_TIMEOUT "Popup2/Timeout" -#define NFOPT_POPUP2_LCLICKSVC "Popup2/LClickSvc" -#define NFOPT_POPUP2_LCLICKCOOKIE "Popup2/LClickCookie" -#define NFOPT_POPUP2_RCLICKSVC "Popup2/RClickSvc" -#define NFOPT_POPUP2_RCLICKCOOKIE "Popup2/RClickCookie" -#define NFOPT_POPUP2_STATUSMODE "Popup2/StatusMode" -#define NFOPT_POPUP2_PLUGINDATA "Popup2/PluginData" -#define NFOPT_POPUP2_WNDPROC "Popup2/WndProc" - -#define NFOPT_POPUP2_BACKCOLOR_S "Popup2/BackColor/Save" -#define NFOPT_POPUP2_TEXTCOLOR_S "Popup2/TextColor/Save" -#define NFOPT_POPUP2_TIMEOUT_S "Popup2/Timeout/Save" - -#define MS_POPUP2_SHOW "Popup2/Show" -#define MS_POPUP2_UPDATE "Popup2/Update" -#define MS_POPUP2_REMOVE "Popup2/Remove" - -#ifndef POPUP2_NOHELPERS - #define MPopup2Show(a) (CallService(MS_POPUP2_SHOW, 0, (LPARAM)(a))) - #define MPopup2Update(a) (CallService(MS_POPUP2_UPDATE, 0, (LPARAM)(a))) - #define MPopup2Remove(a) (CallService(MS_POPUP2_REMOVE, 0, (LPARAM)(a))) -#endif - -#endif // __m_yapp_h__ diff --git a/plugins/YAPP/src/message_pump.cpp b/plugins/YAPP/src/message_pump.cpp index 421be2d433..3c2d297d92 100644 --- a/plugins/YAPP/src/message_pump.cpp +++ b/plugins/YAPP/src/message_pump.cpp @@ -1,8 +1,4 @@ #include "common.h" -#include "message_pump.h" -#include "popwin.h" -#include "services.h" -#include "options.h" unsigned message_pump_thread_id = 0; int num_popups = 0; diff --git a/plugins/YAPP/src/message_pump.h b/plugins/YAPP/src/message_pump.h index 70671b157a..6acb371080 100644 --- a/plugins/YAPP/src/message_pump.h +++ b/plugins/YAPP/src/message_pump.h @@ -11,6 +11,31 @@ void PostMPMessage(UINT msg, WPARAM, LPARAM); #define MUM_NMREMOVE (WM_USER + 0x014) #define MUM_NMAVATAR (WM_USER + 0x015) +struct PopupData +{ + int cbSize; + int flags; // OR of PDF_* flags below + HANDLE hContact; + HICON hIcon; + union { + char *pszTitle; + TCHAR *ptzTitle; + wchar_t *pwzTitle; + }; + union { + char *pszText; + TCHAR *ptzText; + wchar_t *pwzText; + }; + COLORREF colorBack; // if colorBack and colorText are equal, defaults will be used + COLORREF colorText; + WNDPROC windowProc; // optional custom window procedure + int timeout; // -1 == infinite, 0 == default, otherwise timeout in seconds + void *opaque; + + void SetIcon(HICON); +}; + // given a popup data pointer, and a handle to an event, this function // will post a message to the message queue which will set the hwnd value // and then set the event...so create an event, call this function and then wait on the event diff --git a/plugins/YAPP/src/notify_imp.cpp b/plugins/YAPP/src/notify_imp.cpp index 131df92bf7..be2e14cdc1 100644 --- a/plugins/YAPP/src/notify_imp.cpp +++ b/plugins/YAPP/src/notify_imp.cpp @@ -1,8 +1,4 @@ #include "common.h" -#include "resource.h" -#include "notify.h" -#include "message_pump.h" -#include "m_yapp.h" HANDLE hhkShow=0, hhkUpdate=0, hhkRemove=0; diff --git a/plugins/YAPP/src/options.cpp b/plugins/YAPP/src/options.cpp index f2fafa9aa3..e8f06ceea2 100644 --- a/plugins/YAPP/src/options.cpp +++ b/plugins/YAPP/src/options.cpp @@ -1,8 +1,4 @@ #include "common.h" -#include "options.h" -#include "resource.h" -#include "popwin.h" -#include "services.h" Options options; diff --git a/plugins/YAPP/src/popwin.cpp b/plugins/YAPP/src/popwin.cpp index 3c0c4cd10d..0313ba6f30 100644 --- a/plugins/YAPP/src/popwin.cpp +++ b/plugins/YAPP/src/popwin.cpp @@ -1,7 +1,4 @@ #include "common.h" -#include "popwin.h" -#include "message_pump.h" -#include "options.h" HMODULE hUserDll; BOOL (WINAPI *MySetLayeredWindowAttributes)(HWND,COLORREF,BYTE,DWORD) = 0; diff --git a/plugins/YAPP/src/services.cpp b/plugins/YAPP/src/services.cpp index 372a4db2ce..8d5f962b69 100644 --- a/plugins/YAPP/src/services.cpp +++ b/plugins/YAPP/src/services.cpp @@ -1,9 +1,4 @@ #include "common.h" -#include "services.h" -#include "popwin.h" -#include "message_pump.h" -#include "resource.h" -#include "yapp_history.h" HANDLE hMenuShowHistory, hMenuToggleOnOff; diff --git a/plugins/YAPP/src/version.h b/plugins/YAPP/src/version.h index 48ea697f99..52c5791da7 100644 --- a/plugins/YAPP/src/version.h +++ b/plugins/YAPP/src/version.h @@ -1,24 +1,14 @@ -#ifndef __VERSION_H_INCLUDED -#define __VERSION_H_INCLUDED - #define __MAJOR_VERSION 0 #define __MINOR_VERSION 5 #define __RELEASE_NUM 0 #define __BUILD_NUM 10 #define __FILEVERSION_STRING __MAJOR_VERSION,__MINOR_VERSION,__RELEASE_NUM,__BUILD_NUM -#define __FILEVERSION_STRING_DOTS __MAJOR_VERSION.__MINOR_VERSION.__RELEASE_NUM.__BUILD_NUM -#define __STRINGIFY(x) #x -#define __VERSION_STRING __STRINGIFY(__FILEVERSION_STRING_DOTS) - -#define __DESC "Yet Another Popup Plugin - Provides popup notification window services to other plugins." -#define __AUTHOR "Scott Ellis" -#define __AUTHOREMAIL "mail@scottellis.com.au" -#define __COPYRIGHT "© 2005,2006 Scott Ellis" -#define __AUTHORWEB "http://miranda-ng.org/" - -#define __PLUGIN_NAME "YAPP" - -#define __FILENAME "yapp.dll" -#endif //__VERSION_H_INCLUDED +#define __PLUGIN_NAME "YAPP" +#define __FILENAME "YAPP.dll" +#define __DESCRIPTION "Yet Another Popup Plugin - Provides popup notification window services to other plugins." +#define __AUTHOR "Scott Ellis" +#define __AUTHOREMAIL "mail@scottellis.com.au" +#define __AUTHORWEB "http://miranda-ng.org/" +#define __COPYRIGHT "© 2005-2006 Scott Ellis" diff --git a/plugins/YAPP/src/yapp.cpp b/plugins/YAPP/src/yapp.cpp index b9aacd198b..cec66a0ee9 100644 --- a/plugins/YAPP/src/yapp.cpp +++ b/plugins/YAPP/src/yapp.cpp @@ -2,13 +2,6 @@ // #include "common.h" -#include "version.h" -#include "message_pump.h" -#include "options.h" -#include "popwin.h" -#include "notify.h" - -#include "yapp_history.h" //to be able to update the renderer HMODULE hInst = 0; @@ -30,17 +23,17 @@ PLUGININFOEX pluginInfo={ sizeof(PLUGININFOEX), __PLUGIN_NAME, PLUGIN_MAKE_VERSION(__MAJOR_VERSION, __MINOR_VERSION, __RELEASE_NUM, __BUILD_NUM), - __DESC, + __DESCRIPTION, __AUTHOR, __AUTHOREMAIL, __COPYRIGHT, __AUTHORWEB, UNICODE_AWARE, - // {EFD15F16-7AE4-40d7-A8E3-A411ED747BD5} - {0xefd15f16, 0x7ae4, 0x40d7, {0xa8, 0xe3, 0xa4, 0x11, 0xed, 0x74, 0x7b, 0xd5 }} + // {EFD15F16-7AE4-40D7-A8E3-A411ED747BD5} + {0xefd15f16, 0x7ae4, 0x40d7, {0xa8, 0xe3, 0xa4, 0x11, 0xed, 0x74, 0x7b, 0xd5}} }; -extern "C" BOOL APIENTRY DllMain( HMODULE hModule, DWORD ul_reason_for_call, LPVOID lpReserved) +BOOL WINAPI DllMain(HMODULE hModule, DWORD ul_reason_for_call, LPVOID lpReserved) { hInst = hModule; return TRUE; diff --git a/plugins/YAPP/src/yapp_history.cpp b/plugins/YAPP/src/yapp_history.cpp index d6b0c4b114..a7cfd70fc6 100644 --- a/plugins/YAPP/src/yapp_history.cpp +++ b/plugins/YAPP/src/yapp_history.cpp @@ -1,5 +1,4 @@ #include "common.h" -#include "yapp_history.h" PopupHistoryList::PopupHistoryList(int renderer) { diff --git a/plugins/YAPP/src/yapp_history.h b/plugins/YAPP/src/yapp_history.h index d527bc47f4..4927086b21 100644 --- a/plugins/YAPP/src/yapp_history.h +++ b/plugins/YAPP/src/yapp_history.h @@ -1,8 +1,6 @@ #ifndef __yapp_history_h__ #define __yapp_history_h__ -#include "m_ieview.h" //need this for special renderers - /****HISTORY ++ STUFF ***/ //there's no include file for h++ yet #ifndef MS_HPP_EG_WINDOW diff --git a/plugins/YAPP/src/yapp_history_dlg.cpp b/plugins/YAPP/src/yapp_history_dlg.cpp index 1904243df7..71457acc41 100644 --- a/plugins/YAPP/src/yapp_history_dlg.cpp +++ b/plugins/YAPP/src/yapp_history_dlg.cpp @@ -1,6 +1,4 @@ #include "common.h" -#include "resource.h" -#include "yapp_history.h" //************ Some helper resize stuff ****************** diff --git a/plugins/YAPP/yapp_10.vcxproj b/plugins/YAPP/yapp_10.vcxproj index e4a2dcccdd..986f02ef59 100644 --- a/plugins/YAPP/yapp_10.vcxproj +++ b/plugins/YAPP/yapp_10.vcxproj @@ -73,7 +73,7 @@ Disabled ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - WIN32;_DEBUG;_WINDOWS;_USRDLL;YAPP_EXPORTS;%(PreprocessorDefinitions) + WIN32;_DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) true EnableFastChecks MultiThreadedDebugDLL @@ -102,7 +102,7 @@ OnlyExplicitInline Size ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - WIN32;NDEBUG;_WINDOWS;_USRDLL;YAPP_EXPORTS;%(PreprocessorDefinitions) + WIN32;NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) true false Fast @@ -133,7 +133,7 @@ OnlyExplicitInline Size ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - WIN64;NDEBUG;_WINDOWS;_USRDLL;YAPP_EXPORTS;%(PreprocessorDefinitions) + WIN64;NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) true Level3 Use @@ -160,7 +160,7 @@ EnableFastChecks MultiThreadedDebugDLL ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - WIN64;_DEBUG;_WINDOWS;_USRDLL;YAPP_EXPORTS;%(PreprocessorDefinitions) + WIN64;_DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) Disabled Level3 Use diff --git a/plugins/YAPP/yapp_11.vcxproj b/plugins/YAPP/yapp_11.vcxproj index 18f139e202..24b5c8c198 100644 --- a/plugins/YAPP/yapp_11.vcxproj +++ b/plugins/YAPP/yapp_11.vcxproj @@ -77,7 +77,7 @@ Disabled ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - WIN32;_DEBUG;_WINDOWS;_USRDLL;YAPP_EXPORTS;%(PreprocessorDefinitions) + WIN32;_DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) true EnableFastChecks MultiThreadedDebugDLL @@ -106,7 +106,7 @@ OnlyExplicitInline Size ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - WIN32;NDEBUG;_WINDOWS;_USRDLL;YAPP_EXPORTS;%(PreprocessorDefinitions) + WIN32;NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) true false Fast @@ -137,7 +137,7 @@ OnlyExplicitInline Size ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - WIN64;NDEBUG;_WINDOWS;_USRDLL;YAPP_EXPORTS;%(PreprocessorDefinitions) + WIN64;NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) true Level3 Use @@ -164,7 +164,7 @@ EnableFastChecks MultiThreadedDebugDLL ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - WIN64;_DEBUG;_WINDOWS;_USRDLL;YAPP_EXPORTS;%(PreprocessorDefinitions) + WIN64;_DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) Disabled Level3 Use -- cgit v1.2.3