From 2521caf6cd5c4f7ad590f09a303c5ca4eb83c9a5 Mon Sep 17 00:00:00 2001 From: Vadim Dashevskiy Date: Sat, 25 Apr 2015 23:36:15 +0000 Subject: CrashDumper - common project git-svn-id: http://svn.miranda-ng.org/main/trunk@13156 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- bin10/mir_dev.sln | 2 +- bin10/mir_full.sln | 2 +- bin10/mir_full_pro.sln | 2 +- bin12/mir_dev.sln | 2 +- bin12/mir_full.sln | 2 +- plugins/CrashDumper/crshdmp.vcxproj | 33 ++++ plugins/CrashDumper/crshdmp.vcxproj.filters | 4 + plugins/CrashDumper/crshdmp_10.vcxproj | 229 ------------------------ plugins/CrashDumper/crshdmp_10.vcxproj.filters | 82 --------- plugins/CrashDumper/crshdmp_12.vcxproj | 232 ------------------------- plugins/CrashDumper/crshdmp_12.vcxproj.filters | 82 --------- plugins/CrashDumper/src/crshdmp.cpp | 2 +- plugins/CrashDumper/src/crshdmp_icons.cpp | 2 +- plugins/CrashDumper/src/dumper.cpp | 2 +- plugins/CrashDumper/src/exhndlr.cpp | 2 +- plugins/CrashDumper/src/stdafx.cpp | 18 -- plugins/CrashDumper/src/stdafx.cxx | 18 ++ plugins/CrashDumper/src/stdafx.h | 150 ++++++++++++++++ plugins/CrashDumper/src/ui.cpp | 2 +- plugins/CrashDumper/src/upload.cpp | 2 +- plugins/CrashDumper/src/utils.cpp | 2 +- plugins/CrashDumper/src/utils.h | 152 ---------------- 22 files changed, 217 insertions(+), 807 deletions(-) create mode 100644 plugins/CrashDumper/crshdmp.vcxproj create mode 100644 plugins/CrashDumper/crshdmp.vcxproj.filters delete mode 100644 plugins/CrashDumper/crshdmp_10.vcxproj delete mode 100644 plugins/CrashDumper/crshdmp_10.vcxproj.filters delete mode 100644 plugins/CrashDumper/crshdmp_12.vcxproj delete mode 100644 plugins/CrashDumper/crshdmp_12.vcxproj.filters delete mode 100644 plugins/CrashDumper/src/stdafx.cpp create mode 100644 plugins/CrashDumper/src/stdafx.cxx create mode 100644 plugins/CrashDumper/src/stdafx.h delete mode 100644 plugins/CrashDumper/src/utils.h diff --git a/bin10/mir_dev.sln b/bin10/mir_dev.sln index 498ef8ee43..91344938fc 100644 --- a/bin10/mir_dev.sln +++ b/bin10/mir_dev.sln @@ -265,7 +265,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "PasteIt", "..\plugins\Paste EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "SendSS", "..\plugins\SendScreenshotPlus\SendSS_10.vcxproj", "{CEAD8BCF-1F22-4E00-9F6D-E33405B00552}" EndProject -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CrashDumper", "..\plugins\CrashDumper\crshdmp_10.vcxproj", "{576EEEFD-E423-482B-879A-F0515D40B8E1}" +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CrashDumper", "..\plugins\CrashDumper\crshdmp.vcxproj", "{576EEEFD-E423-482B-879A-F0515D40B8E1}" EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DbEditorPP", "..\plugins\DbeditorPP\dbeditorpp_10.vcxproj", "{9C6040B8-1173-40FA-A3DB-DE044CCD8250}" EndProject diff --git a/bin10/mir_full.sln b/bin10/mir_full.sln index 0ee4b718d7..80cbd4c9f7 100644 --- a/bin10/mir_full.sln +++ b/bin10/mir_full.sln @@ -267,7 +267,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "SendSS", "..\plugins\SendSc EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DbEditorPP", "..\plugins\DbeditorPP\dbeditorpp_10.vcxproj", "{9C6040B8-1173-40FA-A3DB-DE044CCD8250}" EndProject -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CrashDumper", "..\plugins\CrashDumper\crshdmp_10.vcxproj", "{576EEEFD-E423-482B-879A-F0515D40B8E1}" +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CrashDumper", "..\plugins\CrashDumper\crshdmp.vcxproj", "{576EEEFD-E423-482B-879A-F0515D40B8E1}" EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OpenFolder", "..\plugins\OpenFolder\openFolder_10.vcxproj", "{8D233B9A-2744-4B62-94FC-7872FDDA4683}" EndProject diff --git a/bin10/mir_full_pro.sln b/bin10/mir_full_pro.sln index 0dce890c7a..c8b3a074ab 100644 --- a/bin10/mir_full_pro.sln +++ b/bin10/mir_full_pro.sln @@ -301,7 +301,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "SendSS", "..\plugins\SendSc EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DbEditorPP", "..\plugins\DbeditorPP\dbeditorpp_10.vcxproj", "{9C6040B8-1173-40FA-A3DB-DE044CCD8250}" EndProject -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CrashDumper", "..\plugins\CrashDumper\crshdmp_10.vcxproj", "{576EEEFD-E423-482B-879A-F0515D40B8E1}" +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CrashDumper", "..\plugins\CrashDumper\crshdmp.vcxproj", "{576EEEFD-E423-482B-879A-F0515D40B8E1}" EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OpenFolder", "..\plugins\OpenFolder\openFolder_10.vcxproj", "{8D233B9A-2744-4B62-94FC-7872FDDA4683}" EndProject diff --git a/bin12/mir_dev.sln b/bin12/mir_dev.sln index 729aff066e..a49c6426ca 100644 --- a/bin12/mir_dev.sln +++ b/bin12/mir_dev.sln @@ -267,7 +267,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "PasteIt", "..\plugins\Paste EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "SendSS", "..\plugins\SendScreenshotPlus\SendSS_12.vcxproj", "{CEAD8BCF-1F22-4E00-9F6D-E33405B00552}" EndProject -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CrashDumper", "..\plugins\CrashDumper\crshdmp_12.vcxproj", "{576EEEFD-E423-482B-879A-F0515D40B8E1}" +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CrashDumper", "..\plugins\CrashDumper\crshdmp.vcxproj", "{576EEEFD-E423-482B-879A-F0515D40B8E1}" EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DbEditorPP", "..\plugins\DbeditorPP\dbeditorpp_12.vcxproj", "{9C6040B8-1173-40FA-A3DB-DE044CCD8250}" EndProject diff --git a/bin12/mir_full.sln b/bin12/mir_full.sln index 1bf793e159..ff50b6329f 100644 --- a/bin12/mir_full.sln +++ b/bin12/mir_full.sln @@ -271,7 +271,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "SendSS", "..\plugins\SendSc EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DbEditorPP", "..\plugins\DbeditorPP\dbeditorpp_12.vcxproj", "{9C6040B8-1173-40FA-A3DB-DE044CCD8250}" EndProject -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CrashDumper", "..\plugins\CrashDumper\crshdmp_12.vcxproj", "{576EEEFD-E423-482B-879A-F0515D40B8E1}" +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CrashDumper", "..\plugins\CrashDumper\crshdmp.vcxproj", "{576EEEFD-E423-482B-879A-F0515D40B8E1}" EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OpenFolder", "..\plugins\OpenFolder\openFolder_12.vcxproj", "{8D233B9A-2744-4B62-94FC-7872FDDA4683}" EndProject diff --git a/plugins/CrashDumper/crshdmp.vcxproj b/plugins/CrashDumper/crshdmp.vcxproj new file mode 100644 index 0000000000..827a373e7c --- /dev/null +++ b/plugins/CrashDumper/crshdmp.vcxproj @@ -0,0 +1,33 @@ + + + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + + + CrashDumper + {576EEEFD-E423-482B-879A-F0515D40B8E1} + + + + + + + dbghelp.lib;version.lib;%(AdditionalDependencies) + + + \ No newline at end of file diff --git a/plugins/CrashDumper/crshdmp.vcxproj.filters b/plugins/CrashDumper/crshdmp.vcxproj.filters new file mode 100644 index 0000000000..de5ad9f66c --- /dev/null +++ b/plugins/CrashDumper/crshdmp.vcxproj.filters @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/plugins/CrashDumper/crshdmp_10.vcxproj b/plugins/CrashDumper/crshdmp_10.vcxproj deleted file mode 100644 index 191257d4aa..0000000000 --- a/plugins/CrashDumper/crshdmp_10.vcxproj +++ /dev/null @@ -1,229 +0,0 @@ - - - - - Debug - Win32 - - - Debug - x64 - - - Release - Win32 - - - Release - x64 - - - - CrashDumper - {576EEEFD-E423-482B-879A-F0515D40B8E1} - - - - DynamicLibrary - Unicode - - - DynamicLibrary - Unicode - true - - - DynamicLibrary - Unicode - - - DynamicLibrary - Unicode - true - - - - - - - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.311 - $(SolutionDir)$(Configuration)\Plugins\ - $(SolutionDir)$(Configuration)\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)64\Plugins\ - $(SolutionDir)$(Configuration)64\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)\Plugins\ - $(SolutionDir)$(Configuration)\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)64\Plugins\ - $(SolutionDir)$(Configuration)64\Obj\$(ProjectName)\ - true - - - - Full - Size - true - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - true - false - false - false - Fast - Level3 - OnlyExplicitInline - Use - utils.h - - - dbghelp.lib;version.lib;%(AdditionalDependencies) - true - Windows - true - true - true - $(IntDir)$(TargetName).lib - false - $(ProfileDir)..\..\bin10\lib - /PDBALTPATH:%_PDB% - - - ..\..\include\msapi - NDEBUG;%(PreprocessorDefinitions) - - - - - Full - Size - true - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - true - false - false - false - Fast - Level3 - OnlyExplicitInline - Use - utils.h - - - dbghelp.lib;version.lib;%(AdditionalDependencies) - true - Windows - true - true - true - $(IntDir)$(TargetName).lib - false - $(ProfileDir)..\..\bin10\lib - /PDBALTPATH:%_PDB% - - - ..\..\include\msapi - NDEBUG;%(PreprocessorDefinitions) - - - - - Disabled - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - _DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - true - EnableFastChecks - MultiThreadedDebugDLL - Fast - Level3 - EditAndContinue - false - Use - utils.h - - - dbghelp.lib;version.lib;%(AdditionalDependencies) - true - Windows - true - $(IntDir)$(TargetName).lib - false - $(ProfileDir)..\..\bin10\lib - - - ..\..\include\msapi - _DEBUG;%(PreprocessorDefinitions) - - - - - Disabled - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - _DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - true - EnableFastChecks - MultiThreadedDebugDLL - Fast - Level3 - false - Use - utils.h - - - dbghelp.lib;version.lib;%(AdditionalDependencies) - true - Windows - true - $(IntDir)$(TargetName).lib - false - $(ProfileDir)..\..\bin10\lib - - - ..\..\include\msapi - _DEBUG;%(PreprocessorDefinitions) - - - - - - - - - Create - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/plugins/CrashDumper/crshdmp_10.vcxproj.filters b/plugins/CrashDumper/crshdmp_10.vcxproj.filters deleted file mode 100644 index aa2111816c..0000000000 --- a/plugins/CrashDumper/crshdmp_10.vcxproj.filters +++ /dev/null @@ -1,82 +0,0 @@ - - - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - - - Resource Files - - - Resource Files - - - - - {1b9ea841-da4e-4a4f-b264-f1fb6e1f4d8f} - - - {6262c2f6-a26d-4484-97d2-a070eddff40e} - - - {62e505d1-3764-4225-b4dd-cf2341c4f783} - - - {4ac2fffa-c726-460d-a233-b057b4367069} - - - - - Resource Files\Icons - - - Resource Files\Icons - - - Resource Files\Icons - - - Resource Files\Icons - - - Resource Files\Icons - - - \ No newline at end of file diff --git a/plugins/CrashDumper/crshdmp_12.vcxproj b/plugins/CrashDumper/crshdmp_12.vcxproj deleted file mode 100644 index 25b860eef5..0000000000 --- a/plugins/CrashDumper/crshdmp_12.vcxproj +++ /dev/null @@ -1,232 +0,0 @@ - - - - - Debug - Win32 - - - Debug - x64 - - - Release - Win32 - - - Release - x64 - - - - CrashDumper - {576EEEFD-E423-482B-879A-F0515D40B8E1} - - - - DynamicLibrary - Unicode - v120_xp - - - DynamicLibrary - Unicode - true - v120_xp - - - DynamicLibrary - Unicode - v120_xp - - - DynamicLibrary - Unicode - true - v120_xp - - - - - - - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.311 - $(SolutionDir)$(Configuration)\Plugins\ - $(SolutionDir)$(Configuration)\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)64\Plugins\ - $(SolutionDir)$(Configuration)64\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)\Plugins\ - $(SolutionDir)$(Configuration)\Obj\$(ProjectName)\ - $(SolutionDir)$(Configuration)64\Plugins\ - $(SolutionDir)$(Configuration)64\Obj\$(ProjectName)\ - true - - - - Full - Size - true - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - true - false - false - false - Fast - Level4 - OnlyExplicitInline - Use - utils.h - - - dbghelp.lib;version.lib;%(AdditionalDependencies) - true - Windows - true - true - true - $(IntDir)$(TargetName).lib - false - $(ProfileDir)..\..\bin12\lib - - - ..\..\include\msapi - NDEBUG;%(PreprocessorDefinitions) - - - - - Full - Size - true - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - true - false - false - false - Fast - Level4 - OnlyExplicitInline - Use - utils.h - - - dbghelp.lib;version.lib;%(AdditionalDependencies) - true - Windows - true - true - true - $(IntDir)$(TargetName).lib - false - $(ProfileDir)..\..\bin12\lib - - - ..\..\include\msapi - NDEBUG;%(PreprocessorDefinitions) - - - - - Disabled - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - _DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - true - EnableFastChecks - MultiThreadedDebugDLL - Fast - Level4 - EditAndContinue - false - Use - utils.h - - - dbghelp.lib;version.lib;%(AdditionalDependencies) - true - Windows - true - $(IntDir)$(TargetName).lib - false - $(ProfileDir)..\..\bin12\lib - false - - - ..\..\include\msapi - _DEBUG;%(PreprocessorDefinitions) - - - - - Disabled - ..\..\include;..\ExternalAPI;%(AdditionalIncludeDirectories) - _DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) - true - EnableFastChecks - MultiThreadedDebugDLL - Fast - Level4 - false - Use - utils.h - - - dbghelp.lib;version.lib;%(AdditionalDependencies) - true - Windows - true - $(IntDir)$(TargetName).lib - false - $(ProfileDir)..\..\bin12\lib - - - ..\..\include\msapi - _DEBUG;%(PreprocessorDefinitions) - - - - - - - - - Create - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/plugins/CrashDumper/crshdmp_12.vcxproj.filters b/plugins/CrashDumper/crshdmp_12.vcxproj.filters deleted file mode 100644 index aa2111816c..0000000000 --- a/plugins/CrashDumper/crshdmp_12.vcxproj.filters +++ /dev/null @@ -1,82 +0,0 @@ - - - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - Source Files - - - - - Header Files - - - Header Files - - - Header Files - - - Header Files - - - - - Resource Files - - - Resource Files - - - - - {1b9ea841-da4e-4a4f-b264-f1fb6e1f4d8f} - - - {6262c2f6-a26d-4484-97d2-a070eddff40e} - - - {62e505d1-3764-4225-b4dd-cf2341c4f783} - - - {4ac2fffa-c726-460d-a233-b057b4367069} - - - - - Resource Files\Icons - - - Resource Files\Icons - - - Resource Files\Icons - - - Resource Files\Icons - - - Resource Files\Icons - - - \ No newline at end of file diff --git a/plugins/CrashDumper/src/crshdmp.cpp b/plugins/CrashDumper/src/crshdmp.cpp index 108d48910a..a20f5c82d0 100644 --- a/plugins/CrashDumper/src/crshdmp.cpp +++ b/plugins/CrashDumper/src/crshdmp.cpp @@ -16,7 +16,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . */ -#include "utils.h" +#include "stdafx.h" int hLangpack; diff --git a/plugins/CrashDumper/src/crshdmp_icons.cpp b/plugins/CrashDumper/src/crshdmp_icons.cpp index faf7298705..66e0f0e108 100644 --- a/plugins/CrashDumper/src/crshdmp_icons.cpp +++ b/plugins/CrashDumper/src/crshdmp_icons.cpp @@ -16,7 +16,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . */ -#include "utils.h" +#include "stdafx.h" static IconItem iconList[] = { diff --git a/plugins/CrashDumper/src/dumper.cpp b/plugins/CrashDumper/src/dumper.cpp index 99317570b1..9eea197517 100644 --- a/plugins/CrashDumper/src/dumper.cpp +++ b/plugins/CrashDumper/src/dumper.cpp @@ -16,7 +16,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . */ -#include "utils.h" +#include "stdafx.h" extern TCHAR* vertxt; extern TCHAR* profname; diff --git a/plugins/CrashDumper/src/exhndlr.cpp b/plugins/CrashDumper/src/exhndlr.cpp index e44f72c5ed..0253f5823a 100644 --- a/plugins/CrashDumper/src/exhndlr.cpp +++ b/plugins/CrashDumper/src/exhndlr.cpp @@ -1,4 +1,4 @@ -#include "utils.h" +#include "stdafx.h" #ifndef FACILITY_VISUALCPP #define FACILITY_VISUALCPP ((LONG)0x6d) diff --git a/plugins/CrashDumper/src/stdafx.cpp b/plugins/CrashDumper/src/stdafx.cpp deleted file mode 100644 index 6a4aa99c82..0000000000 --- a/plugins/CrashDumper/src/stdafx.cpp +++ /dev/null @@ -1,18 +0,0 @@ -/* -Copyright (C) 2012-15 Miranda NG project (http://miranda-ng.org) - -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 version 2 -of the License. - -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, see . -*/ - -#include "utils.h" \ No newline at end of file diff --git a/plugins/CrashDumper/src/stdafx.cxx b/plugins/CrashDumper/src/stdafx.cxx new file mode 100644 index 0000000000..6fb37564b7 --- /dev/null +++ b/plugins/CrashDumper/src/stdafx.cxx @@ -0,0 +1,18 @@ +/* +Copyright (C) 2012-15 Miranda NG project (http://miranda-ng.org) + +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 version 2 +of the License. + +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, see . +*/ + +#include "stdafx.h" \ No newline at end of file diff --git a/plugins/CrashDumper/src/stdafx.h b/plugins/CrashDumper/src/stdafx.h new file mode 100644 index 0000000000..ff77ceff81 --- /dev/null +++ b/plugins/CrashDumper/src/stdafx.h @@ -0,0 +1,150 @@ +/* +Miranda Crash Dumper Plugin +Copyright (C) 2008 - 2012 Boris Krasnovskiy All Rights Reserved + +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 version 2 +of the License. + +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, see . +*/ + +#include +#include + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "m_folders.h" +#include "m_toptoolbar.h" + +#include "sdkstuff.h" +#include "version.h" +#include "resource.h" + +#define crsi_u2a(dst, src) \ +{ \ + int cbLen = WideCharToMultiByte(CP_ACP, 0, src, -1, NULL, 0, NULL, NULL); \ + dst = (char*)alloca(cbLen+1); \ + WideCharToMultiByte(CP_ACP, 0, src, -1, dst, cbLen, NULL, NULL); \ +} + +#define crsi_a2u(dst, src, alloc) \ +{ \ + int cbLen = MultiByteToWideChar(CP_ACP, 0, src, -1, NULL, 0); \ + dst = (wchar_t*)alloc(sizeof(wchar_t) * (cbLen+1)); \ + MultiByteToWideChar(CP_ACP, 0, src, -1, dst, cbLen); \ +} + + + +#define crsi_t2a(d,s) crsi_u2a(d,s) +#define crsi_a2t(d,s) crsi_a2u(d,s,alloca) +#define crs_a2t(d,s) crsi_a2u(d,s,mir_alloc) + + + +#define MS_CRASHDUMPER_STORETOFILE "CrashDmp/StoreVerInfoToFile" +#define MS_CRASHDUMPER_STORETOCLIP "CrashDmp/StoreVerInfoToClip" +#define MS_CRASHDUMPER_GETINFO "CrashDmp/GetInfo" +#define MS_CRASHDUMPER_VIEWINFO "CrashDmp/ViewInfo" +#define MS_CRASHDUMPER_UPLOAD "CrashDmp/UploadInfo" +#define MS_CRASHDUMPER_URL "CrashDmp/StartUrl" +#define MS_CRASHDUMPER_URLTOCLIP "CrashDmp/CopyToClip" + +#define PluginName "Crash Dumper" + +#define VI_FLAG_FORMAT 1 +#define VI_FLAG_PRNVAR 2 +#define VI_FLAG_PRNDLL 4 +#define VI_FLAG_WEATHER 8 + +struct VerTrnsfr +{ + char* buf; + bool autot; +}; + +extern HMODULE hInst; +extern DWORD mirandaVersion; +extern LCID packlcid; +extern bool servicemode, clsdates, dtsubfldr, catchcrashes, needrestart; + +extern TCHAR CrashLogFolder[MAX_PATH]; +extern TCHAR VersionInfoFolder[MAX_PATH]; + +void WriteBBFile(CMString& buffer, bool hdr); +void WriteUtfFile(HANDLE hDumpFile, char* bufu); + +LONG WINAPI myfilter(PEXCEPTION_POINTERS exc_ptr); +LONG WINAPI myfilterv(PEXCEPTION_POINTERS exc_ptr); +DWORD MirandaThreadFilter(DWORD code, EXCEPTION_POINTERS* info); + +void GetOSDisplayString(CMString& buffer); +void GetInternetExplorerVersion(CMString& buffer); +void GetProcessorString(CMString& buffer); +void GetFreeMemoryString(CMString& buffer); +void GetFreeDiskString(LPCTSTR dirname, CMString& buffer); +void GetAdminString(CMString& buffer); +void GetLanguageString(CMString& buffer); +void GetLanguagePackString(CMString& buffer); +void GetWow64String(CMString& buffer); +void GetVersionInfo(HMODULE hLib, CMString& buffer); + +void GetISO8061Time(SYSTEMTIME* stLocal, LPTSTR lpszString, DWORD dwSize); + +void ReadableExceptionInfo(PEXCEPTION_RECORD excrec, CMString& buffer); + +void GetLastWriteTime(LPCTSTR fileName, LPTSTR lpszString, DWORD dwSize); +void GetLastWriteTime(FILETIME* ftime, LPTSTR lpszString, DWORD dwSize); +bool CreateDirectoryTree(LPTSTR szDir); +void StoreStringToClip(CMString& buffer); +void ShowMessage(int type, const TCHAR* format, ...); +bool IsPluginEnabled(TCHAR* filename); + +PLUGININFOEX* GetMirInfo(HMODULE hModule); +const PLUGININFOEX* GetPluginInfoEx(void); + +void CreateMiniDump(HANDLE hDumpFile, PEXCEPTION_POINTERS exc_ptr); +void CreateCrashReport(HANDLE hDumpFile, PEXCEPTION_POINTERS exc_ptr, const TCHAR* msg); +void PrintVersionInfo(CMString& buffer, unsigned flags = VI_FLAG_PRNVAR); +bool ProcessVIHash(bool store); + +void InitExceptionHandler(void); +void DestroyExceptionHandler(void); +void SetExceptionHandler(void); +void RemoveExceptionHandler(void); + +INT_PTR CALLBACK DlgProcOptions(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam); +INT_PTR CALLBACK DlgProcView(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam); +void DestroyAllWindows(void); + +void UploadInit(void); +void UploadClose(void); +void OpenAuthUrl(const char* url); +void __cdecl VersionInfoUploadThread(void* arg); + +void InitIcons(void); +HICON LoadIconEx(int iconId, bool big = false); +void ReleaseIconEx(int iconId); +HANDLE GetIconHandle(int iconId); diff --git a/plugins/CrashDumper/src/ui.cpp b/plugins/CrashDumper/src/ui.cpp index d5908043c3..7050771388 100644 --- a/plugins/CrashDumper/src/ui.cpp +++ b/plugins/CrashDumper/src/ui.cpp @@ -16,7 +16,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . */ -#include "utils.h" +#include "stdafx.h" HWND hViewWnd; extern HINSTANCE hInst; diff --git a/plugins/CrashDumper/src/upload.cpp b/plugins/CrashDumper/src/upload.cpp index f3a70a2cae..3422fee56a 100644 --- a/plugins/CrashDumper/src/upload.cpp +++ b/plugins/CrashDumper/src/upload.cpp @@ -16,7 +16,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . */ -#include "utils.h" +#include "stdafx.h" HANDLE hNetlibUser; diff --git a/plugins/CrashDumper/src/utils.cpp b/plugins/CrashDumper/src/utils.cpp index a592a9f9bc..164e63dfd0 100644 --- a/plugins/CrashDumper/src/utils.cpp +++ b/plugins/CrashDumper/src/utils.cpp @@ -16,7 +16,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . */ -#include "utils.h" +#include "stdafx.h" static HINSTANCE hKernel = GetModuleHandleA("kernel32.dll"); diff --git a/plugins/CrashDumper/src/utils.h b/plugins/CrashDumper/src/utils.h deleted file mode 100644 index 70d49006de..0000000000 --- a/plugins/CrashDumper/src/utils.h +++ /dev/null @@ -1,152 +0,0 @@ -/* -Miranda Crash Dumper Plugin -Copyright (C) 2008 - 2012 Boris Krasnovskiy All Rights Reserved - -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 version 2 -of the License. - -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, see . -*/ - -#define _CRT_SECURE_NO_WARNINGS - -#include -#include - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include "m_folders.h" -#include "m_toptoolbar.h" - -#include "sdkstuff.h" -#include "version.h" -#include "resource.h" - -#define crsi_u2a(dst, src) \ -{ \ - int cbLen = WideCharToMultiByte(CP_ACP, 0, src, -1, NULL, 0, NULL, NULL); \ - dst = (char*)alloca(cbLen+1); \ - WideCharToMultiByte(CP_ACP, 0, src, -1, dst, cbLen, NULL, NULL); \ -} - -#define crsi_a2u(dst, src, alloc) \ -{ \ - int cbLen = MultiByteToWideChar(CP_ACP, 0, src, -1, NULL, 0); \ - dst = (wchar_t*)alloc(sizeof(wchar_t) * (cbLen+1)); \ - MultiByteToWideChar(CP_ACP, 0, src, -1, dst, cbLen); \ -} - - - -#define crsi_t2a(d,s) crsi_u2a(d,s) -#define crsi_a2t(d,s) crsi_a2u(d,s,alloca) -#define crs_a2t(d,s) crsi_a2u(d,s,mir_alloc) - - - -#define MS_CRASHDUMPER_STORETOFILE "CrashDmp/StoreVerInfoToFile" -#define MS_CRASHDUMPER_STORETOCLIP "CrashDmp/StoreVerInfoToClip" -#define MS_CRASHDUMPER_GETINFO "CrashDmp/GetInfo" -#define MS_CRASHDUMPER_VIEWINFO "CrashDmp/ViewInfo" -#define MS_CRASHDUMPER_UPLOAD "CrashDmp/UploadInfo" -#define MS_CRASHDUMPER_URL "CrashDmp/StartUrl" -#define MS_CRASHDUMPER_URLTOCLIP "CrashDmp/CopyToClip" - -#define PluginName "Crash Dumper" - -#define VI_FLAG_FORMAT 1 -#define VI_FLAG_PRNVAR 2 -#define VI_FLAG_PRNDLL 4 -#define VI_FLAG_WEATHER 8 - -struct VerTrnsfr -{ - char* buf; - bool autot; -}; - -extern HMODULE hInst; -extern DWORD mirandaVersion; -extern LCID packlcid; -extern bool servicemode, clsdates, dtsubfldr, catchcrashes, needrestart; - -extern TCHAR CrashLogFolder[MAX_PATH]; -extern TCHAR VersionInfoFolder[MAX_PATH]; - -void WriteBBFile(CMString& buffer, bool hdr); -void WriteUtfFile(HANDLE hDumpFile, char* bufu); - -LONG WINAPI myfilter(PEXCEPTION_POINTERS exc_ptr); -LONG WINAPI myfilterv(PEXCEPTION_POINTERS exc_ptr); -DWORD MirandaThreadFilter(DWORD code, EXCEPTION_POINTERS* info); - -void GetOSDisplayString(CMString& buffer); -void GetInternetExplorerVersion(CMString& buffer); -void GetProcessorString(CMString& buffer); -void GetFreeMemoryString(CMString& buffer); -void GetFreeDiskString(LPCTSTR dirname, CMString& buffer); -void GetAdminString(CMString& buffer); -void GetLanguageString(CMString& buffer); -void GetLanguagePackString(CMString& buffer); -void GetWow64String(CMString& buffer); -void GetVersionInfo(HMODULE hLib, CMString& buffer); - -void GetISO8061Time(SYSTEMTIME* stLocal, LPTSTR lpszString, DWORD dwSize); - -void ReadableExceptionInfo(PEXCEPTION_RECORD excrec, CMString& buffer); - -void GetLastWriteTime(LPCTSTR fileName, LPTSTR lpszString, DWORD dwSize); -void GetLastWriteTime(FILETIME* ftime, LPTSTR lpszString, DWORD dwSize); -bool CreateDirectoryTree(LPTSTR szDir); -void StoreStringToClip(CMString& buffer); -void ShowMessage(int type, const TCHAR* format, ...); -bool IsPluginEnabled(TCHAR* filename); - -PLUGININFOEX* GetMirInfo(HMODULE hModule); -const PLUGININFOEX* GetPluginInfoEx(void); - -void CreateMiniDump(HANDLE hDumpFile, PEXCEPTION_POINTERS exc_ptr); -void CreateCrashReport(HANDLE hDumpFile, PEXCEPTION_POINTERS exc_ptr, const TCHAR* msg); -void PrintVersionInfo(CMString& buffer, unsigned flags = VI_FLAG_PRNVAR); -bool ProcessVIHash(bool store); - -void InitExceptionHandler(void); -void DestroyExceptionHandler(void); -void SetExceptionHandler(void); -void RemoveExceptionHandler(void); - -INT_PTR CALLBACK DlgProcOptions(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam); -INT_PTR CALLBACK DlgProcView(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam); -void DestroyAllWindows(void); - -void UploadInit(void); -void UploadClose(void); -void OpenAuthUrl(const char* url); -void __cdecl VersionInfoUploadThread(void* arg); - -void InitIcons(void); -HICON LoadIconEx(int iconId, bool big = false); -void ReleaseIconEx(int iconId); -HANDLE GetIconHandle(int iconId); -- cgit v1.2.3