diff options
-rw-r--r-- | nohtml/common.h | 2 | ||||
-rw-r--r-- | nohtml/filter.cpp | 10 | ||||
-rw-r--r-- | nohtml/nohtml_9.sln | 12 | ||||
-rw-r--r-- | nohtml/nohtml_9.vcproj | 223 | ||||
-rw-r--r-- | nohtml/options.cpp | 7 |
5 files changed, 235 insertions, 19 deletions
diff --git a/nohtml/common.h b/nohtml/common.h index 51486f9..a585065 100644 --- a/nohtml/common.h +++ b/nohtml/common.h @@ -45,7 +45,7 @@ #include <stdio.h>
#include <m_utils.h>
#include <m_updater.h>
-#include <m_yapp.h>
+#include <m_popup.h>
#define MODULE "nohtml"
diff --git a/nohtml/filter.cpp b/nohtml/filter.cpp index b29781d..b66c457 100644 --- a/nohtml/filter.cpp +++ b/nohtml/filter.cpp @@ -21,7 +21,7 @@ bool ContactIsOTREncrypted(HANDLE hContact) { return (DBGetContactSettingByte(hContact, "OTR", "Encrypted", 0) != 0);
}
-int FilterSendMessage(WPARAM wParam, LPARAM lParam) {
+INT_PTR FilterSendMessage(WPARAM wParam, LPARAM lParam) {
CCSDATA *ccs = (CCSDATA *) lParam;
char *old_message = (char *)ccs->lParam;
char *buf = 0;
@@ -77,13 +77,13 @@ int FilterSendMessage(WPARAM wParam, LPARAM lParam) { }
}
- int ret = CallService(MS_PROTO_CHAINSEND, wParam, lParam);
+ INT_PTR ret = CallService(MS_PROTO_CHAINSEND, wParam, lParam);
ccs->lParam = (LPARAM)old_message;
if(buf) free(buf);
return ret;
}
-int FilterSendMessageW(WPARAM wParam, LPARAM lParam) {
+INT_PTR FilterSendMessageW(WPARAM wParam, LPARAM lParam) {
CCSDATA *ccs = (CCSDATA *) lParam;
if(!(ccs->wParam & PREF_UTF))
ccs->wParam |= PREF_UNICODE;
@@ -91,7 +91,7 @@ int FilterSendMessageW(WPARAM wParam, LPARAM lParam) { return FilterSendMessage(wParam, lParam);
}
-int FilterRecvMessage(WPARAM wParam, LPARAM lParam) {
+INT_PTR FilterRecvMessage(WPARAM wParam, LPARAM lParam) {
CCSDATA *ccs = (CCSDATA *) lParam;
PROTORECVEVENT *pre = (PROTORECVEVENT *) ccs->lParam;
char *old_message = pre->szMessage;
@@ -172,7 +172,7 @@ int FilterRecvMessage(WPARAM wParam, LPARAM lParam) { }
}
- int ret = CallService(MS_PROTO_CHAINRECV, wParam, lParam);
+ INT_PTR ret = CallService(MS_PROTO_CHAINRECV, wParam, lParam);
pre->szMessage = old_message;
if(buf) free(buf);
return ret;
diff --git a/nohtml/nohtml_9.sln b/nohtml/nohtml_9.sln index 73bb545..885ea2d 100644 --- a/nohtml/nohtml_9.sln +++ b/nohtml/nohtml_9.sln @@ -5,20 +5,20 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "nohtml", "nohtml_9.vcproj", EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
- Debug (Unicode)|Win32 = Debug (Unicode)|Win32
Debug|Win32 = Debug|Win32
- Release (Unicode)|Win32 = Release (Unicode)|Win32
+ Debug|x64 = Debug|x64
Release|Win32 = Release|Win32
+ Release|x64 = Release|x64
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {35961A10-6297-47AA-A6D9-1713389AC5F9}.Debug (Unicode)|Win32.ActiveCfg = Release|Win32
- {35961A10-6297-47AA-A6D9-1713389AC5F9}.Debug (Unicode)|Win32.Build.0 = Release|Win32
{35961A10-6297-47AA-A6D9-1713389AC5F9}.Debug|Win32.ActiveCfg = Debug|Win32
{35961A10-6297-47AA-A6D9-1713389AC5F9}.Debug|Win32.Build.0 = Debug|Win32
- {35961A10-6297-47AA-A6D9-1713389AC5F9}.Release (Unicode)|Win32.ActiveCfg = Release|Win32
- {35961A10-6297-47AA-A6D9-1713389AC5F9}.Release (Unicode)|Win32.Build.0 = Release|Win32
+ {35961A10-6297-47AA-A6D9-1713389AC5F9}.Debug|x64.ActiveCfg = Debug|x64
+ {35961A10-6297-47AA-A6D9-1713389AC5F9}.Debug|x64.Build.0 = Debug|x64
{35961A10-6297-47AA-A6D9-1713389AC5F9}.Release|Win32.ActiveCfg = Release|Win32
{35961A10-6297-47AA-A6D9-1713389AC5F9}.Release|Win32.Build.0 = Release|Win32
+ {35961A10-6297-47AA-A6D9-1713389AC5F9}.Release|x64.ActiveCfg = Release|x64
+ {35961A10-6297-47AA-A6D9-1713389AC5F9}.Release|x64.Build.0 = Release|x64
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
diff --git a/nohtml/nohtml_9.vcproj b/nohtml/nohtml_9.vcproj index 60d0629..c8208ef 100644 --- a/nohtml/nohtml_9.vcproj +++ b/nohtml/nohtml_9.vcproj @@ -11,6 +11,9 @@ <Platform
Name="Win32"
/>
+ <Platform
+ Name="x64"
+ />
</Platforms>
<ToolFiles>
</ToolFiles>
@@ -39,7 +42,78 @@ <Tool
Name="VCCLCompilerTool"
Optimization="0"
- AdditionalIncludeDirectories="../../include"
+ AdditionalIncludeDirectories="../../include;../../../include"
+ PreprocessorDefinitions="_DEBUG;_WINDOWS;_USERDLL"
+ RuntimeLibrary="1"
+ UsePrecompiledHeader="2"
+ PrecompiledHeaderThrough="common.h"
+ DebugInformationFormat="3"
+ DisableSpecificWarnings="4996"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ GenerateDebugInformation="true"
+ SubSystem="2"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Debug|x64"
+ OutputDirectory="$(ConfigurationName)64"
+ IntermediateDirectory="$(ConfigurationName)64"
+ ConfigurationType="2"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ TargetEnvironment="3"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ AdditionalIncludeDirectories="../../include;../../../include"
PreprocessorDefinitions="_DEBUG;_WINDOWS;_USERDLL"
RuntimeLibrary="1"
UsePrecompiledHeader="2"
@@ -62,6 +136,7 @@ SubSystem="2"
RandomizedBaseAddress="1"
DataExecutionPrevention="0"
+ TargetMachine="17"
/>
<Tool
Name="VCALinkTool"
@@ -108,9 +183,100 @@ />
<Tool
Name="VCCLCompilerTool"
- AdditionalIncludeDirectories="../../include"
+ Optimization="3"
+ InlineFunctionExpansion="2"
+ EnableIntrinsicFunctions="true"
+ FavorSizeOrSpeed="2"
+ WholeProgramOptimization="true"
+ AdditionalIncludeDirectories="../../include;../../../include"
+ PreprocessorDefinitions="NDEBUG;_WINDOWS;_USERDLL"
+ StringPooling="true"
+ ExceptionHandling="0"
+ RuntimeLibrary="2"
+ BufferSecurityCheck="false"
+ FloatingPointModel="2"
+ RuntimeTypeInfo="false"
+ UsePrecompiledHeader="2"
+ PrecompiledHeaderThrough="common.h"
+ DisableSpecificWarnings="4996"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLinkerTool"
+ GenerateManifest="false"
+ SubSystem="2"
+ EnableCOMDATFolding="2"
+ RandomizedBaseAddress="1"
+ DataExecutionPrevention="0"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCManifestTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCAppVerifierTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release|x64"
+ OutputDirectory="$(ConfigurationName)64"
+ IntermediateDirectory="$(ConfigurationName)64"
+ ConfigurationType="2"
+ WholeProgramOptimization="1"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ TargetEnvironment="3"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="3"
+ InlineFunctionExpansion="2"
+ EnableIntrinsicFunctions="true"
+ FavorSizeOrSpeed="2"
+ WholeProgramOptimization="true"
+ AdditionalIncludeDirectories="../../include;../../../include"
PreprocessorDefinitions="NDEBUG;_WINDOWS;_USERDLL"
- RuntimeLibrary="0"
+ StringPooling="true"
+ ExceptionHandling="0"
+ RuntimeLibrary="2"
+ BufferSecurityCheck="false"
+ FloatingPointModel="2"
+ RuntimeTypeInfo="false"
UsePrecompiledHeader="2"
PrecompiledHeaderThrough="common.h"
DisableSpecificWarnings="4996"
@@ -126,9 +292,12 @@ />
<Tool
Name="VCLinkerTool"
+ GenerateManifest="false"
SubSystem="2"
+ EnableCOMDATFolding="2"
RandomizedBaseAddress="1"
DataExecutionPrevention="0"
+ TargetMachine="17"
/>
<Tool
Name="VCALinkTool"
@@ -173,6 +342,14 @@ />
</FileConfiguration>
<FileConfiguration
+ Name="Debug|x64"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ UsePrecompiledHeader="1"
+ />
+ </FileConfiguration>
+ <FileConfiguration
Name="Release|Win32"
>
<Tool
@@ -180,6 +357,14 @@ UsePrecompiledHeader="1"
/>
</FileConfiguration>
+ <FileConfiguration
+ Name="Release|x64"
+ >
+ <Tool
+ Name="VCCLCompilerTool"
+ UsePrecompiledHeader="1"
+ />
+ </FileConfiguration>
</File>
<File
RelativePath=".\conv.cpp"
@@ -253,6 +438,14 @@ />
</FileConfiguration>
<FileConfiguration
+ Name="Debug|x64"
+ ExcludedFromBuild="true"
+ >
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ </FileConfiguration>
+ <FileConfiguration
Name="Release|Win32"
ExcludedFromBuild="true"
>
@@ -260,6 +453,14 @@ Name="VCResourceCompilerTool"
/>
</FileConfiguration>
+ <FileConfiguration
+ Name="Release|x64"
+ ExcludedFromBuild="true"
+ >
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ </FileConfiguration>
</File>
<File
RelativePath=".\resource.rc"
@@ -277,6 +478,14 @@ />
</FileConfiguration>
<FileConfiguration
+ Name="Debug|x64"
+ ExcludedFromBuild="true"
+ >
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ </FileConfiguration>
+ <FileConfiguration
Name="Release|Win32"
ExcludedFromBuild="true"
>
@@ -284,6 +493,14 @@ Name="VCResourceCompilerTool"
/>
</FileConfiguration>
+ <FileConfiguration
+ Name="Release|x64"
+ ExcludedFromBuild="true"
+ >
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ </FileConfiguration>
</File>
</Filter>
<File
diff --git a/nohtml/options.cpp b/nohtml/options.cpp index bda3de4..194850a 100644 --- a/nohtml/options.cpp +++ b/nohtml/options.cpp @@ -22,7 +22,7 @@ void SaveOptions() { DBWriteContactSettingDword(0, MODULE, "ApplyTo", options.apply_to);
}
-BOOL CALLBACK DlgProcOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam) {
+INT_PTR CALLBACK DlgProcOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam) {
static HANDLE hItemAll;
switch ( msg ) {
@@ -85,13 +85,12 @@ int OptInit(WPARAM wParam, LPARAM lParam) { OPTIONSDIALOGPAGE odp = { 0 };
odp.cbSize = sizeof(odp);
odp.flags = ODPF_BOLDGROUPS;
- odp.flags |= ODPF_TCHAR;
odp.position = -790000000;
odp.hInstance = hInst;
odp.pszTemplate = MAKEINTRESOURCEA(IDD_OPT1);
- odp.ptszTitle = TranslateT(MODULE);
- odp.ptszGroup = TranslateT("Plugins");
+ odp.pszTitle = MODULE;
+ odp.pszGroup = "Plugins";
odp.nIDBottomSimpleControl = 0;
odp.pfnDlgProc = DlgProcOpts;
CallService( MS_OPT_ADDPAGE, wParam,( LPARAM )&odp );
|