File vcl-use-canvas-bool.diff of Package libreoffice-bootstrap
commit 7de8695f19626c764a4b43cfb30179525d9a5956
Author: Radek Doulik <rodo@novell.com>
Date: Wed Feb 9 16:02:42 2011 +0100
GDIMetaFile::bUseCanvas related changes (prerequisite for fixing n#650049)
- add GetUseCanvas() for read access
- update bUseCanvas when playing on metafile
commit bb6e3a77426bd8815760f6a46914dfc3568527cb
Author: Radek Doulik <rodo@novell.com>
Date: Tue Feb 15 17:19:24 2011 +0100
clean the code a bit
--- vcl/inc/vcl/gdimtf.hxx
+++ vcl/inc/vcl/gdimtf.hxx
@@ -247,6 +247,7 @@ public:
BOOL CreateThumbnail( sal_uInt32 nMaximumExtent, BitmapEx& rBmpEx, const BitmapEx* pOverlay = NULL, const Rectangle* pOverlayRect = NULL ) const;
void UseCanvas( BOOL _bUseCanvas );
+ BOOL GetUseCanvas() const { return bUseCanvas; }
};
/** Create a special metaaction that delegates rendering to specified
--- vcl/source/gdi/gdimtf.cxx
+++ vcl/source/gdi/gdimtf.cxx
@@ -437,6 +437,8 @@ void GDIMetaFile::Play( GDIMetaFile& rMtf, ULONG nPos )
MetaAction* pAction = GetCurAction();
const ULONG nObjCount = Count();
+ rMtf.UseCanvas( rMtf.GetUseCanvas() || bUseCanvas );
+
if( nPos > nObjCount )
nPos = nObjCount;