diff options
author | Armin Le Grand <alg@apache.org> | 2013-01-10 16:28:40 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2013-06-13 14:50:46 +0100 |
commit | e0cce521f1ad0cc384d30ce2f1077ea229fffe62 (patch) | |
tree | ae40b74bceb4b036d87b79e861f5eef76ec41102 /svx/source | |
parent | 6ed3ef87d2472bad71b719e9ec927e72acfd2850 (diff) |
Resolves: #i121504# Support for alpha channel in clipboard for all systems
(cherry picked from commit ef3931ff410117e1237b3bef7bc090e8b83b9519)
Conflicts:
automation/source/server/statemnt.cxx
basic/source/runtime/methods.cxx
canvas/source/vcl/devicehelper.cxx
canvas/source/vcl/spritedevicehelper.cxx
drawinglayer/source/processor2d/vclhelperbufferdevice.cxx
drawinglayer/source/processor2d/vclmetafileprocessor2d.cxx
drawinglayer/source/tools/converters.cxx
dtrans/source/win32/dtobj/FmtFilter.cxx
editeng/source/items/bulitem.cxx
extensions/source/scanner/sanedlg.cxx
external/gcc3_specific/makefile.mk
filter/source/graphicfilter/eos2met/eos2met.cxx
filter/source/graphicfilter/ios2met/ios2met.cxx
filter/source/msfilter/msdffimp.cxx
fpicker/source/office/iodlg.cxx
framework/source/fwe/classes/addonsoptions.cxx
framework/source/fwe/helper/actiontriggerhelper.cxx
sc/source/filter/excel/xiescher.cxx
sc/source/ui/docshell/docsh.cxx
sc/source/ui/inc/viewfunc.hxx
sd/source/ui/app/sdxfer.cxx
sd/source/ui/unoidl/unopage.cxx
sd/source/ui/view/sdview3.cxx
sfx2/source/appl/fileobj.cxx
sfx2/source/appl/linkmgr2.cxx
sfx2/source/dialog/filedlghelper.cxx
sfx2/source/dialog/intro.cxx
sfx2/source/doc/docinf.cxx
sot/inc/sot/formats.hxx
sot/source/base/formats.cxx
svtools/bmpmaker/bmpcore.cxx
svtools/bmpmaker/bmpsum.cxx
svtools/inc/svtools/transfer.hxx
svtools/source/filter/filter.cxx
svtools/source/filter/wmf/emfwr.cxx
svtools/source/filter/wmf/enhwmf.cxx
svtools/source/filter/wmf/winwmf.cxx
svtools/source/filter/wmf/wmfwr.cxx
svtools/source/graphic/graphic.cxx
svtools/source/graphic/provider.cxx
svtools/source/misc/transfer.cxx
svx/inc/svx/xoutbmp.hxx
svx/source/sdr/overlay/overlaymanagerbuffered.cxx
svx/source/xoutdev/_xoutbmp.cxx
sw/source/core/view/viewsh.cxx
sw/source/filter/ww1/w1filter.cxx
sw/source/filter/ww8/ww8par.hxx
sw/source/ui/dochdl/swdtflvr.cxx
toolkit/source/awt/vclxbitmap.cxx
toolkit/source/helper/vclunohelper.cxx
vcl/Library_vcl.mk
vcl/Package_inc.mk
vcl/aqua/source/dtrans/DataFlavorMapping.cxx
vcl/aqua/source/dtrans/OSXTransferable.cxx
vcl/aqua/source/dtrans/PictToBmpFlt.cxx
vcl/aqua/source/dtrans/PictToBmpFlt.hxx
vcl/inc/vcl/alpha.hxx
vcl/inc/vcl/bitmap.hxx
vcl/inc/vcl/bitmapex.hxx
vcl/inc/vcl/pngwrite.hxx
vcl/inc/vcl/salbtype.hxx
vcl/inc/vcl/wall.hxx
vcl/source/gdi/animate.cxx
vcl/source/gdi/bitmap2.cxx
vcl/source/gdi/bitmapex.cxx
vcl/source/gdi/bmpconv.cxx
vcl/source/gdi/cvtsvm.cxx
vcl/source/gdi/impgraph.cxx
vcl/source/gdi/impimagetree.cxx
vcl/source/gdi/metaact.cxx
vcl/source/gdi/wall.cxx
Change-Id: I79938bc412c048c3d4e64f430f216e73bec16167
Diffstat (limited to 'svx/source')
-rw-r--r-- | svx/source/gallery2/galmisc.cxx | 2 | ||||
-rw-r--r-- | svx/source/gallery2/galobj.cxx | 12 | ||||
-rw-r--r-- | svx/source/sdr/overlay/overlaymanagerbuffered.cxx | 1 | ||||
-rw-r--r-- | svx/source/xoutdev/_xoutbmp.cxx | 6 | ||||
-rw-r--r-- | svx/source/xoutdev/xattrbmp.cxx | 9 |
5 files changed, 17 insertions, 13 deletions
diff --git a/svx/source/gallery2/galmisc.cxx b/svx/source/gallery2/galmisc.cxx index 499ab340d238..06c8d158af6c 100644 --- a/svx/source/gallery2/galmisc.cxx +++ b/svx/source/gallery2/galmisc.cxx @@ -590,7 +590,7 @@ sal_Bool GalleryTransferable::GetData( const datatransfer::DataFlavor& rFlavor ) } else if( ( FORMAT_BITMAP == nFormat ) && mpGraphicObject ) { - bRet = SetBitmap( mpGraphicObject->GetGraphic().GetBitmap(), rFlavor ); + bRet = SetBitmapEx( mpGraphicObject->GetGraphic().GetBitmapEx(), rFlavor ); } return bRet; diff --git a/svx/source/gallery2/galobj.cxx b/svx/source/gallery2/galobj.cxx index 573dcf6875cb..eb1b6e4e701d 100644 --- a/svx/source/gallery2/galobj.cxx +++ b/svx/source/gallery2/galobj.cxx @@ -21,11 +21,9 @@ #include <com/sun/star/lang/XUnoTunnel.hpp> #include <sfx2/objsh.hxx> #include <sfx2/docfac.hxx> - #include <comphelper/classids.hxx> #include <comphelper/string.hxx> #include <unotools/pathoptions.hxx> - #include <tools/rcid.h> #include <tools/vcompat.hxx> #include <tools/helpers.hxx> @@ -38,7 +36,7 @@ #include "svx/galmisc.hxx" #include "galobj.hxx" #include <vcl/svapp.hxx> - +#include <vcl/dibtools.hxx> #include "gallerydrawmodel.hxx" using namespace ::com::sun::star; @@ -150,7 +148,7 @@ void SgaObject::WriteData( SvStream& rOut, const String& rDestDir ) const rOut.SetCompressMode( COMPRESSMODE_ZBITMAP ); rOut.SetVersion( SOFFICE_FILEFORMAT_50 ); - rOut << aThumbBmp; + WriteDIBBitmapEx(aThumbBmp, rOut); rOut.SetVersion( nOldVersion ); rOut.SetCompressMode( nOldCompressMode ); @@ -173,9 +171,13 @@ void SgaObject::ReadData(SvStream& rIn, sal_uInt16& rReadVersion ) rIn >> nTmp32 >> nTmp16 >> rReadVersion >> nTmp16 >> bIsThumbBmp; if( bIsThumbBmp ) - rIn >> aThumbBmp; + { + ReadDIBBitmapEx(aThumbBmp, rIn); + } else + { rIn >> aThumbMtf; + } OUString aTmpStr = read_lenPrefixed_uInt8s_ToOUString<sal_uInt16>(rIn, RTL_TEXTENCODING_UTF8); aURL = INetURLObject(aTmpStr); diff --git a/svx/source/sdr/overlay/overlaymanagerbuffered.cxx b/svx/source/sdr/overlay/overlaymanagerbuffered.cxx index 47d76f835d00..d502094d55fb 100644 --- a/svx/source/sdr/overlay/overlaymanagerbuffered.cxx +++ b/svx/source/sdr/overlay/overlaymanagerbuffered.cxx @@ -26,6 +26,7 @@ #include <tools/stream.hxx> #include <basegfx/matrix/b2dhommatrix.hxx> #include <vcl/cursor.hxx> +#include <vcl/dibtools.hxx> ////////////////////////////////////////////////////////////////////////////// diff --git a/svx/source/xoutdev/_xoutbmp.cxx b/svx/source/xoutdev/_xoutbmp.cxx index 33e36ee0fd10..535d6b3299dc 100644 --- a/svx/source/xoutdev/_xoutbmp.cxx +++ b/svx/source/xoutdev/_xoutbmp.cxx @@ -17,7 +17,6 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ - #include <sot/factory.hxx> #include <tools/poly.hxx> #include <vcl/bmpacc.hxx> @@ -27,6 +26,7 @@ #include <sfx2/docfile.hxx> #include <sfx2/app.hxx> #include "svx/xoutbmp.hxx" +#include <vcl/dibtools.hxx> #include <vcl/FilterConfigItem.hxx> #include <vcl/graphicfilter.hxx> @@ -363,8 +363,8 @@ Bitmap XOutBitmap::DetectEdges( const Bitmap& rBmp, const sal_uInt8 cThreshold ) const long nHeight = aSize.Height(); const long nHeight2 = nHeight - 2L; const long lThres2 = (long) cThreshold * cThreshold; - const sal_uInt8 nWhitePalIdx = pWriteAcc->GetBestPaletteIndex( Color( COL_WHITE ) ); - const sal_uInt8 nBlackPalIdx = pWriteAcc->GetBestPaletteIndex( Color( COL_BLACK ) ); + const sal_uInt8 nWhitePalIdx(static_cast< sal_uInt8 >(pWriteAcc->GetBestPaletteIndex(Color(COL_WHITE)))); + const sal_uInt8 nBlackPalIdx(static_cast< sal_uInt8 >(pWriteAcc->GetBestPaletteIndex(Color(COL_BLACK)))); long nSum1; long nSum2; long lGray; diff --git a/svx/source/xoutdev/xattrbmp.cxx b/svx/source/xoutdev/xattrbmp.cxx index 85255918e682..462bae6b5036 100644 --- a/svx/source/xoutdev/xattrbmp.cxx +++ b/svx/source/xoutdev/xattrbmp.cxx @@ -38,6 +38,7 @@ #include <com/sun/star/beans/PropertyValue.hpp> #include <vcl/salbtype.hxx> #include <vcl/bmpacc.hxx> +#include <vcl/dibtools.hxx> using namespace ::com::sun::star; @@ -357,7 +358,7 @@ XFillBitmapItem::XFillBitmapItem(SvStream& rIn, sal_uInt16 nVer) // Behandlung der alten Bitmaps Bitmap aBmp; - rIn >> aBmp; + ReadDIB(aBmp, rIn, true); maGraphicObject = Graphic(aBmp); } else if(1 == nVer) @@ -371,7 +372,7 @@ XFillBitmapItem::XFillBitmapItem(SvStream& rIn, sal_uInt16 nVer) { Bitmap aBmp; - rIn >> aBmp; + ReadDIB(aBmp, rIn, true); maGraphicObject = Graphic(aBmp); } else if(XBITMAP_8X8 == iTmp) @@ -398,7 +399,7 @@ XFillBitmapItem::XFillBitmapItem(SvStream& rIn, sal_uInt16 nVer) { BitmapEx aBmpEx; - rIn >> aBmpEx; + ReadDIBBitmapEx(aBmpEx, rIn); maGraphicObject = Graphic(aBmpEx); } } @@ -442,7 +443,7 @@ SvStream& XFillBitmapItem::Store( SvStream& rOut, sal_uInt16 nItemVersion ) cons if(!IsIndex()) { - rOut << maGraphicObject.GetGraphic().GetBitmapEx(); + WriteDIBBitmapEx(maGraphicObject.GetGraphic().GetBitmapEx(), rOut); } return rOut; |