diff options
author | Jianyuan Li <lijiany@apache.org> | 2012-09-11 08:00:21 +0000 |
---|---|---|
committer | Jianyuan Li <lijiany@apache.org> | 2012-09-11 08:00:21 +0000 |
commit | f1ecd5ff46a217ee9f4323a08f03e59a53ef551e (patch) | |
tree | 0855affeb69eef5ad4d6a14826ce8f6dddf523dc /sd | |
parent | 4960217394334be14d6d7172119cee7c8e78479f (diff) |
#119467# Form controls cannot be saved into .ppt file in AOO3.4
Reported by: Du Jing
Patch by: Jianyuan Li
Review by: sunying
Notes
Notes:
merged as: f38487511957971f9d08dd5c9af8f8128371540e
Diffstat (limited to 'sd')
-rw-r--r-- | sd/source/filter/eppt/eppt.cxx | 3 | ||||
-rw-r--r-- | sd/source/filter/eppt/epptso.cxx | 4 |
2 files changed, 6 insertions, 1 deletions
diff --git a/sd/source/filter/eppt/eppt.cxx b/sd/source/filter/eppt/eppt.cxx index 398bab06b14f..fd875a27ed60 100644 --- a/sd/source/filter/eppt/eppt.cxx +++ b/sd/source/filter/eppt/eppt.cxx @@ -1826,7 +1826,8 @@ void PPTWriter::ImplWriteOLE( sal_uInt32 nCnvrtFlags ) if ( pPtr->xControlModel.is() ) { String aName; - ::com::sun::star::awt::Size aSize; + //Initialize the graphic size which will be used on export + ::com::sun::star::awt::Size aSize( pPtr->xShape->getSize() ); SvStorageRef xDest( new SvStorage( new SvMemoryStream(), sal_True ) ); sal_Bool bOk = SvxMSConvertOCXControls::WriteOCXStream( xDest, pPtr->xControlModel, aSize, aName ); if ( bOk ) diff --git a/sd/source/filter/eppt/epptso.cxx b/sd/source/filter/eppt/epptso.cxx index c79f3364e0d5..57a500720274 100644 --- a/sd/source/filter/eppt/epptso.cxx +++ b/sd/source/filter/eppt/epptso.cxx @@ -4593,6 +4593,7 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a << nPageId; PPTExOleObjEntry* pEntry = new PPTExOleObjEntry( OCX_CONTROL, mpExEmbed->Tell() ); pEntry->xControlModel = aXControlModel; + pEntry->xShape = mXShape; maExOleObj.Insert( pEntry ); mnExEmbed++; @@ -4666,6 +4667,9 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a ImplCreateShape( ESCHER_ShpInst_HostControl, nSpFlags, aSolverContainer ); if ( aPropOpt.CreateGraphicProperties( mXPropSet, String( RTL_CONSTASCII_USTRINGPARAM( "MetaFile" ) ), sal_False ) ) aPropOpt.AddOpt( ESCHER_Prop_LockAgainstGrouping, 0x800080 ); + //export form control graphic + else if ( aPropOpt.CreateBlipPropertiesforOLEControl(mXPropSet,mXShape)) + aPropOpt.AddOpt( ESCHER_Prop_LockAgainstGrouping, 0x800080 ); aPropOpt.AddOpt( ESCHER_Prop_pictureId, mnExEmbed ); aPropOpt.AddOpt( ESCHER_Prop_pictureActive, 0x10000 ); |