Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
onlyoffice_core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boris Kocherov
onlyoffice_core
Commits
80b1e5e8
Commit
80b1e5e8
authored
Aug 25, 2017
by
ElenaSubbotina
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
d1a7800f
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
36 additions
and
28 deletions
+36
-28
ASCOfficePPTXFile/ASCOfficeDrawingConverter.cpp
ASCOfficePPTXFile/ASCOfficeDrawingConverter.cpp
+18
-17
ASCOfficePPTXFile/ASCOfficeDrawingConverter.h
ASCOfficePPTXFile/ASCOfficeDrawingConverter.h
+6
-4
ASCOfficePPTXFile/PPTXFormat/Logic/CNvGraphicFramePr.h
ASCOfficePPTXFile/PPTXFormat/Logic/CNvGraphicFramePr.h
+1
-1
ASCOfficePPTXFile/PPTXFormat/Logic/Pic.cpp
ASCOfficePPTXFile/PPTXFormat/Logic/Pic.cpp
+9
-4
ASCOfficePPTXFile/PPTXFormat/Presentation.h
ASCOfficePPTXFile/PPTXFormat/Presentation.h
+2
-2
No files found.
ASCOfficePPTXFile/ASCOfficeDrawingConverter.cpp
View file @
80b1e5e8
...
...
@@ -913,20 +913,29 @@ HRESULT CDrawingConverter::SetMainDocument(BinDocxRW::CDocxSerializer* pDocument
return
S_OK
;
}
HRESULT
CDrawingConverter
::
SetMediaDstPath
(
const
std
::
wstring
&
bsMediaPath
)
void
CDrawingConverter
::
SetSrcPath
(
const
std
::
wstring
&
sPath
,
int
nDocType
)
{
m_pBinaryWriter
->
m_pCommon
->
m_pImageManager
->
m_strDstMedia
=
(
std
::
wstring
)
bsMediaPath
;
m_pImageManager
->
SetDstMedia
(
m_pBinaryWriter
->
m_pCommon
->
m_pImageManager
->
m_strDstMedia
)
;
m_pReader
->
m_pRels
->
m_pManager
=
m_pImageManager
;
m_pReader
->
m_strFolder
=
sPath
;
NSDirectory
::
CreateDirectory
(
bsMediaPath
);
return
S_OK
;
m_pImageManager
->
m_nDocumentType
=
nDocType
;
}
void
CDrawingConverter
::
SetDstPath
(
const
std
::
wstring
&
sPath
)
{
m_pImageManager
->
SetDstFolder
(
sPath
);
}
HRESULT
CDrawingConverter
::
SetEmbedDstPath
(
const
std
::
wstring
&
bsEmbed
Path
)
void
CDrawingConverter
::
SetMediaDstPath
(
const
std
::
wstring
&
s
Path
)
{
m_pImageManager
->
SetDstEmbed
(
bsEmbedPath
);
m_pBinaryWriter
->
m_pCommon
->
m_pImageManager
->
m_strDstMedia
=
sPath
;
m_pImageManager
->
SetDstMedia
(
sPath
);
NSDirectory
::
CreateDirectory
(
bsEmbedPath
);
return
S_OK
;
NSDirectory
::
CreateDirectory
(
sPath
);
}
void
CDrawingConverter
::
SetEmbedDstPath
(
const
std
::
wstring
&
sPath
)
{
m_pImageManager
->
SetDstEmbed
(
sPath
);
NSDirectory
::
CreateDirectory
(
sPath
);
}
HRESULT
CDrawingConverter
::
AddShapeType
(
const
std
::
wstring
&
bsXml
)
{
...
...
@@ -5274,14 +5283,6 @@ OOX::CContentTypes* CDrawingConverter::GetContentTypes()
//return m_pReader->mm_strContentTypes;
}
void
CDrawingConverter
::
SetSourceFileDir
(
std
::
wstring
path
,
int
nDocType
)
{
m_pReader
->
m_pRels
->
m_pManager
=
m_pImageManager
;
m_pReader
->
m_strFolder
=
path
;
m_pImageManager
->
m_nDocumentType
=
nDocType
;
}
void
CDrawingConverter
::
Clear
()
{
for
(
std
::
map
<
std
::
wstring
,
CShape
*>::
iterator
pPair
=
m_mapShapeTypes
.
begin
();
pPair
!=
m_mapShapeTypes
.
end
();
++
pPair
)
...
...
ASCOfficePPTXFile/ASCOfficeDrawingConverter.h
View file @
80b1e5e8
...
...
@@ -215,8 +215,12 @@ namespace NSBinPptxRW
smart_ptr
<
OOX
::
IFileContainer
>
GetRels
();
HRESULT
SetMainDocument
(
BinDocxRW
::
CDocxSerializer
*
pDocument
);
HRESULT
SetMediaDstPath
(
const
std
::
wstring
&
sMediaPath
);
HRESULT
SetEmbedDstPath
(
const
std
::
wstring
&
sEmbedPath
);
void
SetSrcPath
(
const
std
::
wstring
&
sPath
,
int
nDocType
=
1
/*XMLWRITER_DOC_TYPE_DOCX*/
);
void
SetDstPath
(
const
std
::
wstring
&
sPath
);
void
SetMediaDstPath
(
const
std
::
wstring
&
sMediaPath
);
void
SetEmbedDstPath
(
const
std
::
wstring
&
sEmbedPath
);
HRESULT
AddShapeType
(
const
std
::
wstring
&
sXml
);
HRESULT
AddObject
(
const
std
::
wstring
&
sXml
,
std
::
wstring
**
pMainProps
);
...
...
@@ -255,8 +259,6 @@ namespace NSBinPptxRW
void
SetDocumentChartsCount
(
int
val
);
int
GetDocumentChartsCount
();
void
SetSourceFileDir
(
std
::
wstring
path
,
int
nDocType
=
1
/*XMLWRITER_DOC_TYPE_DOCX*/
);
OOX
::
CContentTypes
*
GetContentTypes
();
protected:
nullable
<
PPTX
::
Logic
::
Xfrm
>
m_oxfrm_override
;
...
...
ASCOfficePPTXFile/PPTXFormat/Logic/CNvGraphicFramePr.h
View file @
80b1e5e8
...
...
@@ -134,7 +134,7 @@ namespace PPTX
if
(
pWriter
->
m_lDocType
==
XMLWRITER_DOC_TYPE_XLSX
)
namespace_
=
L"xdr"
;
if
(
pWriter
->
m_lDocType
==
XMLWRITER_DOC_TYPE_DOCX
)
{
namespaceLock_
=
L"
wp
"
;
namespaceLock_
=
L"
a
"
;
namespace_
=
L"wp"
;
}
...
...
ASCOfficePPTXFile/PPTXFormat/Logic/Pic.cpp
View file @
80b1e5e8
...
...
@@ -346,8 +346,11 @@ namespace PPTX
pReader
->
m_pRels
=
new
NSBinPptxRW
::
CRelsGenerator
();
oDrawingConverter
.
SetMainDocument
(
&
oDocxSerializer
);
oDrawingConverter
.
SetSourceFileDir
(
pReader
->
m_strFolder
,
1
);
oDrawingConverter
.
SetMediaDstPath
(
sMediaPath
);
oDrawingConverter
.
SetDstPath
(
sDstEmbeddedTemp
+
FILE_SEPARATOR_STR
+
L"word"
);
oDrawingConverter
.
SetSrcPath
(
pReader
->
m_strFolder
,
1
);
oDrawingConverter
.
SetMediaDstPath
(
sMediaPath
);
oDrawingConverter
.
SetEmbedDstPath
(
sEmbedPath
);
std
::
wstring
sDocxFilename
=
L"Microsoft_Word_Document"
+
std
::
to_wstring
(
id
)
+
L".docx"
;
...
...
@@ -434,8 +437,10 @@ namespace PPTX
oDrawingConverter
.
m_pReader
=
pReader
;
pReader
->
m_pRels
=
new
NSBinPptxRW
::
CRelsGenerator
();
oDrawingConverter
.
SetSourceFileDir
(
pReader
->
m_strFolder
,
2
);
oDrawingConverter
.
SetMediaDstPath
(
sMediaPath
);
oDrawingConverter
.
SetDstPath
(
sDstEmbeddedTemp
+
FILE_SEPARATOR_STR
+
L"xl"
);
oDrawingConverter
.
SetSrcPath
(
pReader
->
m_strFolder
,
2
);
oDrawingConverter
.
SetMediaDstPath
(
sMediaPath
);
oDrawingConverter
.
SetEmbedDstPath
(
sEmbedPath
);
std
::
wstring
sXlsxFilename
=
L"Microsoft_Excel_Worksheet"
+
std
::
to_wstring
(
id
)
+
L".xlsx"
;
...
...
ASCOfficePPTXFile/PPTXFormat/Presentation.h
View file @
80b1e5e8
...
...
@@ -469,8 +469,8 @@ namespace PPTX
bool
m_bMacroEnabled
;
smart_ptr
<
OOX
::
VbaProject
>
m_pVbaProject
;
void
SetClrMap
(
Logic
::
ClrMap
map
)
{
m_clrMap
=
map
;};
void
SetClrScheme
(
nsTheme
::
ClrScheme
scheme
)
{
m_clrScheme
=
scheme
;};
void
SetClrMap
(
Logic
::
ClrMap
map
)
{
m_clrMap
=
map
;}
void
SetClrScheme
(
nsTheme
::
ClrScheme
scheme
)
{
m_clrScheme
=
scheme
;}
DWORD
GetRGBAFromMap
(
const
std
::
wstring
&
str
)
const
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment