mirror of
https://github.com/ONLYOFFICE/core.git
synced 2026-02-10 18:05:41 +08:00
Merge pull request 'Fix pdf properties exists' (#244) from fix/pdf-properties into hotfix/v8.3.2
Reviewed-on: https://git.onlyoffice.com/ONLYOFFICE/core/pulls/244
This commit is contained in:
@ -963,10 +963,7 @@ bool CPdfEditor::EditPage(int nPageIndex, bool bSet, bool bActualPos)
|
||||
{
|
||||
Object oRes;
|
||||
char* chKey2 = oTemp.dictGetKey(nIndex);
|
||||
if (strcmp("Font", chKey2) == 0 || strcmp("ExtGState", chKey2) == 0 || strcmp("XObject", chKey2) == 0 || strcmp("Shading", chKey2) == 0 || strcmp("Pattern", chKey2) == 0)
|
||||
oTemp.dictGetVal(nIndex, &oRes);
|
||||
else
|
||||
oTemp.dictGetValNF(nIndex, &oRes);
|
||||
oTemp.dictGetVal(nIndex, &oRes);
|
||||
DictToCDictObject(&oRes, pDict, false, chKey2);
|
||||
oRes.free();
|
||||
}
|
||||
|
||||
@ -372,7 +372,7 @@ TEST_F(CPdfFileTest, EditPdf)
|
||||
|
||||
TEST_F(CPdfFileTest, EditPdfFromBase64)
|
||||
{
|
||||
//GTEST_SKIP();
|
||||
GTEST_SKIP();
|
||||
|
||||
NSFonts::NSApplicationFontStream::SetGlobalMemoryStorage(NSFonts::NSApplicationFontStream::CreateDefaultGlobalMemoryStorage());
|
||||
|
||||
@ -417,14 +417,14 @@ TEST_F(CPdfFileTest, EditPdfFromBase64)
|
||||
|
||||
TEST_F(CPdfFileTest, EditPdfFromBin)
|
||||
{
|
||||
GTEST_SKIP();
|
||||
// GTEST_SKIP();
|
||||
|
||||
LoadFromFile();
|
||||
ASSERT_TRUE(pdfFile->EditPdf(wsDstFile));
|
||||
|
||||
// чтение бинарника
|
||||
NSFile::CFileBinary oFile;
|
||||
ASSERT_TRUE(oFile.OpenFile(NSFile::GetProcessDirectory() + L"/changes0.json"));
|
||||
ASSERT_TRUE(oFile.OpenFile(NSFile::GetProcessDirectory() + L"/changes.bin"));
|
||||
|
||||
DWORD dwFileSize = oFile.GetFileSize();
|
||||
BYTE* pFileContent = new BYTE[dwFileSize];
|
||||
@ -440,7 +440,7 @@ TEST_F(CPdfFileTest, EditPdfFromBin)
|
||||
|
||||
CConvertFromBinParams* pParams = new CConvertFromBinParams();
|
||||
pParams->m_sMediaDirectory = NSFile::GetProcessDirectory();
|
||||
pdfFile->AddToPdfFromBinary(pFileContent, dwReaded, pParams);
|
||||
pdfFile->AddToPdfFromBinary(pFileContent + 4, dwReaded - 4, pParams);
|
||||
|
||||
RELEASEOBJECT(pParams);
|
||||
RELEASEARRAYOBJECTS(pFileContent);
|
||||
|
||||
Reference in New Issue
Block a user