Kaydet (Commit) f2e6a55b authored tarafından Miklos Vajna's avatar Miklos Vajna

oox: kill no longer needed US() macro

Change-Id: Id1cd194a5968aa8578d0f2fefb3c75e3d74a25f5
üst 3f02531d
...@@ -20,7 +20,6 @@ ...@@ -20,7 +20,6 @@
#ifndef _OOX_EXPORT_UTILS_HXX_ #ifndef _OOX_EXPORT_UTILS_HXX_
#define _OOX_EXPORT_UTILS_HXX_ #define _OOX_EXPORT_UTILS_HXX_
#define US(x) rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( x ))
#define I32S(x) rtl::OString::valueOf( (sal_Int32) x ).getStr() #define I32S(x) rtl::OString::valueOf( (sal_Int32) x ).getStr()
#define I64S(x) rtl::OString::valueOf( (sal_Int64) x ).getStr() #define I64S(x) rtl::OString::valueOf( (sal_Int64) x ).getStr()
#define IS(x) rtl::OString::valueOf( x ).getStr() #define IS(x) rtl::OString::valueOf( x ).getStr()
......
...@@ -456,42 +456,42 @@ OUString DrawingML::WriteImage( const Graphic& rGraphic ) ...@@ -456,42 +456,42 @@ OUString DrawingML::WriteImage( const Graphic& rGraphic )
switch ( aLink.GetType() ) { switch ( aLink.GetType() ) {
case GFX_LINK_TYPE_NATIVE_GIF: case GFX_LINK_TYPE_NATIVE_GIF:
sMediaType = US( "image/gif" ); sMediaType = "image/gif";
pExtension = ".gif"; pExtension = ".gif";
break; break;
case GFX_LINK_TYPE_NATIVE_JPG: case GFX_LINK_TYPE_NATIVE_JPG:
sMediaType = US( "image/jpeg" ); sMediaType = "image/jpeg";
pExtension = ".jpeg"; pExtension = ".jpeg";
break; break;
case GFX_LINK_TYPE_NATIVE_PNG: case GFX_LINK_TYPE_NATIVE_PNG:
sMediaType = US( "image/png" ); sMediaType = "image/png";
pExtension = ".png"; pExtension = ".png";
break; break;
case GFX_LINK_TYPE_NATIVE_TIF: case GFX_LINK_TYPE_NATIVE_TIF:
sMediaType = US( "image/tiff" ); sMediaType = "image/tiff";
pExtension = ".tiff"; pExtension = ".tiff";
break; break;
case GFX_LINK_TYPE_NATIVE_WMF: case GFX_LINK_TYPE_NATIVE_WMF:
sMediaType = US( "image/x-wmf" ); sMediaType = "image/x-wmf";
pExtension = ".wmf"; pExtension = ".wmf";
break; break;
case GFX_LINK_TYPE_NATIVE_MET: case GFX_LINK_TYPE_NATIVE_MET:
sMediaType = US( "image/x-met" ); sMediaType = "image/x-met";
pExtension = ".met"; pExtension = ".met";
break; break;
case GFX_LINK_TYPE_NATIVE_PCT: case GFX_LINK_TYPE_NATIVE_PCT:
sMediaType = US( "image/x-pict" ); sMediaType = "image/x-pict";
pExtension = ".pct"; pExtension = ".pct";
break; break;
default: { default: {
GraphicType aType = rGraphic.GetType(); GraphicType aType = rGraphic.GetType();
if ( aType == GRAPHIC_BITMAP ) { if ( aType == GRAPHIC_BITMAP ) {
GraphicConverter::Export( aStream, rGraphic, CVT_PNG ); GraphicConverter::Export( aStream, rGraphic, CVT_PNG );
sMediaType = US( "image/png" ); sMediaType = "image/png";
pExtension = ".png"; pExtension = ".png";
} else if ( aType == GRAPHIC_GDIMETAFILE ) { } else if ( aType == GRAPHIC_GDIMETAFILE ) {
GraphicConverter::Export( aStream, rGraphic, CVT_EMF ); GraphicConverter::Export( aStream, rGraphic, CVT_EMF );
sMediaType = US( "image/x-emf" ); sMediaType = "image/x-emf";
pExtension = ".emf"; pExtension = ".emf";
} else { } else {
OSL_TRACE( "unhandled graphic type" ); OSL_TRACE( "unhandled graphic type" );
...@@ -515,7 +515,7 @@ OUString DrawingML::WriteImage( const Graphic& rGraphic ) ...@@ -515,7 +515,7 @@ OUString DrawingML::WriteImage( const Graphic& rGraphic )
xOutStream->closeOutput(); xOutStream->closeOutput();
sRelId = mpFB->addRelation( mpFS->getOutputStream(), sRelId = mpFB->addRelation( mpFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/image" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",
OUStringBuffer() OUStringBuffer()
.appendAscii( GetRelationCompPrefix() ) .appendAscii( GetRelationCompPrefix() )
.appendAscii( "media/image" ) .appendAscii( "media/image" )
...@@ -826,7 +826,7 @@ void DrawingML::WriteRunProperties( Reference< XPropertySet > rRun, sal_Bool bIs ...@@ -826,7 +826,7 @@ void DrawingML::WriteRunProperties( Reference< XPropertySet > rRun, sal_Bool bIs
mAny >>= sURL; mAny >>= sURL;
if( !sURL.isEmpty() ) { if( !sURL.isEmpty() ) {
OUString sRelId = mpFB->addRelation( mpFS->getOutputStream(), OUString sRelId = mpFB->addRelation( mpFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink",
sURL, true ); sURL, true );
mpFS->singleElementNS( XML_a, XML_hlinkClick, mpFS->singleElementNS( XML_a, XML_hlinkClick,
...@@ -1029,12 +1029,12 @@ void DrawingML::WriteParagraphNumbering( Reference< XPropertySet > rXPropSet, sa ...@@ -1029,12 +1029,12 @@ void DrawingML::WriteParagraphNumbering( Reference< XPropertySet > rXPropSet, sa
if ( aPropName == "NumberingType" ) if ( aPropName == "NumberingType" )
nNumberingType = *( (sal_Int16*)pValue ); nNumberingType = *( (sal_Int16*)pValue );
else if ( aPropName == "Prefix" ) { else if ( aPropName == "Prefix" ) {
if( *(OUString*)pValue == US( ")" ) ) if( *(OUString*)pValue == ")")
bPBoth = true; bPBoth = true;
} else if ( aPropName == "Suffix" ) { } else if ( aPropName == "Suffix" ) {
if( *(OUString*)pValue == US( "." ) ) if( *(OUString*)pValue == ".")
bSDot = true; bSDot = true;
else if( *(OUString*)pValue == US( ")" ) ) else if( *(OUString*)pValue == ")")
bPBehind = true; bPBehind = true;
} else if ( aPropName == "BulletChar" ) } else if ( aPropName == "BulletChar" )
{ {
......
...@@ -1340,7 +1340,7 @@ ShapeExport& ShapeExport::WriteOLE2Shape( Reference< XShape > xShape ) ...@@ -1340,7 +1340,7 @@ ShapeExport& ShapeExport::WriteOLE2Shape( Reference< XShape > xShape )
xOutStream->closeOutput(); xOutStream->closeOutput();
OUString sRelId = mpFB->addRelation( mpFS->getOutputStream(), OUString sRelId = mpFB->addRelation( mpFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/package" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/package",
OUStringBuffer() OUStringBuffer()
.appendAscii( GetRelationCompPrefix() ) .appendAscii( GetRelationCompPrefix() )
.appendAscii( "embeddings/spreadsheet" ) .appendAscii( "embeddings/spreadsheet" )
......
...@@ -334,14 +334,14 @@ bool PowerPointExport::exportDocument() throw() ...@@ -334,14 +334,14 @@ bool PowerPointExport::exportDocument() throw()
DrawingML::ResetCounters(); DrawingML::ResetCounters();
maShapeMap.clear (); maShapeMap.clear ();
addRelation( US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument" ), "ppt/presentation.xml" ); addRelation( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument", "ppt/presentation.xml" );
mPresentationFS = openFragmentStreamWithSerializer( US( "ppt/presentation.xml" ), mPresentationFS = openFragmentStreamWithSerializer( "ppt/presentation.xml",
US( "application/vnd.openxmlformats-officedocument.presentationml.presentation.main+xml" ) ); "application/vnd.openxmlformats-officedocument.presentationml.presentation.main+xml" );
addRelation( mPresentationFS->getOutputStream(), addRelation( mPresentationFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",
US( "theme/theme1.xml" ) ); "theme/theme1.xml" );
mPresentationFS->startElementNS( XML_p, XML_presentation, PNMSS, FSEND ); mPresentationFS->startElementNS( XML_p, XML_presentation, PNMSS, FSEND );
...@@ -1262,11 +1262,11 @@ void PowerPointExport::WriteAuthors() ...@@ -1262,11 +1262,11 @@ void PowerPointExport::WriteAuthors()
if ( maAuthors.size() <= 0 ) if ( maAuthors.size() <= 0 )
return; return;
FSHelperPtr pFS = openFragmentStreamWithSerializer( US( "ppt/commentAuthors.xml" ), FSHelperPtr pFS = openFragmentStreamWithSerializer( "ppt/commentAuthors.xml",
US( "application/vnd.openxmlformats-officedocument.presentationml.commentAuthors+xml" ) ); "application/vnd.openxmlformats-officedocument.presentationml.commentAuthors+xml" );
addRelation( mPresentationFS->getOutputStream(), addRelation( mPresentationFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/commentAuthors" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/commentAuthors",
US( "commentAuthors.xml" ) ); "commentAuthors.xml" );
pFS->startElementNS( XML_p, XML_cmAuthorLst, pFS->startElementNS( XML_p, XML_cmAuthorLst,
FSNS( XML_xmlns, XML_p ), "http://schemas.openxmlformats.org/presentationml/2006/main", FSNS( XML_xmlns, XML_p ), "http://schemas.openxmlformats.org/presentationml/2006/main",
...@@ -1315,7 +1315,7 @@ bool PowerPointExport::WriteComments( sal_uInt32 nPageNum ) ...@@ -1315,7 +1315,7 @@ bool PowerPointExport::WriteComments( sal_uInt32 nPageNum )
.append( (sal_Int32) nPageNum + 1 ) .append( (sal_Int32) nPageNum + 1 )
.appendAscii( ".xml" ) .appendAscii( ".xml" )
.makeStringAndClear(), .makeStringAndClear(),
US( "application/vnd.openxmlformats-officedocument.presentationml.comments+xml" ) ); "application/vnd.openxmlformats-officedocument.presentationml.comments+xml" );
pFS->startElementNS( XML_p, XML_cmLst, pFS->startElementNS( XML_p, XML_cmLst,
FSNS( XML_xmlns, XML_p ), "http://schemas.openxmlformats.org/presentationml/2006/main", FSNS( XML_xmlns, XML_p ), "http://schemas.openxmlformats.org/presentationml/2006/main",
...@@ -1372,7 +1372,7 @@ void PowerPointExport::ImplWriteSlide( sal_uInt32 nPageNum, sal_uInt32 nMasterNu ...@@ -1372,7 +1372,7 @@ void PowerPointExport::ImplWriteSlide( sal_uInt32 nPageNum, sal_uInt32 nMasterNu
// add explicit relation of presentation to this slide // add explicit relation of presentation to this slide
OUString sRelId = addRelation( mPresentationFS->getOutputStream(), OUString sRelId = addRelation( mPresentationFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slide" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slide",
OUStringBuffer() OUStringBuffer()
.appendAscii( "slides/slide" ) .appendAscii( "slides/slide" )
.append( (sal_Int32) nPageNum + 1 ) .append( (sal_Int32) nPageNum + 1 )
...@@ -1392,7 +1392,7 @@ void PowerPointExport::ImplWriteSlide( sal_uInt32 nPageNum, sal_uInt32 nMasterNu ...@@ -1392,7 +1392,7 @@ void PowerPointExport::ImplWriteSlide( sal_uInt32 nPageNum, sal_uInt32 nMasterNu
.append( (sal_Int32) nPageNum + 1 ) .append( (sal_Int32) nPageNum + 1 )
.appendAscii( ".xml" ) .appendAscii( ".xml" )
.makeStringAndClear(), .makeStringAndClear(),
US( "application/vnd.openxmlformats-officedocument.presentationml.slide+xml" ) ); "application/vnd.openxmlformats-officedocument.presentationml.slide+xml" );
if( mpSlidesFSArray.size() < mnPages ) if( mpSlidesFSArray.size() < mnPages )
mpSlidesFSArray.resize( mnPages ); mpSlidesFSArray.resize( mnPages );
...@@ -1428,7 +1428,7 @@ void PowerPointExport::ImplWriteSlide( sal_uInt32 nPageNum, sal_uInt32 nMasterNu ...@@ -1428,7 +1428,7 @@ void PowerPointExport::ImplWriteSlide( sal_uInt32 nPageNum, sal_uInt32 nMasterNu
// add implicit relation to slide layout // add implicit relation to slide layout
addRelation( pFS->getOutputStream(), addRelation( pFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideLayout" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideLayout",
OUStringBuffer() OUStringBuffer()
.appendAscii( "../slideLayouts/slideLayout" ) .appendAscii( "../slideLayouts/slideLayout" )
.append( GetLayoutFileId( GetPPTXLayoutId( GetLayoutOffset( mXPagePropSet ) ), nMasterNum ) ) .append( GetLayoutFileId( GetPPTXLayoutId( GetLayoutOffset( mXPagePropSet ) ), nMasterNum ) )
...@@ -1438,7 +1438,7 @@ void PowerPointExport::ImplWriteSlide( sal_uInt32 nPageNum, sal_uInt32 nMasterNu ...@@ -1438,7 +1438,7 @@ void PowerPointExport::ImplWriteSlide( sal_uInt32 nPageNum, sal_uInt32 nMasterNu
if ( WriteComments( nPageNum ) ) if ( WriteComments( nPageNum ) )
// add implicit relation to slide comments // add implicit relation to slide comments
addRelation( pFS->getOutputStream(), addRelation( pFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments",
OUStringBuffer() OUStringBuffer()
.appendAscii( "../comments/comment" ) .appendAscii( "../comments/comment" )
.append( (sal_Int32) nPageNum + 1 ) .append( (sal_Int32) nPageNum + 1 )
...@@ -1460,7 +1460,7 @@ void PowerPointExport::ImplWriteNotes( sal_uInt32 nPageNum ) ...@@ -1460,7 +1460,7 @@ void PowerPointExport::ImplWriteNotes( sal_uInt32 nPageNum )
.append( (sal_Int32) nPageNum + 1 ) .append( (sal_Int32) nPageNum + 1 )
.appendAscii( ".xml" ) .appendAscii( ".xml" )
.makeStringAndClear(), .makeStringAndClear(),
US( "application/vnd.openxmlformats-officedocument.presentationml.notesSlide+xml" ) ); "application/vnd.openxmlformats-officedocument.presentationml.notesSlide+xml" );
pFS->startElementNS( XML_p, XML_notes, PNMSS, FSEND ); pFS->startElementNS( XML_p, XML_notes, PNMSS, FSEND );
...@@ -1474,7 +1474,7 @@ void PowerPointExport::ImplWriteNotes( sal_uInt32 nPageNum ) ...@@ -1474,7 +1474,7 @@ void PowerPointExport::ImplWriteNotes( sal_uInt32 nPageNum )
// add implicit relation to slide // add implicit relation to slide
addRelation( pFS->getOutputStream(), addRelation( pFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slide" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slide",
OUStringBuffer() OUStringBuffer()
.appendAscii( "../slides/slide" ) .appendAscii( "../slides/slide" )
.append( (sal_Int32) nPageNum + 1 ) .append( (sal_Int32) nPageNum + 1 )
...@@ -1484,7 +1484,7 @@ void PowerPointExport::ImplWriteNotes( sal_uInt32 nPageNum ) ...@@ -1484,7 +1484,7 @@ void PowerPointExport::ImplWriteNotes( sal_uInt32 nPageNum )
// add slide implicit relation to notes // add slide implicit relation to notes
if( mpSlidesFSArray.size() >= nPageNum ) if( mpSlidesFSArray.size() >= nPageNum )
addRelation( mpSlidesFSArray[ nPageNum ]->getOutputStream(), addRelation( mpSlidesFSArray[ nPageNum ]->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/notesSlide" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/notesSlide",
OUStringBuffer() OUStringBuffer()
.appendAscii( "../notesSlides/notesSlide" ) .appendAscii( "../notesSlides/notesSlide" )
.append( (sal_Int32) nPageNum + 1 ) .append( (sal_Int32) nPageNum + 1 )
...@@ -1493,8 +1493,8 @@ void PowerPointExport::ImplWriteNotes( sal_uInt32 nPageNum ) ...@@ -1493,8 +1493,8 @@ void PowerPointExport::ImplWriteNotes( sal_uInt32 nPageNum )
// add implicit relation to notes master // add implicit relation to notes master
addRelation( pFS->getOutputStream(), addRelation( pFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/notesMaster" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/notesMaster",
US( "../notesMasters/notesMaster1.xml" ) ); "../notesMasters/notesMaster1.xml" );
DBG(printf("----------------\n")); DBG(printf("----------------\n"));
} }
...@@ -1503,7 +1503,7 @@ void PowerPointExport::AddLayoutIdAndRelation( FSHelperPtr pFS, sal_Int32 nLayou ...@@ -1503,7 +1503,7 @@ void PowerPointExport::AddLayoutIdAndRelation( FSHelperPtr pFS, sal_Int32 nLayou
{ {
// add implicit relation of slide master to slide layout // add implicit relation of slide master to slide layout
OUString sRelId = addRelation( pFS->getOutputStream(), OUString sRelId = addRelation( pFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideLayout" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideLayout",
OUStringBuffer() OUStringBuffer()
.appendAscii( "../slideLayouts/slideLayout" ) .appendAscii( "../slideLayouts/slideLayout" )
.append( nLayoutFileId ) .append( nLayoutFileId )
...@@ -1534,7 +1534,7 @@ void PowerPointExport::ImplWriteSlideMaster( sal_uInt32 nPageNum, Reference< XPr ...@@ -1534,7 +1534,7 @@ void PowerPointExport::ImplWriteSlideMaster( sal_uInt32 nPageNum, Reference< XPr
mPresentationFS->startElementNS( XML_p, XML_sldMasterIdLst, FSEND ); mPresentationFS->startElementNS( XML_p, XML_sldMasterIdLst, FSEND );
OUString sRelId = addRelation( mPresentationFS->getOutputStream(), OUString sRelId = addRelation( mPresentationFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideMaster" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideMaster",
OUStringBuffer() OUStringBuffer()
.appendAscii( "slideMasters/slideMaster" ) .appendAscii( "slideMasters/slideMaster" )
.append( (sal_Int32) nPageNum + 1 ) .append( (sal_Int32) nPageNum + 1 )
...@@ -1555,7 +1555,7 @@ void PowerPointExport::ImplWriteSlideMaster( sal_uInt32 nPageNum, Reference< XPr ...@@ -1555,7 +1555,7 @@ void PowerPointExport::ImplWriteSlideMaster( sal_uInt32 nPageNum, Reference< XPr
.append( (sal_Int32) nPageNum + 1 ) .append( (sal_Int32) nPageNum + 1 )
.appendAscii( ".xml" ) .appendAscii( ".xml" )
.makeStringAndClear(), .makeStringAndClear(),
US( "application/vnd.openxmlformats-officedocument.presentationml.slideMaster+xml" ) ); "application/vnd.openxmlformats-officedocument.presentationml.slideMaster+xml" );
if( mpMasterFSArray.size() < mnMasterPages ) if( mpMasterFSArray.size() < mnMasterPages )
mpMasterFSArray.resize( mnMasterPages ); mpMasterFSArray.resize( mnMasterPages );
mpMasterFSArray[ nPageNum ] = pFS; mpMasterFSArray[ nPageNum ] = pFS;
...@@ -1565,7 +1565,7 @@ void PowerPointExport::ImplWriteSlideMaster( sal_uInt32 nPageNum, Reference< XPr ...@@ -1565,7 +1565,7 @@ void PowerPointExport::ImplWriteSlideMaster( sal_uInt32 nPageNum, Reference< XPr
// add implicit relation to the presentation theme // add implicit relation to the presentation theme
addRelation( pFS->getOutputStream(), addRelation( pFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",
OUStringBuffer() OUStringBuffer()
.appendAscii( "../theme/theme" ) .appendAscii( "../theme/theme" )
.append( (sal_Int32) nPageNum + 1 ) .append( (sal_Int32) nPageNum + 1 )
...@@ -1651,7 +1651,7 @@ void PowerPointExport::ImplWritePPTXLayout( sal_Int32 nOffset, sal_uInt32 nMaste ...@@ -1651,7 +1651,7 @@ void PowerPointExport::ImplWritePPTXLayout( sal_Int32 nOffset, sal_uInt32 nMaste
#endif #endif
Reference< beans::XPropertySet > xPropSet( xSlide, uno::UNO_QUERY ); Reference< beans::XPropertySet > xPropSet( xSlide, uno::UNO_QUERY );
xPropSet->setPropertyValue( US( "Layout" ), makeAny( short( aLayoutInfo[ nOffset ].nType ) ) ); xPropSet->setPropertyValue( "Layout", makeAny( short( aLayoutInfo[ nOffset ].nType ) ) );
DBG(dump_pset( xPropSet )); DBG(dump_pset( xPropSet ));
mXPagePropSet = Reference< XPropertySet >( xSlide, UNO_QUERY ); mXPagePropSet = Reference< XPropertySet >( xSlide, UNO_QUERY );
...@@ -1670,11 +1670,11 @@ void PowerPointExport::ImplWritePPTXLayout( sal_Int32 nOffset, sal_uInt32 nMaste ...@@ -1670,11 +1670,11 @@ void PowerPointExport::ImplWritePPTXLayout( sal_Int32 nOffset, sal_uInt32 nMaste
.append( (sal_Int32) mnLayoutFileIdMax ) .append( (sal_Int32) mnLayoutFileIdMax )
.appendAscii( ".xml" ) .appendAscii( ".xml" )
.makeStringAndClear(), .makeStringAndClear(),
US( "application/vnd.openxmlformats-officedocument.presentationml.slideLayout+xml" ) ); "application/vnd.openxmlformats-officedocument.presentationml.slideLayout+xml" );
// add implicit relation of slide layout to slide master // add implicit relation of slide layout to slide master
addRelation( pFS->getOutputStream(), addRelation( pFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideMaster" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideMaster",
OUStringBuffer() OUStringBuffer()
.appendAscii( "../slideMasters/slideMaster" ) .appendAscii( "../slideMasters/slideMaster" )
.append( (sal_Int32) nMasterNum + 1 ) .append( (sal_Int32) nMasterNum + 1 )
...@@ -2046,7 +2046,7 @@ void PowerPointExport::WriteTheme( sal_Int32 nThemeNum ) ...@@ -2046,7 +2046,7 @@ void PowerPointExport::WriteTheme( sal_Int32 nThemeNum )
.append( (sal_Int32) nThemeNum + 1 ) .append( (sal_Int32) nThemeNum + 1 )
.appendAscii( ".xml" ) .appendAscii( ".xml" )
.makeStringAndClear(), .makeStringAndClear(),
US( "application/vnd.openxmlformats-officedocument.theme+xml" ) ); "application/vnd.openxmlformats-officedocument.theme+xml" );
pFS->startElementNS( XML_a, XML_theme, pFS->startElementNS( XML_a, XML_theme,
FSNS( XML_xmlns, XML_a), "http://schemas.openxmlformats.org/drawingml/2006/main", FSNS( XML_xmlns, XML_a), "http://schemas.openxmlformats.org/drawingml/2006/main",
...@@ -2082,8 +2082,8 @@ sal_Bool PowerPointExport::WriteNotesMaster() ...@@ -2082,8 +2082,8 @@ sal_Bool PowerPointExport::WriteNotesMaster()
mPresentationFS->startElementNS( XML_p, XML_notesMasterIdLst, FSEND ); mPresentationFS->startElementNS( XML_p, XML_notesMasterIdLst, FSEND );
OUString sRelId = addRelation( mPresentationFS->getOutputStream(), OUString sRelId = addRelation( mPresentationFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/notesMaster" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/notesMaster",
US( "notesMasters/notesMaster1.xml" ) ); "notesMasters/notesMaster1.xml" );
mPresentationFS->singleElementNS( XML_p, XML_notesMasterId, mPresentationFS->singleElementNS( XML_p, XML_notesMasterId,
FSNS( XML_r, XML_id ), USS( sRelId ), FSNS( XML_r, XML_id ), USS( sRelId ),
...@@ -2092,14 +2092,14 @@ sal_Bool PowerPointExport::WriteNotesMaster() ...@@ -2092,14 +2092,14 @@ sal_Bool PowerPointExport::WriteNotesMaster()
mPresentationFS->endElementNS( XML_p, XML_notesMasterIdLst ); mPresentationFS->endElementNS( XML_p, XML_notesMasterIdLst );
FSHelperPtr pFS = FSHelperPtr pFS =
openFragmentStreamWithSerializer( US( "ppt/notesMasters/notesMaster1.xml" ), openFragmentStreamWithSerializer( "ppt/notesMasters/notesMaster1.xml",
US( "application/vnd.openxmlformats-officedocument.presentationml.notesMaster+xml" ) ); "application/vnd.openxmlformats-officedocument.presentationml.notesMaster+xml" );
// write theme per master // write theme per master
WriteTheme( mnMasterPages ); WriteTheme( mnMasterPages );
// add implicit relation to the presentation theme // add implicit relation to the presentation theme
addRelation( pFS->getOutputStream(), addRelation( pFS->getOutputStream(),
US( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme" ), "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",
OUStringBuffer() OUStringBuffer()
.appendAscii( "../theme/theme" ) .appendAscii( "../theme/theme" )
.append( (sal_Int32) mnMasterPages + 1 ) .append( (sal_Int32) mnMasterPages + 1 )
......
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