From fb14be5f8f74f83ba89e15f891ddf1f753dcc62f Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Thu, 12 Mar 2015 14:53:28 +0200 Subject: create new 'enum class' SotClipboardFormatId to unify types of which there are several. There are some issues here I am unsure of - the SW and SC and CHART2 modules essentially ignore the enum values and assign their own ids Perhaps I should change them to use the common values and create new enum values where necessary? - the sc/qa/ and sq/qa/ and starmath/qa/ code was doing some dodgy stuff. I translated the code to pass down the stuff numeric values to the underlying code, but perhaps further fixing is necessary? Change-Id: Ic06d723e404481e3f1bca67c43b70321b764d923 --- svx/source/tbxctrls/colrctrl.cxx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'svx/source/tbxctrls/colrctrl.cxx') diff --git a/svx/source/tbxctrls/colrctrl.cxx b/svx/source/tbxctrls/colrctrl.cxx index 689932bda7ad..f78e8276db9e 100644 --- a/svx/source/tbxctrls/colrctrl.cxx +++ b/svx/source/tbxctrls/colrctrl.cxx @@ -52,7 +52,7 @@ protected: virtual void AddSupportedFormats() SAL_OVERRIDE; virtual bool GetData( const css::datatransfer::DataFlavor& rFlavor, const OUString& rDestDoc ) SAL_OVERRIDE; - virtual bool WriteObject( SotStorageStreamRef& rxOStm, void* pUserObject, sal_uInt32 nUserObjectId, const ::com::sun::star::datatransfer::DataFlavor& rFlavor ) SAL_OVERRIDE; + virtual bool WriteObject( SotStorageStreamRef& rxOStm, void* pUserObject, SotClipboardFormatId nUserObjectId, const ::com::sun::star::datatransfer::DataFlavor& rFlavor ) SAL_OVERRIDE; public: @@ -64,7 +64,7 @@ public: void SvxColorValueSetData::AddSupportedFormats() { - AddFormat( SOT_FORMATSTR_ID_XFA ); + AddFormat( SotClipboardFormatId::XFA ); } @@ -73,16 +73,16 @@ bool SvxColorValueSetData::GetData( const css::datatransfer::DataFlavor& rFlavor { bool bRet = false; - if( SotExchange::GetFormat( rFlavor ) == SOT_FORMATSTR_ID_XFA ) + if( SotExchange::GetFormat( rFlavor ) == SotClipboardFormatId::XFA ) { - SetObject( &maData, 0, rFlavor ); + SetObject( &maData, SotClipboardFormatId::NONE, rFlavor ); bRet = true; } return bRet; } -bool SvxColorValueSetData::WriteObject( SotStorageStreamRef& rxOStm, void*, sal_uInt32 , const ::com::sun::star::datatransfer::DataFlavor& ) +bool SvxColorValueSetData::WriteObject( SotStorageStreamRef& rxOStm, void*, SotClipboardFormatId, const ::com::sun::star::datatransfer::DataFlavor& ) { WriteXFillExchangeData( *rxOStm, maData ); return( rxOStm->GetError() == ERRCODE_NONE ); -- cgit