Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/kornelski/7z.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIgor Pavlov <ipavlov@users.sourceforge.net>2007-04-17 04:00:00 +0400
committerKornel LesiƄski <kornel@geekhood.net>2016-05-28 02:15:50 +0300
commita145bfc7cf17f7bbcfae8f0064333c8ea75b455c (patch)
tree4ea458c9f35956fe080562989a702ea8c9af4b90 /CPP/7zip/Archive/Chm
parentd9666cf046a8453b33b3e2fbf4d82295a9f87df3 (diff)
4.45 beta
Diffstat (limited to 'CPP/7zip/Archive/Chm')
-rwxr-xr-xCPP/7zip/Archive/Chm/Chm.dsp337
-rwxr-xr-xCPP/7zip/Archive/Chm/Chm.dsw29
-rwxr-xr-xCPP/7zip/Archive/Chm/ChmRegister.cpp13
-rwxr-xr-xCPP/7zip/Archive/Chm/DllExports.cpp77
-rwxr-xr-xCPP/7zip/Archive/Chm/makefile68
-rwxr-xr-xCPP/7zip/Archive/Chm/resource.rc3
6 files changed, 13 insertions, 514 deletions
diff --git a/CPP/7zip/Archive/Chm/Chm.dsp b/CPP/7zip/Archive/Chm/Chm.dsp
deleted file mode 100755
index 7e0b7c66..00000000
--- a/CPP/7zip/Archive/Chm/Chm.dsp
+++ /dev/null
@@ -1,337 +0,0 @@
-# Microsoft Developer Studio Project File - Name="Chm" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=Chm - Win32 Debug
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "Chm.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "Chm.mak" CFG="Chm - Win32 Debug"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "Chm - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "Chm - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "Chm - Win32 Release"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release"
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CHM_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /Gz /MD /W3 /GX /O1 /I "../../../" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CHM_EXPORTS" /Yu"StdAfx.h" /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x419 /d "NDEBUG"
-# ADD RSC /l 0x419 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"C:\Program Files\7-Zip\Formats\chm.dll" /opt:NOWIN98
-# SUBTRACT LINK32 /pdb:none
-
-!ELSEIF "$(CFG)" == "Chm - Win32 Debug"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug"
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CHM_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "../../../" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CHM_EXPORTS" /Yu"StdAfx.h" /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x419 /d "_DEBUG"
-# ADD RSC /l 0x419 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"C:\Program Files\7-Zip\Formats\chm.dll" /pdbtype:sept
-
-!ENDIF
-
-# Begin Target
-
-# Name "Chm - Win32 Release"
-# Name "Chm - Win32 Debug"
-# Begin Group "Spec"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=..\Archive.def
-# End Source File
-# Begin Source File
-
-SOURCE=.\DllExports.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\resource.rc
-# End Source File
-# Begin Source File
-
-SOURCE=.\StdAfx.cpp
-# ADD CPP /Yc"StdAfx.h"
-# End Source File
-# Begin Source File
-
-SOURCE=.\StdAfx.h
-# End Source File
-# End Group
-# Begin Group "Engine"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=.\ChmHandler.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\ChmHandler.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\ChmHeader.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\ChmHeader.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\ChmIn.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\ChmIn.h
-# End Source File
-# End Group
-# Begin Group "7zip Common"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=..\..\Common\InBuffer.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Common\InBuffer.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Common\LimitedStreams.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Common\LimitedStreams.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Common\OutBuffer.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Common\OutBuffer.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Common\ProgressUtils.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Common\ProgressUtils.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Common\StreamUtils.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Common\StreamUtils.h
-# End Source File
-# End Group
-# Begin Group "Common"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=..\..\..\Common\Alloc.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\..\Common\Alloc.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\..\Common\Buffer.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\..\Common\IntToString.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\..\Common\IntToString.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\..\Common\String.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\..\Common\String.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\..\Common\StringConvert.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\..\Common\StringConvert.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\..\Common\UTFConvert.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\..\Common\UTFConvert.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\..\Common\Vector.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\..\Common\Vector.h
-# End Source File
-# End Group
-# Begin Group "Windows"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=..\..\..\Windows\PropVariant.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\..\Windows\PropVariant.h
-# End Source File
-# End Group
-# Begin Group "Archive Common"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=..\Common\ItemNameUtils.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\Common\ItemNameUtils.h
-# End Source File
-# End Group
-# Begin Group "Compress"
-
-# PROP Default_Filter ""
-# Begin Group "LZ"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=..\..\Compress\LZ\LZOutWindow.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Compress\LZ\LZOutWindow.h
-# End Source File
-# End Group
-# Begin Group "Lzx"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=..\..\Compress\Lzx\Lzx.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Compress\Lzx\Lzx86Converter.cpp
-
-!IF "$(CFG)" == "Chm - Win32 Release"
-
-# ADD CPP /O2
-# SUBTRACT CPP /YX /Yc /Yu
-
-!ELSEIF "$(CFG)" == "Chm - Win32 Debug"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Compress\Lzx\Lzx86Converter.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Compress\Lzx\LzxDecoder.cpp
-
-!IF "$(CFG)" == "Chm - Win32 Release"
-
-# ADD CPP /O2
-# SUBTRACT CPP /YX /Yc /Yu
-
-!ELSEIF "$(CFG)" == "Chm - Win32 Debug"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Compress\Lzx\LzxDecoder.h
-# End Source File
-# End Group
-# Begin Source File
-
-SOURCE=..\..\Compress\Copy\CopyCoder.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\Compress\Copy\CopyCoder.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/CPP/7zip/Archive/Chm/Chm.dsw b/CPP/7zip/Archive/Chm/Chm.dsw
deleted file mode 100755
index 58cb09b2..00000000
--- a/CPP/7zip/Archive/Chm/Chm.dsw
+++ /dev/null
@@ -1,29 +0,0 @@
-Microsoft Developer Studio Workspace File, Format Version 6.00
-# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
-
-###############################################################################
-
-Project: "Chm"=.\Chm.dsp - Package Owner=<4>
-
-Package=<5>
-{{{
-}}}
-
-Package=<4>
-{{{
-}}}
-
-###############################################################################
-
-Global:
-
-Package=<5>
-{{{
-}}}
-
-Package=<3>
-{{{
-}}}
-
-###############################################################################
-
diff --git a/CPP/7zip/Archive/Chm/ChmRegister.cpp b/CPP/7zip/Archive/Chm/ChmRegister.cpp
new file mode 100755
index 00000000..abebe6c6
--- /dev/null
+++ b/CPP/7zip/Archive/Chm/ChmRegister.cpp
@@ -0,0 +1,13 @@
+// ChmRegister.cpp
+
+#include "StdAfx.h"
+
+#include "../../Common/RegisterArc.h"
+
+#include "ChmHandler.h"
+static IInArchive *CreateArc() { return new NArchive::NChm::CHandler; }
+
+static CArcInfo g_ArcInfo =
+ { L"Chm", L"chm chi chq chw hxs hxi hxr hxq hxw lit", 0, 0xE9, { 'I', 'T', 'S', 'F' }, 4, false, CreateArc, 0 };
+
+REGISTER_ARC(Chm)
diff --git a/CPP/7zip/Archive/Chm/DllExports.cpp b/CPP/7zip/Archive/Chm/DllExports.cpp
deleted file mode 100755
index ad822094..00000000
--- a/CPP/7zip/Archive/Chm/DllExports.cpp
+++ /dev/null
@@ -1,77 +0,0 @@
-// DLLExports.cpp
-
-#include "StdAfx.h"
-
-#include "Common/MyInitGuid.h"
-#include "Common/ComTry.h"
-#include "Windows/PropVariant.h"
-#include "ChmHandler.h"
-#include "../../ICoder.h"
-
-// {23170F69-40C1-278A-1000-000110E90000}
-DEFINE_GUID(CLSID_CChmHandler,
- 0x23170F69, 0x40C1, 0x278A, 0x10, 0x00, 0x00, 0x01, 0x10, 0xE9, 0x00, 0x00);
-
-extern "C"
-BOOL WINAPI DllMain(HINSTANCE /* hInstance */, DWORD /* dwReason */, LPVOID /*lpReserved*/)
-{
- return TRUE;
-}
-
-STDAPI CreateObject(
- const GUID *classID,
- const GUID *interfaceID,
- void **outObject)
-{
- COM_TRY_BEGIN
- *outObject = 0;
- if (*classID != CLSID_CChmHandler)
- return CLASS_E_CLASSNOTAVAILABLE;
- if (*interfaceID != IID_IInArchive)
- return E_NOINTERFACE;
- CMyComPtr<IInArchive> inArchive = (IInArchive *)new NArchive::NChm::CHandler;
- *outObject = inArchive.Detach();
- COM_TRY_END
- return S_OK;
-}
-
-STDAPI GetHandlerProperty(PROPID propID, PROPVARIANT *value)
-{
- NWindows::NCOM::CPropVariant propVariant;
- switch(propID)
- {
- case NArchive::kName:
- propVariant = L"Chm";
- break;
- case NArchive::kClassID:
- {
- if ((value->bstrVal = ::SysAllocStringByteLen(
- (const char *)&CLSID_CChmHandler, sizeof(GUID))) != 0)
- value->vt = VT_BSTR;
- return S_OK;
- }
- case NArchive::kExtension:
- propVariant = L"chm chi chq chw hxs hxi hxr hxq hxw lit";
- break;
- case NArchive::kUpdate:
- propVariant = false;
- break;
- case NArchive::kKeepName:
- propVariant = false;
- break;
- case NArchive::kStartSignature:
- {
- const char sig[] = { 'I', 'T', 'S', 'F' };
- if ((value->bstrVal = ::SysAllocStringByteLen(sig, 4)) != 0)
- value->vt = VT_BSTR;
- return S_OK;
- }
- case NArchive::kAssociate:
- {
- propVariant = false;
- break;
- }
- }
- propVariant.Detach(value);
- return S_OK;
-}
diff --git a/CPP/7zip/Archive/Chm/makefile b/CPP/7zip/Archive/Chm/makefile
deleted file mode 100755
index 4adce2f5..00000000
--- a/CPP/7zip/Archive/Chm/makefile
+++ /dev/null
@@ -1,68 +0,0 @@
-PROG = chm.dll
-DEF_FILE = ../Archive.def
-CFLAGS = $(CFLAGS) -I ../../../
-LIBS = $(LIBS) oleaut32.lib user32.lib
-
-CHM_OBJS = \
- $O\DllExports.obj \
- $O\ChmHandler.obj \
- $O\ChmHeader.obj \
- $O\ChmIn.obj \
-
-COMMON_OBJS = \
- $O\Alloc.obj \
- $O\IntToString.obj \
- $O\NewHandler.obj \
- $O\String.obj \
- $O\StringConvert.obj \
- $O\UTFConvert.obj \
- $O\Vector.obj \
-
-WIN_OBJS = \
- $O\PropVariant.obj \
-
-7ZIP_COMMON_OBJS = \
- $O\InBuffer.obj \
- $O\LimitedStreams.obj \
- $O\OutBuffer.obj \
- $O\ProgressUtils.obj \
- $O\StreamUtils.obj \
-
-AR_COMMON_OBJS = \
- $O\ItemNameUtils.obj \
-
-COMPRESS_LZX_OBJS = \
- $O\LzxDecoder.obj \
- $O\Lzx86Converter.obj \
-
-OBJS = \
- $O\StdAfx.obj \
- $(CHM_OBJS) \
- $(COMMON_OBJS) \
- $(WIN_OBJS) \
- $(7ZIP_COMMON_OBJS) \
- $(AR_COMMON_OBJS) \
- $(COMPRESS_LZX_OBJS) \
- $O\LZOutWindow.obj \
- $O\CopyCoder.obj \
- $O\resource.res
-
-!include "../../../Build.mak"
-
-$(CHM_OBJS): $(*B).cpp
- $(COMPL)
-$(COMMON_OBJS): ../../../Common/$(*B).cpp
- $(COMPL)
-$(WIN_OBJS): ../../../Windows/$(*B).cpp
- $(COMPL)
-$(7ZIP_COMMON_OBJS): ../../Common/$(*B).cpp
- $(COMPL)
-$(AR_COMMON_OBJS): ../Common/$(*B).cpp
- $(COMPL)
-$(COMPRESS_LZX_OBJS): ../../Compress/Lzx/$(*B).cpp
- $(COMPL_O2)
-$O\LZOutWindow.obj: ../../Compress/LZ/$(*B).cpp
- $(COMPL)
-$O\CopyCoder.obj: ../../Compress/Copy/$(*B).cpp
- $(COMPL)
-
diff --git a/CPP/7zip/Archive/Chm/resource.rc b/CPP/7zip/Archive/Chm/resource.rc
deleted file mode 100755
index fc93ae4f..00000000
--- a/CPP/7zip/Archive/Chm/resource.rc
+++ /dev/null
@@ -1,3 +0,0 @@
-#include "../../MyVersionInfo.rc"
-
-MY_VERSION_INFO_DLL("Chm Plugin", "chm")