summaryrefslogtreecommitdiff
path: root/svx/source/svdraw/svditer.cxx
diff options
context:
space:
mode:
authorIvo Hinkelmann <ihi@openoffice.org>2009-02-16 13:39:47 +0000
committerIvo Hinkelmann <ihi@openoffice.org>2009-02-16 13:39:47 +0000
commit337a1ee590de50c923e38ee0a8e86f4213fcd14e (patch)
tree948a8253d36410085af909931dfd2b86026f4337 /svx/source/svdraw/svditer.cxx
parent043d3becc55c883c1a3d0d37f226aa4d7d44f7a6 (diff)
CWS-TOOLING: integrate CWS dr66_OOO310
2009-01-22 15:51:40 +0100 dr r266730 : #i98028# moved to CWS dr66 2009-01-22 15:50:28 +0100 dr r266729 : #i98028# moved to CWS dr66 2009-01-20 16:25:49 +0100 dr r266595 : #i98282# resolve palette colors while loading chart gradients (convert back to unx lineends...) 2009-01-20 16:23:19 +0100 dr r266594 : #i98282# resolve palette colors while loading chart gradients 2009-01-19 15:43:57 +0100 dr r266507 : #i97900# move fix to CWS dr66 2009-01-19 15:40:28 +0100 dr r266506 : #i97900# move fix to CWS dr66 2009-01-19 15:20:14 +0100 dr r266505 : #i98141# correctly update note position while switching LTR/RTL mode of sheet 2009-01-06 10:28:02 +0100 dr r265899 : CWS-TOOLING: rebase CWS dr66 to trunk@265758 (milestone: DEV300:m38) 2008-11-13 13:59:02 +0100 dr r263644 : #i10000# merge problems 2008-11-13 13:25:15 +0100 dr r263639 : #i10000# merge problems 2008-11-13 13:22:58 +0100 dr r263638 : #i10000# merge problems 2008-11-13 13:22:25 +0100 dr r263637 : #i10000# merge problems 2008-11-12 13:40:46 +0100 dr r263595 : #i10000# merge problem 2008-11-12 11:34:51 +0100 dr r263583 : CWS-TOOLING: rebase CWS dr66 to trunk@263288 (milestone: DEV300:m35) 2008-11-11 16:58:11 +0100 dr r263568 : CWS-TOOLING: rebase CWS dr66 to trunk@262087 (milestone: DEV300:m33) 2008-10-27 14:38:34 +0100 dr r262675 : migrate CWS dr66 to SVN
Diffstat (limited to 'svx/source/svdraw/svditer.cxx')
-rw-r--r--svx/source/svdraw/svditer.cxx59
1 files changed, 36 insertions, 23 deletions
diff --git a/svx/source/svdraw/svditer.cxx b/svx/source/svdraw/svditer.cxx
index 5207c529c6..d396876bfd 100644
--- a/svx/source/svdraw/svditer.cxx
+++ b/svx/source/svdraw/svditer.cxx
@@ -7,7 +7,7 @@
* OpenOffice.org - a multi-platform office productivity suite
*
* $RCSfile: svditer.cxx,v $
- * $Revision: 1.9 $
+ * $Revision: 1.9.246.1 $
*
* This file is part of OpenOffice.org.
*
@@ -34,6 +34,7 @@
#include <svx/svdpage.hxx>
#include <svx/svdogrp.hxx>
#include <svx/svdobj.hxx>
+#include <svx/svdmark.hxx>
// #99190#
#include <svx/scene3d.hxx>
@@ -68,33 +69,45 @@ SdrObjListIter::SdrObjListIter( const SdrObject& rObj, SdrIterMode eMode, BOOL b
Reset();
}
+SdrObjListIter::SdrObjListIter( const SdrMarkList& rMarkList, SdrIterMode eMode, BOOL bReverse )
+: maObjList(1024, 64, 64),
+ mnIndex(0L),
+ mbReverse(bReverse)
+{
+ ImpProcessMarkList(rMarkList, eMode);
+ Reset();
+}
+
void SdrObjListIter::ImpProcessObjectList(const SdrObjList& rObjList, SdrIterMode eMode, BOOL bUseZOrder)
{
- for(sal_uInt32 a(0L); a < rObjList.GetObjCount(); a++)
+ for( ULONG nIdx = 0, nCount = rObjList.GetObjCount(); nIdx < nCount; ++nIdx )
{
- SdrObject* pObj = NULL;
- if (bUseZOrder)
- pObj = rObjList.GetObj(a);
- else
- pObj = rObjList.GetObjectForNavigationPosition(a);
- if (pObj == NULL)
- {
- OSL_ASSERT(pObj!=NULL);
- continue;
- }
+ SdrObject* pObj = bUseZOrder ?
+ rObjList.GetObj( nIdx ) : rObjList.GetObjectForNavigationPosition( nIdx );
+ OSL_ASSERT( pObj != 0 );
+ if( pObj )
+ ImpProcessObj( pObj, eMode, bUseZOrder );
+ }
+}
- sal_Bool bIsGroup(pObj->IsGroupObject());
+void SdrObjListIter::ImpProcessMarkList( const SdrMarkList& rMarkList, SdrIterMode eMode )
+{
+ for( ULONG nIdx = 0, nCount = rMarkList.GetMarkCount(); nIdx < nCount; ++nIdx )
+ if( SdrObject* pObj = rMarkList.GetMark( nIdx )->GetMarkedSdrObj() )
+ ImpProcessObj( pObj, eMode, FALSE );
+}
- // #99190# 3D objects are no group objects, IsGroupObject()
- // only tests if pSub is not null ptr :-(
- if(bIsGroup && pObj->ISA(E3dObject) && !pObj->ISA(E3dScene))
- bIsGroup = sal_False;
+void SdrObjListIter::ImpProcessObj(SdrObject* pObj, SdrIterMode eMode, BOOL bUseZOrder)
+{
+ bool bIsGroup = pObj->IsGroupObject();
+ // #99190# 3D objects are no group objects, IsGroupObject()
+ // only tests if pSub is not null ptr :-(
+ if( bIsGroup && pObj->ISA( E3dObject ) && !pObj->ISA( E3dScene ) )
+ bIsGroup = false;
- if(eMode != IM_DEEPNOGROUPS || !bIsGroup)
- maObjList.Insert(pObj, LIST_APPEND);
+ if( !bIsGroup || (eMode != IM_DEEPNOGROUPS) )
+ maObjList.Insert( pObj, LIST_APPEND );
- if(bIsGroup && eMode != IM_FLAT)
- ImpProcessObjectList(*pObj->GetSubList(), eMode, bUseZOrder);
- }
+ if( bIsGroup && (eMode != IM_FLAT) )
+ ImpProcessObjectList( *pObj->GetSubList(), eMode, bUseZOrder );
}
-