summaryrefslogtreecommitdiff
path: root/svtools
diff options
context:
space:
mode:
authorJens-Heiner Rechtien <hr@openoffice.org>2003-04-04 17:19:06 +0000
committerJens-Heiner Rechtien <hr@openoffice.org>2003-04-04 17:19:06 +0000
commit73380fbf799bf4dad5c730f2472fd479448f3b49 (patch)
treea5a237cb3660c92a5d44684ffbf78609bb68fc48 /svtools
parent39bcfcd9cbf7b98e270ae6337e3ea0ac1438f283 (diff)
INTEGRATION: CWS os7 (1.29.2.2.32); FILE MERGED
2003/03/20 13:47:58 pb 1.29.2.2.32.1: fix: #108329# initialize the width vector if necessary
Diffstat (limited to 'svtools')
-rw-r--r--svtools/source/contnr/svimpbox.cxx13
1 files changed, 10 insertions, 3 deletions
diff --git a/svtools/source/contnr/svimpbox.cxx b/svtools/source/contnr/svimpbox.cxx
index afcfa603edc9..551ec3f32e99 100644
--- a/svtools/source/contnr/svimpbox.cxx
+++ b/svtools/source/contnr/svimpbox.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: svimpbox.cxx,v $
*
- * $Revision: 1.30 $
+ * $Revision: 1.31 $
*
- * last change: $Author: hr $ $Date: 2003-03-27 14:37:38 $
+ * last change: $Author: hr $ $Date: 2003-04-04 18:19:06 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -207,7 +207,14 @@ short SvImpLBox::UpdateContextBmpWidthVector( SvLBoxEntry* pEntry, short nWidth
DBG_ASSERT( pView->pModel, "View and Model aren't valid!" );
USHORT nDepth = pView->pModel->GetDepth( pEntry );
- DBG_ASSERT( aContextBmpWidthVector.size() >= nDepth, "Some level missing!" );
+ // initialize vector if necessary
+ USHORT nSize = aContextBmpWidthVector.size();
+ while ( nDepth > nSize )
+ {
+ aContextBmpWidthVector.resize( nSize + 1 );
+ aContextBmpWidthVector.at( nSize ) = nWidth;
+ ++nSize;
+ }
if( aContextBmpWidthVector.size() == nDepth )
{
aContextBmpWidthVector.resize( nDepth + 1 );