summaryrefslogtreecommitdiff
path: root/sd
diff options
context:
space:
mode:
Diffstat (limited to 'sd')
-rw-r--r--sd/inc/pch/precompiled_sd.hxx1
-rw-r--r--sd/source/filter/eppt/eppt.cxx5
-rw-r--r--sd/source/filter/eppt/eppt.hxx1
-rw-r--r--sd/source/filter/eppt/epptso.cxx17
-rw-r--r--sd/source/filter/ppt/pptin.cxx13
-rw-r--r--sd/source/filter/ppt/pptin.hxx4
6 files changed, 23 insertions, 18 deletions
diff --git a/sd/inc/pch/precompiled_sd.hxx b/sd/inc/pch/precompiled_sd.hxx
index d69122633cb1..51524bf49a73 100644
--- a/sd/inc/pch/precompiled_sd.hxx
+++ b/sd/inc/pch/precompiled_sd.hxx
@@ -631,7 +631,6 @@
#include "editeng/lspcitem.hxx"
#include "svx/modctrl.hxx"
#include "svx/msdffdef.hxx"
-#include "filter/msfilter/msocximex.hxx"
#include "filter/msfilter/msoleexp.hxx"
#include "editeng/numitem.hxx"
#include "svx/obj3d.hxx"
diff --git a/sd/source/filter/eppt/eppt.cxx b/sd/source/filter/eppt/eppt.cxx
index b996d205cf1d..832e7b0b7c1c 100644
--- a/sd/source/filter/eppt/eppt.cxx
+++ b/sd/source/filter/eppt/eppt.cxx
@@ -64,6 +64,7 @@
#include <editeng/flditem.hxx>
#include <sfx2/docinf.hxx>
#include <oox/export/utils.hxx>
+#include <oox/ole/olehelper.hxx>
using namespace com::sun::star;
using namespace ::com::sun::star::uno;
@@ -1332,10 +1333,10 @@ void PPTWriter::ImplWriteOLE( )
{
if ( pPtr->xControlModel.is() )
{
- String aName;
+ rtl::OUString aName;
::com::sun::star::awt::Size aSize;
SvStorageRef xDest( new SvStorage( new SvMemoryStream(), sal_True ) );
- sal_Bool bOk = SvxMSConvertOCXControls::WriteOCXStream( xDest, pPtr->xControlModel, aSize, aName );
+ sal_Bool bOk = oox::ole::MSConvertOCXControls::WriteOCXStream( mXModel, xDest, pPtr->xControlModel, aSize, aName );
if ( bOk )
pStrm = xDest->CreateMemoryStream();
}
diff --git a/sd/source/filter/eppt/eppt.hxx b/sd/source/filter/eppt/eppt.hxx
index a3284bd9f810..5695aa595e45 100644
--- a/sd/source/filter/eppt/eppt.hxx
+++ b/sd/source/filter/eppt/eppt.hxx
@@ -83,7 +83,6 @@
#include <com/sun/star/container/XIndexContainer.hpp>
#include <com/sun/star/awt/XControlModel.hpp>
#include <com/sun/star/style/TabStop.hpp>
-#include <filter/msfilter/msocximex.hxx>
#include <com/sun/star/beans/XPropertySet.hpp>
#include <com/sun/star/beans/XPropertyState.hpp>
#include <com/sun/star/beans/XPropertySetInfo.hpp>
diff --git a/sd/source/filter/eppt/epptso.cxx b/sd/source/filter/eppt/epptso.cxx
index 62967ac171e1..10932acc9fa5 100644
--- a/sd/source/filter/eppt/epptso.cxx
+++ b/sd/source/filter/eppt/epptso.cxx
@@ -89,7 +89,7 @@
#include <com/sun/star/table/XMergeableCell.hpp>
#include <com/sun/star/table/BorderLine.hpp>
#include <set>
-
+#include <oox/ole/olehelper.hxx>
#include "i18npool/mslangid.hxx"
using namespace ::com::sun::star;
@@ -2564,9 +2564,9 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
<< (sal_uInt32)0x0012de00;
::com::sun::star::awt::Size aSize;
- String aControlName;
+ rtl::OUString aControlName;
SvStorageRef xTemp( new SvStorage( new SvMemoryStream(), sal_True ) );
- if ( SvxMSConvertOCXControls::WriteOCXStream( xTemp, aXControlModel, aSize, aControlName ) )
+ if ( oox::ole::MSConvertOCXControls::WriteOCXStream( mXModel, xTemp, aXControlModel, aSize, aControlName ) )
{
String aUserName( xTemp->GetUserName() );
String aOleIdentifier;
@@ -2602,7 +2602,8 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
}
}
}
- if ( aControlName.Len() )
+
+ if ( aControlName.getLength() )
PPTWriter::WriteCString( *mpExEmbed, aControlName, 1 );
if ( aOleIdentifier.Len() )
PPTWriter::WriteCString( *mpExEmbed, aOleIdentifier, 2 );
@@ -2623,15 +2624,15 @@ void PPTWriter::ImplWritePage( const PHLayout& rLayout, EscherSolverContainer& a
aPropOpt.AddOpt( ESCHER_Prop_pictureId, mnExEmbed );
aPropOpt.AddOpt( ESCHER_Prop_pictureActive, 0x10000 );
- if ( aControlName.Len() )
+ if ( aControlName.getLength() )
{
sal_uInt16 i, nBufSize;
- nBufSize = ( aControlName.Len() + 1 ) << 1;
+ nBufSize = ( aControlName.getLength() + 1 ) << 1;
sal_uInt8* pBuf = new sal_uInt8[ nBufSize ];
sal_uInt8* pTmp = pBuf;
- for ( i = 0; i < aControlName.Len(); i++ )
+ for ( i = 0; i < aControlName.getLength(); i++ )
{
- sal_Unicode nUnicode = aControlName.GetChar( i );
+ sal_Unicode nUnicode = *(aControlName.getStr() + i);
*pTmp++ = (sal_uInt8)nUnicode;
*pTmp++ = (sal_uInt8)( nUnicode >> 8 );
}
diff --git a/sd/source/filter/ppt/pptin.cxx b/sd/source/filter/ppt/pptin.cxx
index 0f4c8824758f..2620f2026c36 100644
--- a/sd/source/filter/ppt/pptin.cxx
+++ b/sd/source/filter/ppt/pptin.cxx
@@ -103,6 +103,7 @@
#include <comphelper/processfactory.hxx>
#include <comphelper/componentcontext.hxx>
#include <comphelper/string.hxx>
+#include <oox/ole/olehelper.hxx>
using namespace ::com::sun::star;
@@ -2707,10 +2708,16 @@ SdrObject* ImplSdPPTImport::ProcessObj( SvStream& rSt, DffObjData& rObjData, voi
bool
-ImplSdPPTImport::ReadFormControl( uno::Reference< io::XInputStream >& xIs, com::sun::star::uno::Reference< com::sun::star::form::XFormComponent > & rFormComp ) const
+ImplSdPPTImport::ReadFormControl( SotStorageRef& rSrc1, com::sun::star::uno::Reference< com::sun::star::form::XFormComponent > & rFormComp ) const
{
- ::oox::ole::OleFormCtrlImportHelper maFormCtrlHelper( xIs, lcl_getUnoCtx(), mpDoc->GetDocSh()->GetModel() );
- return maFormCtrlHelper.importFormControlFromObjStorage( rFormComp );
+ uno::Reference< frame::XModel > xModel;
+ if ( mpDoc->GetDocSh() )
+ {
+ xModel = mpDoc->GetDocSh()->GetModel();
+ oox::ole::MSConvertOCXControls mCtrlImporter( xModel );
+ return mCtrlImporter.ReadOCXStorage( rSrc1, rFormComp );
+ }
+ return false;
}
// ---------------------
diff --git a/sd/source/filter/ppt/pptin.hxx b/sd/source/filter/ppt/pptin.hxx
index babc2a3ae538..39bd87405601 100644
--- a/sd/source/filter/ppt/pptin.hxx
+++ b/sd/source/filter/ppt/pptin.hxx
@@ -36,7 +36,6 @@
#include <filter/msfilter/msfiltertracer.hxx>
#include <com/sun/star/uno/Any.h>
#include <boost/shared_ptr.hpp>
-#include <oox/ole/olehelper.hxx>
class SdDrawDocument;
class SfxMedium;
@@ -71,7 +70,6 @@ class ImplSdPPTImport : public SdrPowerPointImport
SdrLayerID mnBackgroundObjectsLayerID;
tAnimationMap maAnimations;
-// ::oox::ole::OleFormCtrlImportHelper maFormCtrlHelper;
void SetHeaderFooterPageSettings( SdPage* pPage, const PptSlidePersistEntry* pMasterPersist );
void ImportPageEffect( SdPage* pPage, const sal_Bool bNewAnimationsUsed );
@@ -90,7 +88,7 @@ public:
~ImplSdPPTImport();
sal_Bool Import();
- virtual bool ReadFormControl( com::sun::star::uno::Reference< com::sun::star::io::XInputStream >& xIs, com::sun::star::uno::Reference< com::sun::star::form::XFormComponent > & rFormComp ) const;
+ virtual bool ReadFormControl( SotStorageRef& rSrc1, com::sun::star::uno::Reference< com::sun::star::form::XFormComponent > & rFormComp ) const;
};
class SdPPTImport