From 7654daaa6cf56a14c6a10fb4384a79c5ad750d8d Mon Sep 17 00:00:00 2001 From: Kirill Volinsky Date: Fri, 15 Mar 2013 09:00:59 +0000 Subject: added version info git-svn-id: http://svn.miranda-ng.org/main/trunk@4043 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/VersionInfo/VersionInfo_10.vcxproj | 13 +++-- plugins/VersionInfo/VersionInfo_10.vcxproj.filters | 15 ++++++ plugins/VersionInfo/VersionInfo_11.vcxproj | 13 +++-- plugins/VersionInfo/VersionInfo_11.vcxproj.filters | 15 ++++++ plugins/VersionInfo/res/resource.rc | 53 +++++--------------- plugins/VersionInfo/res/version.rc | 28 ++++------- plugins/VersionInfo/src/CPlugin.cpp | 4 -- plugins/VersionInfo/src/CPlugin.h | 12 ----- plugins/VersionInfo/src/CVersionInfo.cpp | 7 --- plugins/VersionInfo/src/CVersionInfo.h | 12 ----- plugins/VersionInfo/src/common.h | 57 +++++++++------------ plugins/VersionInfo/src/dlgHandlers.cpp | 1 - plugins/VersionInfo/src/dlgHandlers.h | 3 -- plugins/VersionInfo/src/hooked_events.cpp | 7 --- plugins/VersionInfo/src/main.cpp | 10 ++-- plugins/VersionInfo/src/services.cpp | 1 - plugins/VersionInfo/src/utils.cpp | 1 - plugins/VersionInfo/src/utils.h | 2 - plugins/VersionInfo/src/version.h | 58 ++++++---------------- 19 files changed, 112 insertions(+), 200 deletions(-) diff --git a/plugins/VersionInfo/VersionInfo_10.vcxproj b/plugins/VersionInfo/VersionInfo_10.vcxproj index e25ce41abe..88df90d99d 100644 --- a/plugins/VersionInfo/VersionInfo_10.vcxproj +++ b/plugins/VersionInfo/VersionInfo_10.vcxproj @@ -86,7 +86,7 @@ ..\..\include\msapi - imagehlp.lib;%(AdditionalDependencies) + version.lib;imagehlp.lib;%(AdditionalDependencies) true 0x25040000 false @@ -113,7 +113,7 @@ ..\..\include\msapi - imagehlp.lib;%(AdditionalDependencies) + version.lib;imagehlp.lib;%(AdditionalDependencies) true true true @@ -138,7 +138,7 @@ $(IntDir)$(TargetName).lib - imagehlp.lib;%(AdditionalDependencies) + version.lib;imagehlp.lib;%(AdditionalDependencies) true Windows 0x25040000 @@ -167,7 +167,7 @@ $(IntDir)$(TargetName).lib true true - imagehlp.lib;%(AdditionalDependencies) + version.lib;imagehlp.lib;%(AdditionalDependencies) true Windows 0x25040000 @@ -196,11 +196,16 @@ + + + + + diff --git a/plugins/VersionInfo/VersionInfo_10.vcxproj.filters b/plugins/VersionInfo/VersionInfo_10.vcxproj.filters index e84a5904c6..6905e385f8 100644 --- a/plugins/VersionInfo/VersionInfo_10.vcxproj.filters +++ b/plugins/VersionInfo/VersionInfo_10.vcxproj.filters @@ -56,10 +56,25 @@ Header Files + + Header Files + + + Header Files + + + Header Files + + + Header Files + Resource Files + + Resource Files + \ No newline at end of file diff --git a/plugins/VersionInfo/VersionInfo_11.vcxproj b/plugins/VersionInfo/VersionInfo_11.vcxproj index f7109d1457..60a2d4d91f 100644 --- a/plugins/VersionInfo/VersionInfo_11.vcxproj +++ b/plugins/VersionInfo/VersionInfo_11.vcxproj @@ -90,7 +90,7 @@ ..\..\include\msapi - imagehlp.lib;%(AdditionalDependencies) + version.lib;imagehlp.lib;%(AdditionalDependencies) true 0x25040000 false @@ -117,7 +117,7 @@ ..\..\include\msapi - imagehlp.lib;%(AdditionalDependencies) + version.lib;imagehlp.lib;%(AdditionalDependencies) true true true @@ -142,7 +142,7 @@ $(IntDir)$(TargetName).lib - imagehlp.lib;%(AdditionalDependencies) + version.lib;imagehlp.lib;%(AdditionalDependencies) true Windows 0x25040000 @@ -171,7 +171,7 @@ $(IntDir)$(TargetName).lib true true - imagehlp.lib;%(AdditionalDependencies) + version.lib;imagehlp.lib;%(AdditionalDependencies) true Windows 0x25040000 @@ -200,11 +200,16 @@ + + + + + diff --git a/plugins/VersionInfo/VersionInfo_11.vcxproj.filters b/plugins/VersionInfo/VersionInfo_11.vcxproj.filters index e84a5904c6..6905e385f8 100644 --- a/plugins/VersionInfo/VersionInfo_11.vcxproj.filters +++ b/plugins/VersionInfo/VersionInfo_11.vcxproj.filters @@ -56,10 +56,25 @@ Header Files + + Header Files + + + Header Files + + + Header Files + + + Header Files + Resource Files + + Resource Files + \ No newline at end of file diff --git a/plugins/VersionInfo/res/resource.rc b/plugins/VersionInfo/res/resource.rc index 770540d99a..9af9a50df0 100644 --- a/plugins/VersionInfo/res/resource.rc +++ b/plugins/VersionInfo/res/resource.rc @@ -47,46 +47,6 @@ BEGIN COMBOBOX IDC_ASK_BOLDCOMBOBOX,167,104,54,47,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP END - -///////////////////////////////////////////////////////////////////////////// -// -// DESIGNINFO -// - -#ifdef APSTUDIO_INVOKED -GUIDELINES DESIGNINFO -BEGIN - IDD_ASKDIALOG, DIALOG - BEGIN - LEFTMARGIN, 7 - RIGHTMARGIN, 224 - VERTGUIDE, 15 - VERTGUIDE, 221 - TOPMARGIN, 7 - BOTTOMMARGIN, 139 - HORZGUIDE, 116 - END -END -#endif // APSTUDIO_INVOKED - -#endif // English (U.S.) resources -///////////////////////////////////////////////////////////////////////////// - - -///////////////////////////////////////////////////////////////////////////// -// Italian (Italy) resources - -#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ITA) -#ifdef _WIN32 -LANGUAGE LANG_ITALIAN, SUBLANG_ITALIAN -#pragma code_page(1252) -#endif //_WIN32 - -///////////////////////////////////////////////////////////////////////////// -// -// Dialog -// - IDD_OPT_VERSIONINFO DIALOGEX 0, 0, 315, 222 STYLE DS_SETFONT | DS_MODALFRAME | DS_3DLOOK | DS_FIXEDSYS | DS_CENTER | WS_POPUP | WS_VISIBLE EXSTYLE WS_EX_CONTROLPARENT @@ -148,6 +108,17 @@ END #ifdef APSTUDIO_INVOKED GUIDELINES DESIGNINFO BEGIN + IDD_ASKDIALOG, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 224 + VERTGUIDE, 15 + VERTGUIDE, 221 + TOPMARGIN, 7 + BOTTOMMARGIN, 139 + HORZGUIDE, 116 + END + IDD_OPT_VERSIONINFO, DIALOG BEGIN LEFTMARGIN, 5 @@ -208,7 +179,7 @@ END // Icon with lowest ID value placed first to ensure application icon // remains consistent on all systems. IDI_MAIN ICON "VersionInfo.ico" -#endif // Italian (Italy) resources +#endif // English (U.S.) resources ///////////////////////////////////////////////////////////////////////////// diff --git a/plugins/VersionInfo/res/version.rc b/plugins/VersionInfo/res/version.rc index f691628164..5bfbab4754 100644 --- a/plugins/VersionInfo/res/version.rc +++ b/plugins/VersionInfo/res/version.rc @@ -4,17 +4,12 @@ #error this file is not editable by Microsoft Visual C++ #endif //APSTUDIO_INVOKED -#include "..\src\version.h" #include "afxres.h" - -///////////////////////////////////////////////////////////////////////////// -// -// Version -// +#include "..\src\version.h" VS_VERSION_INFO VERSIONINFO - FILEVERSION __PLUGINVERSION_STRING - PRODUCTVERSION __PLUGINVERSION_STRING + FILEVERSION __FILEVERSION_STRING + PRODUCTVERSION __FILEVERSION_STRING FILEFLAGSMASK 0x17L #ifdef _DEBUG FILEFLAGS 0x1L @@ -22,25 +17,22 @@ VS_VERSION_INFO VERSIONINFO FILEFLAGS 0x0L #endif FILEOS 0x4L - FILETYPE 0x2L + FILETYPE 0x0L FILESUBTYPE 0x0L BEGIN BLOCK "StringFileInfo" BEGIN - BLOCK "040904b0" + BLOCK "000004b0" BEGIN - VALUE "Author", __AUTHOR - VALUE "FileDescription", __DESC - VALUE "FileVersion", __VERSION_STRING - VALUE "InternalName", __PLUGIN_DISPLAY_NAME + VALUE "FileDescription", __DESCRIPTION + VALUE "InternalName", __PLUGIN_NAME VALUE "LegalCopyright", __COPYRIGHT + VALUE "OriginalFilename", __FILENAME + VALUE "ProductName", __PLUGIN_NAME END END BLOCK "VarFileInfo" BEGIN - VALUE "Translation", 0x409, 1200 + VALUE "Translation", 0x0, 1200 END END - -#endif // English (U.S.) resources -///////////////////////////////////////////////////////////////////////////// diff --git a/plugins/VersionInfo/src/CPlugin.cpp b/plugins/VersionInfo/src/CPlugin.cpp index 54d762064a..8e1a57399b 100644 --- a/plugins/VersionInfo/src/CPlugin.cpp +++ b/plugins/VersionInfo/src/CPlugin.cpp @@ -18,12 +18,8 @@ along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "CPlugin.h" - #include "common.h" -#pragma comment(lib, "version.lib") - const int cPLUGIN_UUID_MARK = 4; TCHAR PLUGIN_UUID_MARK[cPLUGIN_UUID_MARK]; diff --git a/plugins/VersionInfo/src/CPlugin.h b/plugins/VersionInfo/src/CPlugin.h index 5da1b1dc6b..32b564653c 100644 --- a/plugins/VersionInfo/src/CPlugin.h +++ b/plugins/VersionInfo/src/CPlugin.h @@ -22,18 +22,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #ifndef CPLUGIN_H #define CPLUGIN_H -//#define STRICT -#define WIN32_LEAN_AND_MEAN - -#define _CRT_SECURE_NO_DEPRECATE - -#include -#include - -#ifndef M_NEWPLUGINAPI_H__ - #include "newpluginapi.h" -#endif - #define DEF_UUID_CHARMARK "¤" extern const int cPLUGIN_UUID_MARK; diff --git a/plugins/VersionInfo/src/CVersionInfo.cpp b/plugins/VersionInfo/src/CVersionInfo.cpp index e26a6dc233..c67099874f 100644 --- a/plugins/VersionInfo/src/CVersionInfo.cpp +++ b/plugins/VersionInfo/src/CVersionInfo.cpp @@ -18,14 +18,7 @@ along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ - -#include "CVersionInfo.h" -//#include "AggressiveOptimize.h" - #include "common.h" -#include "resource.h" - -//using namespace std; BOOL (WINAPI *MyGetDiskFreeSpaceEx)(LPCTSTR, PULARGE_INTEGER, PULARGE_INTEGER, PULARGE_INTEGER); BOOL (WINAPI *MyIsWow64Process)(HANDLE, PBOOL); diff --git a/plugins/VersionInfo/src/CVersionInfo.h b/plugins/VersionInfo/src/CVersionInfo.h index eb55b808fc..8f78fc382d 100644 --- a/plugins/VersionInfo/src/CVersionInfo.h +++ b/plugins/VersionInfo/src/CVersionInfo.h @@ -21,22 +21,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #ifndef CVERSIONINFO_H #define CVERSIONINFO_H -//#define STRICT -#define WIN32_LEAN_AND_MEAN -//#include "AggressiveOptimize.h" - -#define _CRT_SECURE_NO_DEPRECATE - #ifndef PF_NX_ENABLED #define PF_NX_ENABLED 12 #endif -#include -#include -//using namespace std; - -#include "CPlugin.h" - class CVersionInfo { private: diff --git a/plugins/VersionInfo/src/common.h b/plugins/VersionInfo/src/common.h index cbbf057daa..c446a76469 100644 --- a/plugins/VersionInfo/src/common.h +++ b/plugins/VersionInfo/src/common.h @@ -18,55 +18,46 @@ along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#define STRICT -#define WIN32_LEAN_AND_MEAN - #ifndef M_VERSIONINFO_COMMON_H #define M_VERSIONINFO_COMMON_H -#pragma warning(disable:4005) -#define _CRT_SECURE_NO_DEPRECATE -#pragma warning(default:4005) - -#define VIPF_NONE 0x0000 -#define VIPF_UNCERTAIN 0x0010 +#define STRICT +#define WIN32_LEAN_AND_MEAN -#define VISF_FORUMSTYLE 0x0001 -#define VISF_SHOWUUID 0x0002 -#define VISF_SHOWFLAGS 0x0004 +#define _CRT_SECURE_NO_DEPRECATE #include -#include - #include -#include #include -#include +#include +#include -#include -//using namespace std; +#include +#include +#include +#include +#include +#include +#include -#include "version.h" +#include +#include -#include "m_versioninfo.h" +#include "CPlugin.h" +#include "version.h" #include "hooked_events.h" #include "services.h" #include "dlgHandlers.h" +#include "utils.h" +#include "CVersionInfo.h" +#include "resource.h" -#include "newpluginapi.h" -#include "m_system.h" -#include "m_langpack.h" -#include "m_database.h" -#include "m_skin.h" -#include "m_clist.h" -#include "m_options.h" -#include "m_popup.h" - -#include "m_utils.h" -#include "m_folders.h" -#include "win2k.h" +#define VIPF_NONE 0x0000 +#define VIPF_UNCERTAIN 0x0010 -#include "utils.h" +#define VISF_FORUMSTYLE 0x0001 +#define VISF_SHOWUUID 0x0002 +#define VISF_SHOWFLAGS 0x0004 #ifndef MS_DB_GETPROFILEPATH_BASIC //db3xSA #define MS_DB_GETPROFILEPATH_BASIC "DB/GetProfilePathBasic" diff --git a/plugins/VersionInfo/src/dlgHandlers.cpp b/plugins/VersionInfo/src/dlgHandlers.cpp index 733a4cd3dc..3fb436b04e 100644 --- a/plugins/VersionInfo/src/dlgHandlers.cpp +++ b/plugins/VersionInfo/src/dlgHandlers.cpp @@ -19,7 +19,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #include "common.h" -#include "dlgHandlers.h" const char *szQuoteStrings[] = {"[quote] | [/quote]", "[code] | [/code]", ""}; const char *szSizeStrings[] = {"[size=1] | [/size]", "[size=1px] | [/size]", "[size=12] | [/size]", "[size=80] | [/size]", ""}; diff --git a/plugins/VersionInfo/src/dlgHandlers.h b/plugins/VersionInfo/src/dlgHandlers.h index bab1876ea2..b2a66f014c 100644 --- a/plugins/VersionInfo/src/dlgHandlers.h +++ b/plugins/VersionInfo/src/dlgHandlers.h @@ -21,9 +21,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #ifndef M_VERSIONINFO_DLGHEADERS_H #define M_VERSIONINFO_DLGHEADERS_H -#include "resource.h" -#include "CVersionInfo.h" - #define TO_ASK 0 #define TO_FILE 1 #define TO_MESSAGEBOX 2 diff --git a/plugins/VersionInfo/src/hooked_events.cpp b/plugins/VersionInfo/src/hooked_events.cpp index 2173fff405..9d0aa826c2 100644 --- a/plugins/VersionInfo/src/hooked_events.cpp +++ b/plugins/VersionInfo/src/hooked_events.cpp @@ -19,13 +19,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #include "common.h" -#include "hooked_events.h" - -#define HOST "http://eblis.tla.ro/projects" - -#define VERSIONINFO_VERSION_URL HOST "/miranda/VersionInfo/updater/VersionInfo.html" -#define VERSIONINFO_UPDATE_URL HOST "/miranda/VersionInfo/updater/VersionInfo.zip" -#define VERSIONINFO_VERSION_PREFIX "Version Information version " int HookEvents() { diff --git a/plugins/VersionInfo/src/main.cpp b/plugins/VersionInfo/src/main.cpp index f9143d34c7..63d9b51339 100644 --- a/plugins/VersionInfo/src/main.cpp +++ b/plugins/VersionInfo/src/main.cpp @@ -20,8 +20,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include "common.h" -#include "CVersionInfo.h" - HINSTANCE hInst; int hLangpack; @@ -46,15 +44,15 @@ char ModuleName[] = "VersionInfo"; PLUGININFOEX pluginInfo={ sizeof(PLUGININFOEX), - __PLUGIN_DISPLAY_NAME, - VERSION, - __DESC, + __PLUGIN_NAME, + PLUGIN_MAKE_VERSION(__MAJOR_VERSION, __MINOR_VERSION, __RELEASE_NUM, __BUILD_NUM), + __DESCRIPTION, __AUTHOR, __AUTHOREMAIL, __COPYRIGHT, __AUTHORWEB, UNICODE_AWARE, - // {2f174488-489c-4fe1-940d-596cf0f35e65} + // {2F174488-489C-4FE1-940D-596CF0F35E65} {0x2f174488, 0x489c, 0x4fe1, {0x94, 0x0d, 0x59, 0x6c, 0xf0, 0xf3, 0x5e, 0x65}} }; diff --git a/plugins/VersionInfo/src/services.cpp b/plugins/VersionInfo/src/services.cpp index d78810637a..2f7ad03534 100644 --- a/plugins/VersionInfo/src/services.cpp +++ b/plugins/VersionInfo/src/services.cpp @@ -19,7 +19,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #include "common.h" -#include "services.h" int bServiceMode = 0; //true only if plugin is running in service mode diff --git a/plugins/VersionInfo/src/utils.cpp b/plugins/VersionInfo/src/utils.cpp index b89eb94a46..1822880a3f 100644 --- a/plugins/VersionInfo/src/utils.cpp +++ b/plugins/VersionInfo/src/utils.cpp @@ -21,7 +21,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. //#define USE_LOG_FUNCTIONS #include "common.h" -#include "utils.h" /* My usual MessageBoxes :-) diff --git a/plugins/VersionInfo/src/utils.h b/plugins/VersionInfo/src/utils.h index 5db4b1a811..9f8bf4a653 100644 --- a/plugins/VersionInfo/src/utils.h +++ b/plugins/VersionInfo/src/utils.h @@ -1,8 +1,6 @@ #ifndef _M_VERSIONINFO_UTILS_H #define _M_VERSIONINFO_UTILS_H -#include "common.h" - //utils.cpp void MB(const TCHAR*); void Log(const TCHAR*); diff --git a/plugins/VersionInfo/src/version.h b/plugins/VersionInfo/src/version.h index 69771bb202..490f827307 100644 --- a/plugins/VersionInfo/src/version.h +++ b/plugins/VersionInfo/src/version.h @@ -1,44 +1,14 @@ -/* -Version information plugin for Miranda IM - -Copyright © 2002-2005 Luca Santarelli, © 2005-2008 Cristian Libotean - -This program is free software; you can redistribute it and/or -modify it under the terms of the GNU General Public License -as published by the Free Software Foundation; either version 2 -of the License, or (at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -*/ - -#ifndef M_VERSIONINFO_VERSION_H -#define M_VERSIONINFO_VERSION_H - -#define __MAJOR_VERSION 1 -#define __MINOR_VERSION 5 -#define __RELEASE_NUM 0 -#define __BUILD_NUM 3 - -#define VERSION PLUGIN_MAKE_VERSION(__MAJOR_VERSION, __MINOR_VERSION, __RELEASE_NUM, __BUILD_NUM) - -#define __PLUGINVERSION_STRING __MAJOR_VERSION,__MINOR_VERSION,__RELEASE_NUM,__BUILD_NUM -#define __PLUGINVERSION_STRING_DOTS __MAJOR_VERSION.__MINOR_VERSION.__RELEASE_NUM.__BUILD_NUM -#define __STRINGIFY_(x) #x -#define __STRINGIFY(x) __STRINGIFY_(x) -#define __VERSION_STRING __STRINGIFY(__PLUGINVERSION_STRING_DOTS) - -#define __DESC "Collects and prints information related to Miranda, the plugins and the OS." -#define __AUTHOR "Luca Santarelli, Cristian Libotean, George Hazan" -#define __AUTHOREMAIL "hrk@users.sourceforge.net, eblis102@yahoo.com, ghazan@miranda.im" -#define __COPYRIGHT "© 2002-2005 Luca Santarelli, © 2005-2009 Cristian Libotean" -#define __AUTHORWEB "http://miranda-ng.org/" -#define __PLUGIN_DISPLAY_NAME "Version Information" - -#endif //M_VERSIONINFO_VERSION_H +#define __MAJOR_VERSION 1 +#define __MINOR_VERSION 5 +#define __RELEASE_NUM 0 +#define __BUILD_NUM 3 + +#define __FILEVERSION_STRING __MAJOR_VERSION,__MINOR_VERSION,__RELEASE_NUM,__BUILD_NUM + +#define __PLUGIN_NAME "Version information" +#define __FILENAME "VersionInfo.dll" +#define __DESCRIPTION "Collects and prints information related to Miranda, the plugins and the OS." +#define __AUTHOR "Luca Santarelli, Cristian Libotean, George Hazan" +#define __AUTHOREMAIL "hrk@users.sourceforge.net, eblis102@yahoo.com, ghazan@miranda.im" +#define __AUTHORWEB "http://miranda-ng.org/" +#define __COPYRIGHT "© 2002-2005 Luca Santarelli, 2005-2009 Cristian Libotean" -- cgit v1.2.3