diff options
author | Kurt Zenker <kz@openoffice.org> | 2006-12-12 17:12:59 +0000 |
---|---|---|
committer | Kurt Zenker <kz@openoffice.org> | 2006-12-12 17:12:59 +0000 |
commit | 74791d91a0b3edfaa4f9129d862ab2bec43bde40 (patch) | |
tree | a61438fed8664ac0c7ebdd0939b24903c24d5497 /sd/source/ui/slidesorter/cache/SlsBitmapCompressor.cxx | |
parent | a2bb6e38ceb8bfcbefdde40b0f9efc23b449c13f (diff) |
INTEGRATION: CWS sdwarningsbegone (1.4.38); FILE MERGED
2006/11/27 16:30:59 cl 1.4.38.3: #i69285# warning free code changes for sd project
2006/11/27 15:15:02 cl 1.4.38.2: #i69285# warning free code changes for sd project
2006/11/22 12:42:10 cl 1.4.38.1: #i69285# warning free code changes for unxlngi6.pro
Diffstat (limited to 'sd/source/ui/slidesorter/cache/SlsBitmapCompressor.cxx')
-rw-r--r-- | sd/source/ui/slidesorter/cache/SlsBitmapCompressor.cxx | 52 |
1 files changed, 30 insertions, 22 deletions
diff --git a/sd/source/ui/slidesorter/cache/SlsBitmapCompressor.cxx b/sd/source/ui/slidesorter/cache/SlsBitmapCompressor.cxx index 7d1596515cd3..7a573e504b0f 100644 --- a/sd/source/ui/slidesorter/cache/SlsBitmapCompressor.cxx +++ b/sd/source/ui/slidesorter/cache/SlsBitmapCompressor.cxx @@ -2,9 +2,9 @@ * * $RCSfile: SlsBitmapCompressor.cxx,v $ * - * $Revision: 1.4 $ + * $Revision: 1.5 $ * - * last change: $Author: obo $ $Date: 2006-09-16 19:03:35 $ + * last change: $Author: kz $ $Date: 2006-12-12 18:12:59 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -59,14 +59,20 @@ public: DummyReplacement (const ::boost::shared_ptr<BitmapEx>& rpPreview) : mpPreview(rpPreview) { } - virtual sal_Int32 GetMemorySize (void) const - { - return mpPreview->GetSizeBytes(); - } -}; + virtual ~DummyReplacement(); + virtual sal_Int32 GetMemorySize (void) const; +}; +NoBitmapCompression::DummyReplacement::~DummyReplacement() +{ +} + +sal_Int32 NoBitmapCompression::DummyReplacement::GetMemorySize (void) const +{ + return mpPreview->GetSizeBytes(); +} ::boost::shared_ptr<BitmapReplacement> NoBitmapCompression::Compress ( const ::boost::shared_ptr<BitmapEx>& rpBitmap) const @@ -74,9 +80,6 @@ public: return ::boost::shared_ptr<BitmapReplacement>(new DummyReplacement(rpBitmap)); } - - - ::boost::shared_ptr<BitmapEx> NoBitmapCompression::Decompress ( const BitmapReplacement& rBitmapData) const { @@ -97,7 +100,7 @@ bool NoBitmapCompression::IsLossless (void) const //===== CompressionByDeletion ================================================= ::boost::shared_ptr<BitmapReplacement> CompressionByDeletion::Compress ( - const ::boost::shared_ptr<BitmapEx>& rpBitmap) const + const ::boost::shared_ptr<BitmapEx>& ) const { return ::boost::shared_ptr<BitmapReplacement>(); } @@ -106,7 +109,7 @@ bool NoBitmapCompression::IsLossless (void) const ::boost::shared_ptr<BitmapEx> CompressionByDeletion::Decompress ( - const BitmapReplacement& rBitmapData) const + const BitmapReplacement& ) const { // Return a NULL pointer. This will eventually lead to a request for // the creation of a new one. @@ -134,17 +137,22 @@ public: ::boost::shared_ptr<BitmapEx> mpPreview; Size maOriginalSize; - virtual sal_Int32 GetMemorySize (void) const - { - if (mpPreview.get() != NULL) - return mpPreview->GetSizeBytes(); - else - return 0; - } -}; + virtual ~ResolutionReducedReplacement(); + virtual sal_Int32 GetMemorySize (void) const; +}; +ResolutionReduction::ResolutionReducedReplacement::~ResolutionReducedReplacement() +{ +} +sal_Int32 ResolutionReduction::ResolutionReducedReplacement::GetMemorySize (void) const +{ + if (mpPreview.get() != NULL) + return mpPreview->GetSizeBytes(); + else + return 0; +} ::boost::shared_ptr<BitmapReplacement> ResolutionReduction::Compress ( const ::boost::shared_ptr<BitmapEx>& rpBitmap) const @@ -210,7 +218,7 @@ public: {} virtual ~PngReplacement (void) { - delete [] mpData; + delete [] (char*)mpData; } virtual sal_Int32 GetMemorySize (void) const { @@ -252,7 +260,7 @@ public: pResult = new BitmapEx(aReader.Read()); } - sal_Int32 nRatio ((100L * (ULONG)pResult->GetSizeBytes()) / (ULONG)pData->mnDataSize); +// sal_Int32 nRatio ((100L * (ULONG)pResult->GetSizeBytes()) / (ULONG)pData->mnDataSize); return ::boost::shared_ptr<BitmapEx>(pResult); } |