From f7124d57bc10b6e2960c86c4384a671ad7b4de02 Mon Sep 17 00:00:00 2001 From: Frank Schönheit Date: Mon, 14 Sep 2009 12:15:57 +0000 Subject: #cr6875455# mpLayoutData not directly accessible anymore --- svtools/source/contnr/ivctrl.cxx | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'svtools/source') diff --git a/svtools/source/contnr/ivctrl.cxx b/svtools/source/contnr/ivctrl.cxx index c0f40fd306df..e3342e288ae0 100644 --- a/svtools/source/contnr/ivctrl.cxx +++ b/svtools/source/contnr/ivctrl.cxx @@ -579,8 +579,7 @@ Rectangle SvtIconChoiceCtrl::GetBoundingBox( SvxIconChoiceCtrlEntry* pEntry ) co void SvtIconChoiceCtrl::FillLayoutData() const { - DBG_ASSERT( !mpLayoutData, "SvtIconChoiceCtrl::FillLayoutData: shouldn't this be called with non-existent layout data only?" ); - mpLayoutData = new ::vcl::ControlLayoutData(); + CreateLayoutData(); SvtIconChoiceCtrl* pNonConstMe = const_cast< SvtIconChoiceCtrl* >( this ); @@ -598,7 +597,7 @@ void SvtIconChoiceCtrl::FillLayoutData() const sal_Bool bLargeIconMode = WB_ICON == ( _pImp->GetStyle() & ( VIEWMODE_MASK ) ); sal_uInt16 nTextPaintFlags = bLargeIconMode ? PAINTFLAG_HOR_CENTERED : PAINTFLAG_VER_CENTERED; - _pImp->PaintItem( aTextRect, IcnViewFieldTypeText, pEntry, nTextPaintFlags, pNonConstMe, &sEntryText, mpLayoutData ); + _pImp->PaintItem( aTextRect, IcnViewFieldTypeText, pEntry, nTextPaintFlags, pNonConstMe, &sEntryText, GetLayoutData() ); ++nPos; } -- cgit From 959cfafb5d71c24b4568473fc3fa8c3bb8c30243 Mon Sep 17 00:00:00 2001 From: Ivo Hinkelmann Date: Tue, 27 Oct 2009 16:20:25 +0000 Subject: CWS-TOOLING: integrate CWS ooo32gsl01 2009-10-13 15:59:25 +0200 hdu r276868 : #i100000# fix remaining merge conflict 2009-10-12 16:08:38 +0200 hdu r276837 : CWS-TOOLING: rebase CWS ooo32gsl01 to branches/OOO320@276773 (milestone: OOO320:m1) 2009-09-15 10:09:52 +0200 hdu r276150 : #i104861# adjust metrics to pseudo-emUnits==1000 expectation for better precision allow non-integer charwidth/stemwidth 2009-09-15 09:58:00 +0200 hdu r276149 : #i104861# prepare to fix by updating cff.cxx to latest version from CWS vcl105 2009-09-14 16:06:46 +0200 hdu r276130 : #i104221# treat judeo-spanish varika as diacritic also in problematic fonts (thanks yoramg) 2009-09-14 15:27:14 +0200 hdu r276126 : #i104221# fix regression with he/ar diacritics 2009-09-10 15:39:58 +0200 aw r276038 : #i104867# added a GraphicVersion number to EmbeddedObjectRef to allow Grahic chamge checks without fetching the graphic 2009-09-10 15:38:41 +0200 aw r276037 : #i104867# added GraphicVersionNumber to SdrOleContentPrimitive to detect OLE content change without getting the Graphic 2009-09-09 17:16:43 +0200 hdu r276006 : #i104886# Aqua: fix for 101491 only applies to non-hairlines 2009-09-09 16:39:05 +0200 hdu r276002 : #i99849# don't give up on ScriptItemize too early --- svtools/source/misc/embedhlp.cxx | 41 ++++++++++++++++++++++++++++++++-------- 1 file changed, 33 insertions(+), 8 deletions(-) (limited to 'svtools/source') diff --git a/svtools/source/misc/embedhlp.cxx b/svtools/source/misc/embedhlp.cxx index 6bd1126f8082..edddb7c1ab6d 100644 --- a/svtools/source/misc/embedhlp.cxx +++ b/svtools/source/misc/embedhlp.cxx @@ -7,7 +7,6 @@ * OpenOffice.org - a multi-platform office productivity suite * * $RCSfile: embedhlp.cxx,v $ - * $Revision: 1.28 $ * * This file is part of OpenOffice.org. * @@ -189,7 +188,6 @@ void SAL_CALL EmbedEventListener_Impl::modified( const lang::EventObject& ) thro pObject->UpdateReplacementOnDemand(); } } - } void SAL_CALL EmbedEventListener_Impl::notifyEvent( const document::EventObject& aEvent ) throw( uno::RuntimeException ) @@ -250,6 +248,9 @@ struct EmbeddedObjectRef_Impl sal_Int64 nViewAspect; BOOL bIsLocked; sal_Bool bNeedUpdate; + + // #i104867# + sal_uInt32 mnGraphicVersion; awt::Size aDefaultSizeForChart_In_100TH_MM;//#i103460# charts do not necessaryly have an own size within ODF files, in this case they need to use the size settings from the surrounding frame, which is made available with this member }; @@ -262,6 +263,7 @@ void EmbeddedObjectRef::Construct_Impl() mpImp->nViewAspect = embed::Aspects::MSOLE_CONTENT; mpImp->bIsLocked = FALSE; mpImp->bNeedUpdate = sal_False; + mpImp->mnGraphicVersion = 0; mpImp->aDefaultSizeForChart_In_100TH_MM = awt::Size(8000,7000); } @@ -297,12 +299,14 @@ EmbeddedObjectRef::EmbeddedObjectRef( const EmbeddedObjectRef& rObj ) mpImp->pGraphic = 0; mpImp->pHCGraphic = 0; + mpImp->mnGraphicVersion = 0; } EmbeddedObjectRef::~EmbeddedObjectRef() { delete mpImp->pGraphic; - if ( mpImp->pHCGraphic ) DELETEZ( mpImp->pHCGraphic ); + if ( mpImp->pHCGraphic ) + DELETEZ( mpImp->pHCGraphic ); Clear(); } /* @@ -453,10 +457,15 @@ void EmbeddedObjectRef::GetReplacement( BOOL bUpdate ) DELETEZ( mpImp->pGraphic ); mpImp->aMediaType = ::rtl::OUString(); mpImp->pGraphic = new Graphic; - if ( mpImp->pHCGraphic ) DELETEZ( mpImp->pHCGraphic ); + if ( mpImp->pHCGraphic ) + DELETEZ( mpImp->pHCGraphic ); + mpImp->mnGraphicVersion++; } else if ( !mpImp->pGraphic ) + { mpImp->pGraphic = new Graphic; + mpImp->mnGraphicVersion++; + } else { DBG_ERROR("No update, but replacement exists already!"); @@ -469,6 +478,7 @@ void EmbeddedObjectRef::GetReplacement( BOOL bUpdate ) GraphicFilter* pGF = GraphicFilter::GetGraphicFilter(); if( mpImp->pGraphic ) pGF->ImportGraphic( *mpImp->pGraphic, String(), *pGraphicStream, GRFILTER_FORMAT_DONTKNOW ); + mpImp->mnGraphicVersion++; delete pGraphicStream; } } @@ -598,6 +608,7 @@ Graphic* EmbeddedObjectRef::GetHCGraphic() const mpImp->pHCGraphic = pGraphic; else delete pGraphic; + mpImp->mnGraphicVersion++; } delete pStream; @@ -615,7 +626,9 @@ void EmbeddedObjectRef::SetGraphicStream( const uno::Reference< io::XInputStream delete mpImp->pGraphic; mpImp->pGraphic = new Graphic(); mpImp->aMediaType = rMediaType; - if ( mpImp->pHCGraphic ) DELETEZ( mpImp->pHCGraphic ); + if ( mpImp->pHCGraphic ) + DELETEZ( mpImp->pHCGraphic ); + mpImp->mnGraphicVersion++; SvStream* pGraphicStream = ::utl::UcbStreamHelper::CreateStream( xInGrStream ); @@ -623,6 +636,7 @@ void EmbeddedObjectRef::SetGraphicStream( const uno::Reference< io::XInputStream { GraphicFilter* pGF = GraphicFilter::GetGraphicFilter(); pGF->ImportGraphic( *mpImp->pGraphic, String(), *pGraphicStream, GRFILTER_FORMAT_DONTKNOW ); + mpImp->mnGraphicVersion++; if ( mpImp->pContainer ) { @@ -645,7 +659,9 @@ void EmbeddedObjectRef::SetGraphic( const Graphic& rGraphic, const ::rtl::OUStri delete mpImp->pGraphic; mpImp->pGraphic = new Graphic( rGraphic ); mpImp->aMediaType = rMediaType; - if ( mpImp->pHCGraphic ) DELETEZ( mpImp->pHCGraphic ); + if ( mpImp->pHCGraphic ) + DELETEZ( mpImp->pHCGraphic ); + mpImp->mnGraphicVersion++; if ( mpImp->pContainer ) SetGraphicToContainer( rGraphic, *mpImp->pContainer, mpImp->aPersistName, rMediaType ); @@ -880,7 +896,9 @@ void EmbeddedObjectRef::UpdateReplacementOnDemand() { DELETEZ( mpImp->pGraphic ); mpImp->bNeedUpdate = sal_True; - if ( mpImp->pHCGraphic ) DELETEZ( mpImp->pHCGraphic ); + if ( mpImp->pHCGraphic ) + DELETEZ( mpImp->pHCGraphic ); + mpImp->mnGraphicVersion++; if( mpImp->pContainer ) { @@ -914,6 +932,12 @@ BOOL EmbeddedObjectRef::IsChart() const return sal_False; } +// #i104867# +sal_uInt32 EmbeddedObjectRef::getGraphicVersion() const +{ + return mpImp->mnGraphicVersion; +} + void EmbeddedObjectRef::SetDefaultSizeForChart( const Size& rSizeIn_100TH_MM ) { //#i103460# charts do not necessaryly have an own size within ODF files, @@ -928,4 +952,5 @@ void EmbeddedObjectRef::SetDefaultSizeForChart( const Size& rSizeIn_100TH_MM ) xSizeTransmitter->setDefaultSize( mpImp->aDefaultSizeForChart_In_100TH_MM ); } -} +} // namespace svt + -- cgit