Commit 2c83860c authored by ElenaSubbotina's avatar ElenaSubbotina

Merge branch 'develop' of https://github.com/ONLYOFFICE/core into develop

Conflicts:
	DesktopEditor/raster/Metafile/Emf/EmfFile.cpp
parents c64b624d 5e399093
...@@ -811,10 +811,10 @@ namespace DocFileFormat ...@@ -811,10 +811,10 @@ namespace DocFileFormat
{ {
Symbol s = getSymbol( chpx ); Symbol s = getSymbol( chpx );
m_pXmlWriter->WriteNodeBegin(L"w:sym", true); //m_pXmlWriter->WriteNodeBegin(L"w:sym", true);
m_pXmlWriter->WriteAttribute(L"w:font", FormatUtils::XmlEncode(s.FontName)); //m_pXmlWriter->WriteAttribute(L"w:font", FormatUtils::XmlEncode(s.FontName));
m_pXmlWriter->WriteAttribute(L"w:char", FormatUtils::XmlEncode(s.HexValue)); //m_pXmlWriter->WriteAttribute(L"w:char", FormatUtils::XmlEncode(s.HexValue));
m_pXmlWriter->WriteNodeEnd(L"", true); //m_pXmlWriter->WriteNodeEnd(L"", true);
} }
else if ((TextMark::DrawnObject == code) && fSpec) else if ((TextMark::DrawnObject == code) && fSpec)
{ {
...@@ -1663,12 +1663,17 @@ namespace DocFileFormat ...@@ -1663,12 +1663,17 @@ namespace DocFileFormat
FontFamilyName* ffn = static_cast<FontFamilyName*>( m_document->FontTable->operator [] ( fontIndex ) ); FontFamilyName* ffn = static_cast<FontFamilyName*>( m_document->FontTable->operator [] ( fontIndex ) );
ret.FontName = ffn->xszFtn; ret.FontName = ffn->xszFtn;
ret.HexValue = L"f0" + FormatUtils::IntToFormattedWideString( code, L"%02x" ); ret.HexValue = L"f0" + FormatUtils::IntToFormattedWideString( code, L"%02x" );//-123 - ShortToFormattedWideString
break; break;
} }
} }
if (ret.HexValue.length() > 4)
{
ret.HexValue = ret.HexValue.substr(ret.HexValue.length() - 4, 4);
}
return ret; return ret;
} }
......
...@@ -307,6 +307,7 @@ namespace ...@@ -307,6 +307,7 @@ namespace
content << L"<w:" << Node << L"s \ content << L"<w:" << Node << L"s \
xmlns:o=\"urn:schemas-microsoft-com:office:office\" \ xmlns:o=\"urn:schemas-microsoft-com:office:office\" \
xmlns:r=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships\" \ xmlns:r=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships\" \
xmlns:a=\"http://schemas.openxmlformats.org/drawingml/2006/main\" \
xmlns:w=\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\" \ xmlns:w=\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\" \
xmlns:w10=\"urn:schemas-microsoft-com:office:word\" \ xmlns:w10=\"urn:schemas-microsoft-com:office:word\" \
xmlns:w14=\"http://schemas.microsoft.com/office/word/2010/wordml\" \ xmlns:w14=\"http://schemas.microsoft.com/office/word/2010/wordml\" \
......
...@@ -553,7 +553,7 @@ namespace PPTX ...@@ -553,7 +553,7 @@ namespace PPTX
std::wstring strFillNode; std::wstring strFillNode;
std::wstring strStrokeNode;; std::wstring strStrokeNode;;
CalculateFill(spPr, style, oTheme, oClrMap, strFillAttr, strFillNode, bOle); CalculateFill(spPr, style, oTheme, oClrMap, strFillAttr, strFillNode, bOle, bSignature);
CalculateLine(spPr, style, oTheme, oClrMap, strStrokeAttr, strStrokeNode, bOle, bSignature); CalculateLine(spPr, style, oTheme, oClrMap, strStrokeAttr, strStrokeNode, bOle, bSignature);
pWriter->StartNode(L"v:shape"); pWriter->StartNode(L"v:shape");
......
...@@ -59,7 +59,7 @@ namespace PPTX ...@@ -59,7 +59,7 @@ namespace PPTX
} }
void CalculateFill(PPTX::Logic::SpPr& oSpPr, nullable<ShapeStyle>& pShapeStyle, NSCommon::smart_ptr<PPTX::Theme>& oTheme, void CalculateFill(PPTX::Logic::SpPr& oSpPr, nullable<ShapeStyle>& pShapeStyle, NSCommon::smart_ptr<PPTX::Theme>& oTheme,
NSCommon::smart_ptr<PPTX::Logic::ClrMap>& oClrMap, std::wstring& strAttr, std::wstring& strNode, bool bOle) NSCommon::smart_ptr<PPTX::Logic::ClrMap>& oClrMap, std::wstring& strAttr, std::wstring& strNode, bool bOle, bool bSignature)
{ {
PPTX::Logic::UniFill fill; PPTX::Logic::UniFill fill;
DWORD ARGB = 0; DWORD ARGB = 0;
...@@ -113,7 +113,7 @@ namespace PPTX ...@@ -113,7 +113,7 @@ namespace PPTX
std::wstring strId = oBlip.blip->embed->ToString(); std::wstring strId = oBlip.blip->embed->ToString();
if(bOle) if (bOle || bSignature)
{ {
strAttr = _T(" filled=\"f\""); strAttr = _T(" filled=\"f\"");
strNode = _T("<v:imagedata r:id=\"") + strId + _T("\" o:title=\"\" />"); strNode = _T("<v:imagedata r:id=\"") + strId + _T("\" o:title=\"\" />");
......
...@@ -44,7 +44,7 @@ namespace PPTX ...@@ -44,7 +44,7 @@ namespace PPTX
namespace Logic namespace Logic
{ {
void CalculateFill(PPTX::Logic::SpPr& oSpPr, nullable<ShapeStyle>& pShapeStyle, smart_ptr<PPTX::Theme>& oTheme, void CalculateFill(PPTX::Logic::SpPr& oSpPr, nullable<ShapeStyle>& pShapeStyle, smart_ptr<PPTX::Theme>& oTheme,
smart_ptr<PPTX::Logic::ClrMap>& oClrMap, std::wstring& strAttr, std::wstring& strNode, bool bOle = false); smart_ptr<PPTX::Logic::ClrMap>& oClrMap, std::wstring& strAttr, std::wstring& strNode, bool bOle = false, bool bSignature = false);
void CalculateLine(PPTX::Logic::SpPr& oSpPr, nullable<ShapeStyle>& pShapeStyle, void CalculateLine(PPTX::Logic::SpPr& oSpPr, nullable<ShapeStyle>& pShapeStyle,
smart_ptr<PPTX::Theme>& oTheme, smart_ptr<PPTX::Logic::ClrMap>& oClrMap, std::wstring& strAttr, std::wstring& strNode, bool bOle = false, bool bSignature = false); smart_ptr<PPTX::Theme>& oTheme, smart_ptr<PPTX::Logic::ClrMap>& oClrMap, std::wstring& strAttr, std::wstring& strNode, bool bOle = false, bool bSignature = false);
......
...@@ -644,6 +644,11 @@ namespace MetaFile ...@@ -644,6 +644,11 @@ namespace MetaFile
dKoefG = 255.0 / (ulMaskG >> ulShiftG); dKoefG = 255.0 / (ulMaskG >> ulShiftG);
dKoefB = 255.0 / (ulMaskB >> ulShiftB); dKoefB = 255.0 / (ulMaskB >> ulShiftB);
if ((ulMaskR >> ulShiftR) == 255 && (ulMaskG >> ulShiftG) == 255 && (ulMaskB >> ulShiftB) == 255)
{
bMask = false; // Proper_Attire_CALT2.odt
}
else
bMask = true; bMask = true;
} }
else else
......
...@@ -35,8 +35,142 @@ ...@@ -35,8 +35,142 @@
#include "../../../common/String.h" #include "../../../common/String.h"
#include "../../../fontengine/FontManager.h" #include "../../../fontengine/FontManager.h"
#ifdef _DEBUG
#include <iostream>
#endif
namespace MetaFile namespace MetaFile
{ {
static const struct ActionNamesEmf
{
int actionNumber;
std::wstring actionName;
} actionNamesEmf[] =
{
{ 0, L"Unknown"},
{ EMR_HEADER, L"EMR_HEADER"},
{ EMR_POLYBEZIER, L"EMR_POLYBEZIER"},
{ EMR_POLYGON, L"EMR_POLYGON"},
{ EMR_POLYLINE, L"EMR_POLYLINE"},
{ EMR_POLYBEZIERTO, L"EMR_POLYBEZIERTO"},
{ EMR_POLYLINETO, L"EMR_POLYLINETO"},
{ EMR_POLYPOLYLINE, L"EMR_POLYPOLYLINE"},
{ EMR_POLYPOLYGON, L"EMR_POLYPOLYGON"},
{ EMR_SETWINDOWEXTEX, L"EMR_SETWINDOWEXTEX"},
{ EMR_SETWINDOWORGEX, L"EMR_SETWINDOWORGEX"},
{ EMR_SETVIEWPORTEXTEX, L"EMR_SETVIEWPORTEXTEX"},
{ EMR_SETVIEWPORTORGEX, L"EMR_SETVIEWPORTORGEX"},
{ EMR_SETBRUSHORGEX, L"EMR_SETBRUSHORGEX"},
{ EMR_EOF, L"EMR_EOF"},
{ EMR_SETPIXELV, L"EMR_SETPIXELV"},
{ EMR_SETMAPPERFLAGS, L"EMR_SETMAPPERFLAGS"},
{ EMR_SETMAPMODE, L"EMR_SETMAPMODE"},
{ EMR_SETBKMODE, L"EMR_SETBKMODE"},
{ EMR_SETPOLYFILLMODE, L"EMR_SETPOLYFILLMODE"},
{ EMR_SETROP2, L"EMR_SETROP2"},
{ EMR_SETSTRETCHBLTMODE, L"EMR_SETSTRETCHBLTMODE"},
{ EMR_SETTEXTALIGN, L"EMR_SETTEXTALIGN"},
{ EMR_SETCOLORADJUSTMENT, L"EMR_SETCOLORADJUSTMENT"},
{ EMR_SETTEXTCOLOR, L"EMR_SETTEXTCOLOR"},
{ EMR_SETBKCOLOR, L"EMR_SETBKCOLOR"},
{ EMR_OFFSETCLIPRGN, L"EMR_OFFSETCLIPRGN"},
{ EMR_MOVETOEX, L"EMR_MOVETOEX"},
{ EMR_SETMETARGN, L"EMR_SETMETARGN"},
{ EMR_EXCLUDECLIPRECT, L"EMR_EXCLUDECLIPRECT"},
{ EMR_INTERSECTCLIPRECT, L"EMR_INTERSECTCLIPRECT"},
{ EMR_SCALEVIEWPORTEXTEX, L"EMR_SCALEVIEWPORTEXTEX"},
{ EMR_SCALEWINDOWEXTEX, L"EMR_SCALEWINDOWEXTEX"},
{ EMR_SAVEDC, L"EMR_SAVEDC"},
{ EMR_RESTOREDC, L"EMR_RESTOREDC"},
{ EMR_SETWORLDTRANSFORM, L"EMR_SETWORLDTRANSFORM"},
{ EMR_MODIFYWORLDTRANSFORM, L"EMR_MODIFYWORLDTRANSFORM"},
{ EMR_SELECTOBJECT, L"EMR_SELECTOBJECT"},
{ EMR_CREATEPEN, L"EMR_CREATEPEN"},
{ EMR_CREATEBRUSHINDIRECT, L"EMR_CREATEBRUSHINDIRECT"},
{ EMR_DELETEOBJECT, L"EMR_DELETEOBJECT"},
{ EMR_ANGLEARC, L"EMR_ANGLEARC"},
{ EMR_ELLIPSE, L"EMR_ELLIPSE"},
{ EMR_RECTANGLE, L"EMR_RECTANGLE"},
{ EMR_ROUNDRECT, L"EMR_ROUNDRECT"},
{ EMR_ARC, L"EMR_ARC"},
{ EMR_CHORD, L"EMR_CHORD"},
{ EMR_PIE, L"EMR_PIE"},
{ EMR_SELECTPALETTE, L"EMR_SELECTPALETTE"},
{ EMR_CREATEPALETTE, L"EMR_CREATEPALETTE"},
{ EMR_SETPALETTEENTRIES, L"EMR_SETPALETTEENTRIES"},
{ EMR_RESIZEPALETTE, L"EMR_RESIZEPALETTE"},
{ EMR_REALIZEPALETTE, L"EMR_REALIZEPALETTE"},
{ EMR_EXTFLOODFILL, L"EMR_EXTFLOODFILL"},
{ EMR_LINETO, L"EMR_LINETO"},
{ EMR_ARCTO, L"EMR_ARCTO"},
{ EMR_POLYDRAW, L"EMR_POLYDRAW"},
{ EMR_SETARCDIRECTION, L"EMR_SETARCDIRECTION"},
{ EMR_SETMITERLIMIT, L"EMR_SETMITERLIMIT"},
{ EMR_BEGINPATH, L"EMR_BEGINPATH"},
{ EMR_ENDPATH, L"EMR_ENDPATH"},
{ EMR_CLOSEFIGURE, L"EMR_CLOSEFIGURE"},
{ EMR_FILLPATH, L"EMR_FILLPATH"},
{ EMR_STROKEANDFILLPATH, L"EMR_STROKEANDFILLPATH"},
{ EMR_STROKEPATH, L"EMR_STROKEPATH"},
{ EMR_FLATTENPATH, L"EMR_FLATTENPATH"},
{ EMR_WIDENPATH, L"EMR_WIDENPATH"},
{ EMR_SELECTCLIPPATH, L"EMR_SELECTCLIPPATH"},
{ EMR_ABORTPATH, L"EMR_ABORTPATH"},
{ 69, L"Unknown"},
{ EMR_GDICOMMENT, L"EMR_GDICOMMENT"},
{ EMR_FILLRGN, L"EMR_FILLRGN"},
{ EMR_FRAMERGN, L"EMR_FRAMERGN"},
{ EMR_INVERTRGN, L"EMR_INVERTRGN"},
{ EMR_PAINTRGN, L"EMR_PAINTRGN"},
{ EMR_EXTSELECTCLIPRGN, L"EMR_EXTSELECTCLIPRGN"},
{ EMR_BITBLT, L"EMR_BITBLT"},
{ EMR_STRETCHBLT, L"EMR_STRETCHBLT"},
{ EMR_MASKBLT, L"EMR_MASKBLT"},
{ EMR_PLGBLT, L"EMR_PLGBLT"},
{ EMR_SETDIBITSTODEVICE, L"EMR_SETDIBITSTODEVICE"},
{ EMR_STRETCHDIBITS, L"EMR_STRETCHDIBITS"},
{ EMR_EXTCREATEFONTINDIRECTW, L"EMR_EXTCREATEFONTINDIRECTW"},
{ EMR_EXTTEXTOUTA, L"EMR_EXTTEXTOUTA"},
{ EMR_EXTTEXTOUTW, L"EMR_EXTTEXTOUTW"},
{ EMR_POLYBEZIER16, L"EMR_POLYBEZIER16"},
{ EMR_POLYGON16, L"EMR_POLYGON16"},
{ EMR_POLYLINE16, L"EMR_POLYLINE16"},
{ EMR_POLYBEZIERTO16, L"EMR_POLYBEZIERTO16"},
{ EMR_POLYLINETO16, L"EMR_POLYLINETO16"},
{ EMR_POLYPOLYLINE16, L"EMR_POLYPOLYLINE16"},
{ EMR_POLYPOLYGON16, L"EMR_POLYPOLYGON16"},
{ EMR_POLYDRAW16, L"EMR_POLYDRAW16"},
{ EMR_CREATEMONOBRUSH, L"EMR_CREATEMONOBRUSH"},
{ EMR_CREATEDIBPATTERNBRUSHPT,L"EMR_CREATEDIBPATTERNBRUSHPT"},
{ EMR_EXTCREATEPEN, L"EMR_EXTCREATEPEN"},
{ EMR_POLYTEXTOUTA, L"EMR_POLYTEXTOUTA"},
{ EMR_POLYTEXTOUTW, L"EMR_POLYTEXTOUTW"},
{ EMR_SETICMMODE, L"EMR_SETICMMODE"},
{ EMR_CREATECOLORSPACE, L"EMR_CREATECOLORSPACE"},
{ EMR_SETCOLORSPACE, L"EMR_SETCOLORSPACE"},
{ EMR_DELETECOLORSPACE, L"EMR_DELETECOLORSPACE"},
{ EMR_GLSRECORD, L"EMR_GLSRECORD"},
{ EMR_GLSBOUNDEDRECORD, L"EMR_GLSBOUNDEDRECORD"},
{ EMR_PIXELFORMAT, L"EMR_PIXELFORMAT"},
{ EMR_RESERVED_105, L"EMR_RESERVED_105"},
{ EMR_RESERVED_106, L"EMR_RESERVED_106"},
{ EMR_RESERVED_107, L"EMR_RESERVED_107"},
{ EMR_RESERVED_108, L"EMR_RESERVED_108"},
{ EMR_RESERVED_109, L"EMR_RESERVED_109"},
{ EMR_RESERVED_110, L"EMR_RESERVED_110"},
{ EMR_COLORCORRECTPALETTE, L"EMR_COLORCORRECTPALETTE"},
{ EMR_SETICMPROFILEA, L"EMR_SETICMPROFILEA"},
{ EMR_SETICMPROFILEW, L"EMR_SETICMPROFILEW"},
{ EMR_ALPHABLEND, L"EMR_ALPHABLEND"},
{ EMR_SETLAYOUT, L"EMR_SETLAYOUT"},
{ EMR_TRANSPARENTBLT, L"EMR_TRANSPARENTBLT"},
{ EMR_RESERVED_117, L"EMR_RESERVED_117"},
{ EMR_GRADIENTFILL, L"EMR_GRADIENTFILL"},
{ EMR_RESERVED_119, L"EMR_RESERVED_119"},
{ EMR_RESERVED_120, L"EMR_RESERVED_120"},
{ EMR_COLORMATCHTOTARGETW, L"EMR_COLORMATCHTOTARGETW"},
{ EMR_CREATECOLORSPACEW, L"EMR_CREATECOLORSPACEW "}
};
void CEmfFile::PlayMetaFile() void CEmfFile::PlayMetaFile()
{ {
if (!m_oStream.IsValid()) if (!m_oStream.IsValid())
...@@ -48,6 +182,7 @@ namespace MetaFile ...@@ -48,6 +182,7 @@ namespace MetaFile
bool bEof = false; bool bEof = false;
unsigned int ulRecordIndex = 0; unsigned int ulRecordIndex = 0;
unsigned int m_ulRecordPos = 0;
if (m_pOutput) if (m_pOutput)
m_pOutput->Begin(); m_pOutput->Begin();
...@@ -60,6 +195,7 @@ namespace MetaFile ...@@ -60,6 +195,7 @@ namespace MetaFile
m_oStream >> ulType; m_oStream >> ulType;
m_oStream >> ulSize; m_oStream >> ulSize;
m_ulRecordPos = m_oStream.Tell();
m_ulRecordSize = ulSize - 8; m_ulRecordSize = ulSize - 8;
if (ulType < EMR_MIN || ulType > EMR_MAX) if (ulType < EMR_MIN || ulType > EMR_MAX)
...@@ -204,6 +340,17 @@ namespace MetaFile ...@@ -204,6 +340,17 @@ namespace MetaFile
if (bEof) if (bEof)
break; break;
int need_skip = m_ulRecordSize - (m_oStream.Tell() - m_ulRecordPos);
m_oStream.Skip(need_skip);
#ifdef _DEBUG
if ( need_skip != 0 && !m_pOutput)
{
std::wstring name = actionNamesEmf[ulType].actionName;
std::wcout << name << L"\t\t(" << ulType << L")\t; skiped = " << need_skip << L"\n";
}
#endif
ulRecordIndex++; ulRecordIndex++;
} while (!CheckError()); } while (!CheckError());
...@@ -1425,6 +1572,8 @@ namespace MetaFile ...@@ -1425,6 +1572,8 @@ namespace MetaFile
template<typename T>void CEmfFile::Read_EMR_POLYDRAW_BASE() template<typename T>void CEmfFile::Read_EMR_POLYDRAW_BASE()
{ {
// TODO: Как найдутся файлы проверить данную запись. // TODO: Как найдутся файлы проверить данную запись.
//bug #35006 - не прочитывается весь рекорд ... выравнивание?
TEmfRectL oBounds; TEmfRectL oBounds;
m_oStream >> oBounds; m_oStream >> oBounds;
......
...@@ -360,6 +360,8 @@ namespace MetaFile ...@@ -360,6 +360,8 @@ namespace MetaFile
struct TEmfHeader struct TEmfHeader
{ {
TEmfHeader() : ulSignature(0), ulVersion(0), ulRecords(0), ushObjects(0), ulSize(0), ulPalEntries(0), ulOffsetDescription(0),ulSizeDescription(0) {}
TEmfRectL oBounds; TEmfRectL oBounds;
TEmfRectL oFrame; TEmfRectL oFrame;
unsigned int ulSignature; unsigned int ulSignature;
......
...@@ -50,11 +50,11 @@ ...@@ -50,11 +50,11 @@
namespace MetaFile namespace MetaFile
{ {
static const struct ActionNames static const struct ActionNamesSmv
{ {
int actionNumber; int actionNumber;
std::wstring actionName; std::wstring actionName;
} actionNames[] = } actionNamesSmv[] =
{ {
{ META_NULL_ACTION, L"META_NULL_ACTION" }, { META_NULL_ACTION, L"META_NULL_ACTION" },
{ META_PIXEL_ACTION, L"META_PIXEL_ACTION" }, { META_PIXEL_ACTION, L"META_PIXEL_ACTION" },
...@@ -224,7 +224,7 @@ void CSvmFile::PlayMetaFile() ...@@ -224,7 +224,7 @@ void CSvmFile::PlayMetaFile()
#ifdef _DEBUG #ifdef _DEBUG
if (100 <= actionType && actionType <= META_LAST_ACTION && need_skip > 0 && !m_pOutput) if (100 <= actionType && actionType <= META_LAST_ACTION && need_skip > 0 && !m_pOutput)
{ {
std::wstring name = actionNames[actionType - 99].actionName; std::wstring name = actionNamesSmv[actionType - 99].actionName;
std::wcout << name << L"\t\t" << actionType << L"\t(version = " << m_currentActionVersion << L")\t; skiped = " << need_skip << L"\n"; std::wcout << name << L"\t\t" << actionType << L"\t(version = " << m_currentActionVersion << L")\t; skiped = " << need_skip << L"\n";
} }
......
...@@ -77,6 +77,11 @@ public: ...@@ -77,6 +77,11 @@ public:
std::wstring GetImageBase64(const std::wstring& file) std::wstring GetImageBase64(const std::wstring& file)
{ {
if (0 == file.find(L"data:image/"))
{
return file.substr(file.find(L",") + 1);
}
BYTE* pData = NULL; BYTE* pData = NULL;
DWORD dwLen = 0; DWORD dwLen = 0;
if (!NSFile::CFileBinary::ReadAllBytes(file, &pData, dwLen)) if (!NSFile::CFileBinary::ReadAllBytes(file, &pData, dwLen))
...@@ -97,6 +102,8 @@ public: ...@@ -97,6 +102,8 @@ public:
std::wstring GetRelsReference(const std::wstring& file) std::wstring GetRelsReference(const std::wstring& file)
{ {
COOXMLRelationships oRels(m_sFolder + file, true); COOXMLRelationships oRels(m_sFolder + file, true);
if (oRels.rels.size() == 0)
return L"";
if (L"/_rels/.rels" == file) if (L"/_rels/.rels" == file)
{ {
......
...@@ -177,7 +177,15 @@ public: ...@@ -177,7 +177,15 @@ public:
std::wstring sSetupID = FindFirstChild(GetObjectById("idOfficeObject"), L"SetupID").GetText(); std::wstring sSetupID = FindFirstChild(GetObjectById("idOfficeObject"), L"SetupID").GetText();
m_guid = U_TO_UTF8(sSetupID); m_guid = U_TO_UTF8(sSetupID);
// 2) Check files (Manifect) // 2) Images
XmlUtils::CXmlNode nodeImageValid = GetObjectById("idValidSigLnImg");
if (nodeImageValid.IsValid())
m_sImageValidBase64 = GetBase64Image(nodeImageValid);
XmlUtils::CXmlNode nodeImageInvalid = GetObjectById("idInvalidSigLnImg");
if (nodeImageInvalid.IsValid())
m_sImageInvalidBase64 = GetBase64Image(nodeImageInvalid);
// 3) Check files (Manifect)
XmlUtils::CXmlNode nodeManifect = GetObjectById("idPackageObject"); XmlUtils::CXmlNode nodeManifect = GetObjectById("idPackageObject");
if (!nodeManifect.IsValid()) if (!nodeManifect.IsValid())
{ {
...@@ -197,14 +205,6 @@ public: ...@@ -197,14 +205,6 @@ public:
return; return;
} }
// 3) Images
XmlUtils::CXmlNode nodeImageValid = GetObjectById("idValidSigLnImg");
if (nodeImageValid.IsValid())
m_sImageValidBase64 = GetBase64Image(nodeImageValid);
XmlUtils::CXmlNode nodeImageInvalid = GetObjectById("idInvalidSigLnImg");
if (nodeImageInvalid.IsValid())
m_sImageInvalidBase64 = GetBase64Image(nodeImageInvalid);
// 4) Objects // 4) Objects
XmlUtils::CXmlNodes nodesReferences; XmlUtils::CXmlNodes nodesReferences;
m_node.ReadNode(L"SignedInfo").GetNodes(L"Reference", nodesReferences); m_node.ReadNode(L"SignedInfo").GetNodes(L"Reference", nodesReferences);
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
QT -= core QT -= core
QT -= gui QT -= gui
VERSION = 2.4.461.0 VERSION = 2.4.462.0
DEFINES += INTVER=$$VERSION DEFINES += INTVER=$$VERSION
TARGET = x2t TARGET = x2t
......
...@@ -486,6 +486,9 @@ namespace NExtractTools ...@@ -486,6 +486,9 @@ namespace NExtractTools
m_sTempDir = new std::wstring(sValue); m_sTempDir = new std::wstring(sValue);
} }
else if(_T("m_nCsvDelimiterChar") == sName) else if(_T("m_nCsvDelimiterChar") == sName)
{
std::wstring sNil;
if (!oXmlNode.GetAttributeIfExist(L"xsi:nil", sNil))
{ {
m_sCsvDelimiterChar = new std::wstring(L""); m_sCsvDelimiterChar = new std::wstring(L"");
} }
...@@ -493,6 +496,7 @@ namespace NExtractTools ...@@ -493,6 +496,7 @@ namespace NExtractTools
} }
} }
} }
}
return true; return true;
} }
std::wstring getPassword() const std::wstring getPassword() const
......
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