Commit 821e0a4b authored by Elen.Subbotina's avatar Elen.Subbotina Committed by Alexander Trofimov

.....

git-svn-id: svn://fileserver/activex/AVS/Sources/TeamlabOffice/trunk/ServerComponents@58897 954022d7-b5bf-4e40-9824-e11837661b57
parent f7c65a4a
This diff is collapsed.
......@@ -156,7 +156,7 @@
Name="VCCLCompilerTool"
InlineFunctionExpansion="1"
AdditionalIncludeDirectories="..\Common;..\..\..\..\Addons\ZLib"
PreprocessorDefinitions="WIN32;_WINDOWS;NDEBUG;_USRDLL;_ATL_ATTRIBUTES;_USE_MATH_DEFINES"
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;_ATL_ATTRIBUTES;NODOCX;PPTX_DEF;PPT_DEF;ENABLE_PPT_TO_PPTX_CONVERT;_AVS_PPT_SHAPE_INCLUDE_;LIBXML_READER_ENABLED;_USE_XMLLITE_READER_;USE_XMLLITE_READER;AVS_USE_CONVERT_PPTX_TOCUSTOM_VML"
StringPooling="true"
RuntimeLibrary="2"
EnableFunctionLevelLinking="true"
......@@ -432,14 +432,6 @@
Name="Source Files"
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm"
>
<File
RelativePath=".\ASCOfficePPTXFile.cpp"
>
</File>
<File
RelativePath=".\ASCOfficePPTXFileRealization.cpp"
>
</File>
<File
RelativePath="stdafx.cpp"
>
......@@ -497,10 +489,6 @@
RelativePath=".\ASCOfficePPTXFileComInterface.h"
>
</File>
<File
RelativePath="..\Common\DocxFormat\Source\XML\libxml2\libxml2.h"
>
</File>
<File
RelativePath="Resource.h"
>
......@@ -509,10 +497,6 @@
RelativePath="stdafx.h"
>
</File>
<File
RelativePath="..\Common\DocxFormat\Source\XML\stringcommon.h"
>
</File>
</Filter>
<Filter
Name="Resource Files"
......@@ -527,30 +511,6 @@
>
</File>
</Filter>
<Filter
Name="Editor"
>
<File
RelativePath=".\Editor\BinaryFileReaderWriter.h"
>
</File>
<File
RelativePath=".\Editor\BinReaderWriterDefines.h"
>
</File>
<File
RelativePath=".\Editor\BinWriters.h"
>
</File>
<File
RelativePath=".\Editor\Converter.h"
>
</File>
<File
RelativePath=".\Editor\PPTXWriter.h"
>
</File>
</Filter>
</Files>
<Globals>
</Globals>
......
#include "stdafx.h"
#include "ASCOfficePPTXFile.h"
#include "PPTXFormat/PPTXEvent.h"
......
......@@ -42,7 +42,7 @@
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="..\..\Common\ASCDocxFormat\Source\Utility;..\..\Common\ASCDocxFormat\Source\XML;..\..\Common\ASCDocxFormat\Source\;.\;..\..\Common\DocxFormat\Source\XML\libxml2\XML\include;&quot;../../DesktopEditor/freetype-2.5.2/include&quot;"
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;_ATL_ATTRIBUTES;_USE_MATH_DEFINES;NODOCX;PPTX_DEF;PPT_DEF;ENABLE_PPT_TO_PPTX_CONVERT;_AVS_PPT_SHAPE_INCLUDE_;_USE_LIBXML2_READER_;LIBXML_READER_ENABLED;AVS_USE_CONVERT_PPTX_TOCUSTOM_VML"
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;_ATL_ATTRIBUTES;_USE_MATH_DEFINES;NODOCX;PPTX_DEF;PPT_DEF;ENABLE_PPT_TO_PPTX_CONVERT;_AVS_PPT_SHAPE_INCLUDE_;_DOCWRAPPER_;LIBXML_READER_ENABLED;USE_LITE_READER;_USE_XMLLITE_READER_;AVS_USE_CONVERT_PPTX_TOCUSTOM_VML"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
......@@ -107,8 +107,8 @@
Name="VCCLCompilerTool"
FavorSizeOrSpeed="1"
WholeProgramOptimization="false"
AdditionalIncludeDirectories="..\..\Common\ASCDocxFormat\Source\Utility;..\..\Common\ASCDocxFormat\Source\XML;..\..\Common\ASCDocxFormat\Source;..\..\Common\DocxFormat\Source\XML\libxml2\XML\include;&quot;../../DesktopEditor/freetype-2.5.2/include&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_LIB;_ATL_ATTRIBUTES;_USE_MATH_DEFINES;NODOCX;PPTX_DEF;PPT_DEF;ENABLE_PPT_TO_PPTX_CONVERT;_AVS_PPT_SHAPE_INCLUDE_;_USE_LIBXML2_READER_;LIBXML_READER_ENABLED;AVS_USE_CONVERT_PPTX_TOCUSTOM_VML"
AdditionalIncludeDirectories="..\..\Common\ASCDocxFormat\Source\Utility;..\..\Common\ASCDocxFormat\Source\XML;..\..\Common\ASCDocxFormat\Source;..\..\Common\DocxFormat\Source\XML\libxml2\XML\include;&quot;..\..\DesktopEditor\freetype-2.5.2\include&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_LIB;_ATL_ATTRIBUTES;_USE_MATH_DEFINES;NODOCX;PPTX_DEF;PPT_DEF;ENABLE_PPT_TO_PPTX_CONVERT;_AVS_PPT_SHAPE_INCLUDE_;LIBXML_READER_ENABLED;USE_LITE_READER;_USE_XMLLITE_READER_;AVS_USE_CONVERT_PPTX_TOCUSTOM_VML"
RuntimeLibrary="2"
UsePrecompiledHeader="0"
WarningLevel="3"
......@@ -158,7 +158,11 @@
>
</File>
<File
RelativePath="..\..\Common\DocxFormat\Source\XML\libxml2\libxml2.cpp"
RelativePath="..\ASCOfficePPTXFile.cpp"
>
</File>
<File
RelativePath="..\ASCOfficePPTXFileRealization.cpp"
>
</File>
<File
......@@ -178,10 +182,6 @@
RelativePath="..\.\ASCOfficePPTXFile.h"
>
</File>
<File
RelativePath="..\..\Common\DocxFormat\Source\XML\libxml2\libxml2.h"
>
</File>
<File
RelativePath="..\..\Common\DocxFormat\Source\XML\stringcommon.h"
>
......@@ -203,48 +203,12 @@
>
</File>
<File
RelativePath="..\.\Editor\FontPicker.cpp"
RelativePath="..\Editor\FontPicker.cpp"
>
</File>
<File
RelativePath="..\..\ASCPresentationEditor\OfficeDrawing\Shapes\BaseShape\PPTXShape\Formula.cpp"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
ObjectFile="$(IntDir)\$(InputName)1.obj"
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
/>
</FileConfiguration>
<FileConfiguration
Name="Release|Win32"
>
<Tool
Name="VCCLCompilerTool"
ObjectFile="$(IntDir)\$(InputName)1.obj"
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
/>
</FileConfiguration>
<FileConfiguration
Name="ReleaseASC|Win32"
>
<Tool
Name="VCCLCompilerTool"
ObjectFile="$(IntDir)\$(InputName)1.obj"
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
/>
</FileConfiguration>
<FileConfiguration
Name="ReleaseOpenSource|Win32"
>
<Tool
Name="VCCLCompilerTool"
ObjectFile="$(IntDir)\$(InputName)1.obj"
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
/>
</FileConfiguration>
</File>
<File
RelativePath="..\..\ASCPresentationEditor\OfficeDrawing\Shapes\BaseShape\PPTShape\Formula.cpp"
......
......@@ -2,6 +2,6 @@
//1
//0
//0
//247
#define INTVER 1,0,0,247
#define STRVER "1,0,0,247\0"
//302
#define INTVER 1,0,0,302
#define STRVER "1,0,0,302\0"
......@@ -63,14 +63,13 @@ __interface IAVSPresentationEditor: IDispatch
[id(2001)] HRESULT GetAdditionalParam([in] BSTR ParamName, [out, retval] VARIANT* ParamValue);
};
//?????? ???
//[dispinterface, uuid("34EC371F-3F73-4a40-B8A6-FD21B9C3E789")]
//__interface _IAVSPresentationEditorEvents
//{
//};
[dispinterface, uuid("34EC371F-3F73-4a40-B8A6-FD21B9C3E789")]
__interface _IAVSPresentationEditorEvents
{
};
// CAVSPresentationEditor
[coclass, uuid("29759D68-916E-4317-BC8B-35793F7448B3")/*, event_source(com)*/, threading(apartment), vi_progid("AVSPptEditor.PptEditor"), progid("AVSPptEditor.PptEditor.1"), version(1.0)]
[coclass, uuid("29759D68-916E-4317-BC8B-35793F7448B3"), event_source(com), threading(apartment), vi_progid("AVSPptEditor.PptEditor"), progid("AVSPptEditor.PptEditor.1"), version(1.0)]
class ATL_NO_VTABLE CAVSPresentationEditor:
public IAVSPresentationEditor
{
......@@ -110,6 +109,8 @@ protected:
#endif
public:
__event __interface _IAVSPresentationEditorEvents;
CAVSPresentationEditor()
{
m_hSynchMutex = CreateMutex(NULL, FALSE, NULL);
......
#pragma once
#include "../../Common/DocxFormat/Source/SystemUtility/File.h"
#include <map>
namespace NSPresentationEditor
{
// xml
......@@ -57,17 +59,16 @@ namespace NSPresentationEditor
// common function
template <typename TKey, typename TVal>
void AppendAtlMap(CAtlMap<TKey, TVal>* pMapDst, const CAtlMap<TKey, TVal>* pMapSrc)
void AppendAtlMap(std::map<TKey, TVal>* pMapDst, const std::map<TKey, TVal>* pMapSrc)
{
if ((NULL == pMapDst) || (NULL == pMapSrc))
return;
POSITION pos = pMapSrc->GetStartPosition();
while (NULL != pos)
for (std::map<TKey, TVal>::iterator pPair = pMapSrc->begin(); pPair != pMapSrc->end(); ++pPair)
{
TKey key = pMapSrc->GetKeyAt(pos);
TVal value = pMapSrc->GetNextValue(pos);
pMapDst->SetAt(key, value);
TKey key = pPair->first;
TVal value = pPair->second;
(*pMapDst)[key] = value;
}
}
}
#pragma once
#include <vector>
namespace NSPresentationEditor
{
class CEffect
......@@ -28,7 +30,7 @@ namespace NSPresentationEditor
class CEffects
{
public:
CAtlArray<CEffect> m_arEffects;
std::vector<CEffect> m_arEffects;
public:
CEffects() : m_arEffects()
......@@ -36,7 +38,7 @@ namespace NSPresentationEditor
}
CEffects& operator=(const CEffects& oSrc)
{
m_arEffects.Copy(oSrc.m_arEffects);
m_arEffects.insert(m_arEffects.end(), oSrc.m_arEffects.begin(), oSrc.m_arEffects.end());
return *this;
}
CEffects(const CEffects& oSrc)
......
......@@ -181,12 +181,11 @@ namespace NSPresentationEditor
virtual void SetupProperties(CSlide* pSlide, CTheme* pTheme, CLayout* pLayout)
{
CAtlMap<CElementProperty::Type, CElementProperty>* pMap = &m_oProperties.m_arProperties;
std::map<CElementProperty::Type, CElementProperty>* pMap = &m_oProperties.m_arProperties;
POSITION pos = pMap->GetStartPosition();
while (NULL != pos)
for (std::map<CElementProperty::Type, CElementProperty>::iterator pPair = pMap->begin(); pPair != pMap->end(); ++pPair)
{
CElementProperty oProperty = pMap->GetNextValue(pos);
CElementProperty oProperty = pPair->second;
SetupProperty(pSlide, pTheme, pLayout, &oProperty);
}
}
......
#pragma once
#include <map>
namespace NSPresentationEditor
{
class CElementProperty
......@@ -114,7 +116,7 @@ namespace NSPresentationEditor
class CElementProperties
{
public:
CAtlMap<CElementProperty::Type, CElementProperty> m_arProperties;
std::map<CElementProperty::Type, CElementProperty> m_arProperties;
public:
CElementProperties() : m_arProperties()
......@@ -123,14 +125,14 @@ namespace NSPresentationEditor
public:
CElementProperties& operator=(const CElementProperties& oSrc)
{
m_arProperties.RemoveAll();
m_arProperties.clear();
POSITION pos = oSrc.m_arProperties.GetStartPosition();
while (NULL != pos)
for (std::map<CElementProperty::Type, CElementProperty>::const_iterator pPair = oSrc.m_arProperties.begin(); pPair != oSrc.m_arProperties.end(); ++pPair)
{
CElementProperty oProperty = oSrc.m_arProperties.GetNextValue(pos);
m_arProperties.SetAt(oProperty.m_ID, oProperty);
CElementProperty oProperty = pPair->second;
m_arProperties[oProperty.m_ID] = oProperty;
}
return *this;
}
CElementProperties(const CElementProperties& oSrc)
......@@ -140,7 +142,7 @@ namespace NSPresentationEditor
virtual ~CElementProperties()
{
m_arProperties.RemoveAll();
m_arProperties.clear();
}
inline void SetAt(const CElementProperty::Type& eType, const DWORD& dwValue)
......@@ -148,28 +150,28 @@ namespace NSPresentationEditor
CElementProperty oProp(eType);
oProp.m_dwValue = dwValue;
m_arProperties.SetAt(eType, oProp);
m_arProperties[eType] = oProp;
}
inline void SetAt(const CElementProperty::Type& eType, const BYTE& nValue)
{
CElementProperty oProp(eType);
oProp.m_dwValue = (DWORD)nValue;
m_arProperties.SetAt(eType, oProp);
m_arProperties[eType] = oProp;
}
inline void SetAt(const CElementProperty::Type& eType, const long& lValue)
{
CElementProperty oProp(eType);
oProp.m_dwValue = (DWORD)lValue;
m_arProperties.SetAt(eType, oProp);
m_arProperties[eType] = oProp;
}
inline void SetAt(const CElementProperty::Type& eType, const bool& bValue)
{
CElementProperty oProp(eType);
oProp.m_dwValue = (true == bValue) ? 1 : 0;
m_arProperties.SetAt(eType, oProp);
m_arProperties[eType] = oProp;
}
inline void SetAt(const CElementProperty::Type& eType, CString strValue)
{
......@@ -181,7 +183,7 @@ namespace NSPresentationEditor
oProp.m_strAdvanced[oProp.m_dwValue - 1] = 0;
m_arProperties.SetAt(eType, oProp);
m_arProperties[eType] = oProp;
}
};
}
......
......@@ -738,12 +738,11 @@ namespace NSPresentationEditor
virtual void SetupProperties(CSlide* pSlide, CTheme* pTheme, CLayout* pLayout)
{
CAtlMap<CElementProperty::Type, CElementProperty>* pMap = &m_oProperties.m_arProperties;
std::map<CElementProperty::Type, CElementProperty>* pMap = &m_oProperties.m_arProperties;
POSITION pos = pMap->GetStartPosition();
while (NULL != pos)
for (std::map<CElementProperty::Type, CElementProperty>::iterator pPair = pMap->begin(); pPair != pMap->end(); ++pPair)
{
CElementProperty oProperty = pMap->GetNextValue(pos);
CElementProperty oProperty = pPair->second;
SetupProperty(pSlide, pTheme, pLayout, &oProperty);
}
......
......@@ -37,7 +37,7 @@ namespace NSPresentationEditor
public:
bool m_bPresent;
CAtlArray<CTextRange> m_arRanges;
std::vector<CTextRange> m_arRanges;
public:
CInteractiveInfo()
......@@ -55,7 +55,7 @@ namespace NSPresentationEditor
m_bPresent = oSrc.m_bPresent;
m_arRanges.Copy(oSrc.m_arRanges);
m_arRanges.insert(m_arRanges.end(), oSrc.m_arRanges.begin(), oSrc.m_arRanges.end());
return *this;
}
......
......@@ -290,12 +290,12 @@ namespace NSPresentationEditor
}
private:
//
bool Save(CAtlArray<BYTE> &aTable)
bool Save(std::vector<BYTE> &aTable)
{
return false;
}
bool Load(CAtlArray<BYTE> &aTable)
bool Load(std::vector<BYTE> &aTable)
{
return false;
}
......@@ -382,12 +382,12 @@ namespace NSPresentationEditor
private:
//
bool Save(CAtlArray<BYTE> &aTable)
bool Save(std::vector<BYTE> &aTable)
{
return false;
}
bool Load(CAtlArray<BYTE> &aTable)
bool Load(std::vector<BYTE> &aTable)
{
return false;
}
......
......@@ -2,8 +2,6 @@
#include "../../Common/ASCUtils.h"
#include "../OfficeDrawing/TextAttributesEx.h"
#define _USE_XMLLITE_READER_
#include <map>
class CCSS
......
......@@ -2,12 +2,13 @@
#include "../stdafx.h"
#include "FileDownloader.h"
namespace NSPresentationEditor
{
class CImageManager
{
private:
CAtlMap<CString, CString> m_mapImages;
std::map<CString, CString> m_mapImages;
LONG m_lIndexNextImage;
CString m_strDstMedia;
......@@ -20,7 +21,7 @@ namespace NSPresentationEditor
}
AVSINLINE void Clear()
{
m_mapImages.RemoveAll();
m_mapImages.clear();
m_lIndexNextImage = 0;
}
AVSINLINE void SetDstMedia(const CString& strDst)
......@@ -31,9 +32,9 @@ namespace NSPresentationEditor
public:
AVSINLINE CString GenerateImage(const CString& strInput)
{
CAtlMap<CString, CString>::CPair* pPair = m_mapImages.Lookup(strInput);
if (NULL != pPair)
return pPair->m_value;
std::map<CString, CString>::iterator pPair = m_mapImages.find(strInput);
if (m_mapImages.end() != pPair)
return pPair->second;
if (IsNeedDownload(strInput))
return DownloadImage(strInput);
......@@ -51,7 +52,7 @@ namespace NSPresentationEditor
CString strOutput = m_strDstMedia + strImage + strExts;
strImage = _T("../media/") + strImage + strExts;
m_mapImages.SetAt(strInput, strImage);
m_mapImages[strInput] = strImage;
//
if (strOutput != strInput)
......@@ -91,7 +92,7 @@ namespace NSPresentationEditor
private:
NSPresentationEditor::CStringWriter m_oWriter;
int m_lNextRelsID;
CAtlMap<CString, int> m_mapImages;
std::map<CString, int> m_mapImages;
CImageManager* m_pManager;
public:
......@@ -106,7 +107,7 @@ namespace NSPresentationEditor
{
m_oWriter.ClearNoAttack();
m_lNextRelsID = 1;
m_mapImages.RemoveAll();
m_mapImages.clear();
}
AVSINLINE void StartMaster(int nIndexTheme, int nStartLayoutIndex, int nCountLayouts)
......@@ -212,16 +213,17 @@ namespace NSPresentationEditor
AVSINLINE CString WriteImage(const CString& strImagePath)
{
CString strImage = m_pManager->GenerateImage(strImagePath);
CAtlMap<CString, int>::CPair* pPair = m_mapImages.Lookup(strImage);
std::map<CString, int>::iterator pPair = m_mapImages.find(strImage);
if (NULL != pPair)
if (m_mapImages.end() != pPair)
{
CString strRid = _T("");
strRid.Format(_T("rId%d"), pPair->m_value);
strRid.Format(_T("rId%d"), pPair->second);
return strRid;
}
m_mapImages.SetAt(strImage, m_lNextRelsID);
m_mapImages[strImage] = m_lNextRelsID;
CString strRid = _T("");
strRid.Format(_T("rId%d"), m_lNextRelsID++);
......
......@@ -2,6 +2,6 @@
//1
//0
//0
//109
#define INTVER 1,0,0,109
#define STRVER "1,0,0,109\0"
//121
#define INTVER 1,0,0,121
#define STRVER "1,0,0,121\0"
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment