diff options
author | Noel Power <noel.power@novell.com> | 2011-09-23 17:31:46 +0100 |
---|---|---|
committer | Noel Power <noel.power@novell.com> | 2011-09-26 12:06:04 +0100 |
commit | 5609c512cd4d2899300b432d88d93cff05a05c87 (patch) | |
tree | 9d312ec779374bdc17934926fd612a09b06081c4 /sw | |
parent | f8f54cbb5d6a34ea74c4e92a3bdb8e34b7b101d6 (diff) |
move OCX_Control ( and subclasses ) and OCX control export to oox
Diffstat (limited to 'sw')
-rw-r--r-- | sw/inc/pch/precompiled_sw.hxx | 1 | ||||
-rw-r--r-- | sw/source/filter/ww8/wrtw8esh.cxx | 15 | ||||
-rw-r--r-- | sw/source/filter/ww8/wrtww8.cxx | 1 | ||||
-rw-r--r-- | sw/source/filter/ww8/wrtww8.hxx | 1 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8par.hxx | 13 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8par3.cxx | 1 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8par4.cxx | 1 |
7 files changed, 17 insertions, 16 deletions
diff --git a/sw/inc/pch/precompiled_sw.hxx b/sw/inc/pch/precompiled_sw.hxx index d577822dc843..bc40045e9695 100644 --- a/sw/inc/pch/precompiled_sw.hxx +++ b/sw/inc/pch/precompiled_sw.hxx @@ -760,7 +760,6 @@ #include "filter/msfilter/mscodec.hxx" #include "filter/msfilter/msdffimp.hxx" #include "filter/msfilter/msfiltertracer.hxx" -#include "filter/msfilter/msocximex.hxx" #include "filter/msfilter/msoleexp.hxx" #include "editeng/numitem.hxx" #include "svx/numvset.hxx" diff --git a/sw/source/filter/ww8/wrtw8esh.cxx b/sw/source/filter/ww8/wrtw8esh.cxx index 4abb4975a789..7695670cfcd3 100644 --- a/sw/source/filter/ww8/wrtw8esh.cxx +++ b/sw/source/filter/ww8/wrtw8esh.cxx @@ -110,6 +110,8 @@ #include <oox/ole/olehelper.hxx> #include <comphelper/componentcontext.hxx> #include <fstream> +#include <unotools/streamwrap.hxx> + using ::editeng::SvxBorderLine; using namespace com::sun::star; @@ -2783,7 +2785,8 @@ lcl_getUnoCtx() } -SwMSConvertControls::SwMSConvertControls( SfxObjectShell *pDSh,SwPaM *pP ) : SvxMSConvertOCXControls( pDSh,pP ), maFormCtrlHelper( pDocSh->GetMedium()->GetInputStream(), lcl_getUnoCtx(), pDocSh->GetModel() ) +SwMSConvertControls::SwMSConvertControls( SfxObjectShell *pDSh,SwPaM *pP ) : oox +::ole::MSConvertOCXControls( pDSh ? pDSh->GetModel() : NULL ), pPaM( pP ) { } @@ -2794,7 +2797,7 @@ sal_Bool SwMSConvertControls::ReadOCXStream( SotStorageRef& rSrc1, sal_Bool bFloatingCtrl ) { uno::Reference< form::XFormComponent > xFComp; - sal_Bool bRes = maFormCtrlHelper.importFormControlFromObjPool( xFComp, rtl::OUString( rSrc1->GetName() ) ); + sal_Bool bRes = oox::ole::MSConvertOCXControls::ReadOCXStorage( rSrc1, xFComp ); if ( bRes && xFComp.is() ) { com::sun::star::awt::Size aSz; // not used in import @@ -2833,13 +2836,17 @@ bool SwMSConvertControls::ExportControl(WW8Export &rWW8Wrt, const SdrObject *pOb SvStorageRef xOleStg = xObjPool->OpenSotStorage(sStorageName, STREAM_READWRITE|STREAM_SHARE_DENYALL); + if (!xOleStg.Is()) return false; - String sName; - if (!WriteOCXStream(xOleStg,xControlModel,aSize,sName)) + + rtl::OUString sUName; + if (!WriteOCXStream( mxModel, xOleStg,xControlModel,aSize,sUName)) return false; + String sName = sUName; + sal_uInt8 aSpecOLE[] = { 0x03, 0x6a, 0xFF, 0xFF, 0xFF, 0xFF, // sprmCPicLocation diff --git a/sw/source/filter/ww8/wrtww8.cxx b/sw/source/filter/ww8/wrtww8.cxx index 9f7eb841f16e..676ac87aa3c7 100644 --- a/sw/source/filter/ww8/wrtww8.cxx +++ b/sw/source/filter/ww8/wrtww8.cxx @@ -53,7 +53,6 @@ #include <editeng/hyznitem.hxx> #include <editeng/langitem.hxx> #include <filter/msfilter/msoleexp.hxx> -#include <filter/msfilter/msocximex.hxx> #include <editeng/lrspitem.hxx> #include <editeng/ulspitem.hxx> #include <editeng/boxitem.hxx> diff --git a/sw/source/filter/ww8/wrtww8.hxx b/sw/source/filter/ww8/wrtww8.hxx index 7359f2903b38..e2d7aeac22e7 100644 --- a/sw/source/filter/ww8/wrtww8.hxx +++ b/sw/source/filter/ww8/wrtww8.hxx @@ -38,7 +38,6 @@ #include <shellio.hxx> #include <wrt_fn.hxx> -#include <filter/msfilter/msocximex.hxx> #include "ww8struc.hxx" #include "ww8scan.hxx" diff --git a/sw/source/filter/ww8/ww8par.hxx b/sw/source/filter/ww8/ww8par.hxx index 901d87670320..1961630c5a15 100644 --- a/sw/source/filter/ww8/ww8par.hxx +++ b/sw/source/filter/ww8/ww8par.hxx @@ -31,7 +31,6 @@ #include <tools/string.hxx> #include <filter/msfilter/msdffimp.hxx> -#include <filter/msfilter/msocximex.hxx> #include <editeng/frmdir.hxx> #include <fltshell.hxx> // fuer den Attribut Stack @@ -582,16 +581,15 @@ enum SwWw8ControlType WW8_CT_DROPDOWN }; - -class WW8FormulaControl : public OCX_Control +class WW8FormulaControl { protected: SwWW8ImplReader &rRdr; public: WW8FormulaControl(const String& rN, SwWW8ImplReader &rR) - : OCX_Control(rN), rRdr(rR), fUnknown(0), fDropdownIndex(0), + : rRdr(rR), fUnknown(0), fDropdownIndex(0), fToolTip(0), fNoMark(0), fUseSize(0), fNumbersOnly(0), fDateOnly(0), - fUnused(0), nSize(0), hpsCheckBox(20), nChecked(0) + fUnused(0), nSize(0), hpsCheckBox(20), nChecked(0), sName( rN ) { } sal_uInt8 fUnknown:2; @@ -621,6 +619,7 @@ public: com::sun::star::uno::Reference < com::sun::star::form::XFormComponent> &rFComp, com::sun::star::awt::Size &rSz) = 0; + UniString sName; private: //No copying WW8FormulaControl(const WW8FormulaControl&); @@ -677,7 +676,7 @@ public: com::sun::star::awt::Size & /* rSz */) { return sal_False; } }; -class SwMSConvertControls: public SvxMSConvertOCXControls +class SwMSConvertControls: public oox::ole::MSConvertOCXControls { public: SwMSConvertControls( SfxObjectShell *pDSh,SwPaM *pP ); @@ -693,7 +692,7 @@ public: com::sun::star::drawing::XShape > *pShapeRef=0, sal_Bool bFloatingCtrl=false ); private: - ::oox::ole::OleFormCtrlImportHelper maFormCtrlHelper; + SwPaM *pPaM; }; class SwMSDffManager : public SvxMSDffManager diff --git a/sw/source/filter/ww8/ww8par3.cxx b/sw/source/filter/ww8/ww8par3.cxx index 604a81170b69..1b38b33ead64 100644 --- a/sw/source/filter/ww8/ww8par3.cxx +++ b/sw/source/filter/ww8/ww8par3.cxx @@ -72,7 +72,6 @@ #include <editeng/crsditem.hxx> #include <editeng/udlnitem.hxx> #include <editeng/postitem.hxx> -#include <filter/msfilter/msocximex.hxx> #include <unotextrange.hxx> #include <doc.hxx> #include <docary.hxx> diff --git a/sw/source/filter/ww8/ww8par4.cxx b/sw/source/filter/ww8/ww8par4.cxx index c99d48d9555e..98d0ba9e5dd4 100644 --- a/sw/source/filter/ww8/ww8par4.cxx +++ b/sw/source/filter/ww8/ww8par4.cxx @@ -41,7 +41,6 @@ #include <svx/svdoole2.hxx> #include <filter/msfilter/msdffimp.hxx> #include <svx/unoapi.hxx> -#include <filter/msfilter/msocximex.hxx> #include <sot/exchange.hxx> #include <swtypes.hxx> |