diff options
author | Rüdiger Timm <rt@openoffice.org> | 2007-07-03 13:05:24 +0000 |
---|---|---|
committer | Rüdiger Timm <rt@openoffice.org> | 2007-07-03 13:05:24 +0000 |
commit | b7d50285483a41d6f73bb736aae765a31c5a42a9 (patch) | |
tree | 30869fa8dce6aa0e5eb64c494dc6566b585a46e2 /vcl/source/gdi/image.cxx | |
parent | 0319846d66200567b0f7edf05c66b1920f7eb1d9 (diff) |
INTEGRATION: CWS vcl79 (1.27.24); FILE MERGED
2007/06/24 17:37:32 pl 1.27.24.5: RESYNC: (1.29-1.30); FILE MERGED
2007/06/19 11:27:29 pl 1.27.24.4: #i78378# fix another crash
2007/06/18 17:44:18 pl 1.27.24.3: #i78378# fix wrong assertion
2007/06/18 15:23:48 pl 1.27.24.2: RESYNC: (1.27-1.29); FILE MERGED
2007/06/18 13:00:04 pl 1.27.24.1: #i78378# do not return empty names
Diffstat (limited to 'vcl/source/gdi/image.cxx')
-rw-r--r-- | vcl/source/gdi/image.cxx | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/vcl/source/gdi/image.cxx b/vcl/source/gdi/image.cxx index 0594e8a59c27..e3be711d5d5c 100644 --- a/vcl/source/gdi/image.cxx +++ b/vcl/source/gdi/image.cxx @@ -1,13 +1,12 @@ -#include <stdio.h> /************************************************************************* * * OpenOffice.org - a multi-platform office productivity suite * * $RCSfile: image.cxx,v $ * - * $Revision: 1.31 $ + * $Revision: 1.32 $ * - * last change: $Author: hr $ $Date: 2007-06-27 20:14:13 $ + * last change: $Author: rt $ $Date: 2007-07-03 14:05:24 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -575,7 +574,7 @@ void ImageAryData::Load(const rtl::OUString &rPrefix) rtl::OUString aFileName = rPrefix; aFileName += maName; -#ifdef DEBUG +#ifdef DBG_UTIL bool bSuccess = aImageTree->loadImage( aFileName, aSymbolsStyle, maBitmapEx, true ); DBG_ASSERT (bSuccess, "ImageAryData::Failed to load image"); #else @@ -668,11 +667,14 @@ void ImageList::InsertFromHorizontalBitmap( const ResId& rResId, const Color *pReplaceColors, ULONG nColorCount) { -// fprintf (stderr, "InsertFromHorizontalBitmap\n"); - BitmapEx aBmpEx( rResId ); - if ( !aBmpEx.IsTransparent() && pMaskColor ) - aBmpEx = BitmapEx( aBmpEx.GetBitmap(), *pMaskColor ); + if (!aBmpEx.IsTransparent()) + { + if( pMaskColor ) + aBmpEx = BitmapEx( aBmpEx.GetBitmap(), *pMaskColor ); + else + aBmpEx = BitmapEx( aBmpEx.GetBitmap() ); + } if ( nColorCount && pSearchColors && pReplaceColors ) aBmpEx.Replace( pSearchColors, pReplaceColors, nColorCount ); @@ -967,7 +969,11 @@ void ImageList::GetImageNames( ::std::vector< ::rtl::OUString >& rNames ) const if( mpImplData ) { for( sal_uInt32 i = 0; i < mpImplData->maImages.size(); i++ ) - rNames.push_back( mpImplData->maImages[ i ]->maName ); + { + const rtl::OUString& rName( mpImplData->maImages[ i ]->maName ); + if( rName.getLength() != 0 ) + rNames.push_back( rName ); + } } } |