diff options
author | Chris Sherlock <chris.sherlock79@gmail.com> | 2014-03-15 02:08:55 +1100 |
---|---|---|
committer | Norbert Thiebaud <nthiebaud@gmail.com> | 2014-03-22 05:32:17 +0000 |
commit | 0eb7070e767fd395cf2c8fbb83707e2efda2bf01 (patch) | |
tree | d1616d6bc229aaf73ee073028b912e0b4469bc48 /include | |
parent | d4855da9e9718b31b371376ee8a469e9e26495af (diff) |
fdo#74702 DrawOutDev() and CopyArea() functions now noops in Printer
DrawOutDev() and CopyArea() functions now assert when called from a
Printer instance. This has allowed the removal of meOutDevType, which
I hope to eventually completely eradicate from LO.
I've also included DrawOutDev(...) which holds a parameter with a
reference to a Printer object. This shouldn't be possible, so it
asserts.
Change-Id: Iabee853ca7c8bfc99349da086d1944ee13210a2e
Reviewed-on: https://gerrit.libreoffice.org/8592
Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com>
Tested-by: Norbert Thiebaud <nthiebaud@gmail.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/vcl/outdev.hxx | 9 | ||||
-rw-r--r-- | include/vcl/print.hxx | 10 |
2 files changed, 16 insertions, 3 deletions
diff --git a/include/vcl/outdev.hxx b/include/vcl/outdev.hxx index 76f6011f3b59..e82cb1ddb94d 100644 --- a/include/vcl/outdev.hxx +++ b/include/vcl/outdev.hxx @@ -1028,12 +1028,15 @@ public: void DrawChord( const Rectangle& rRect, const Point& rStartPt, const Point& rEndPt ); - void DrawOutDev( const Point& rDestPt, const Size& rDestSize, + virtual void DrawOutDev( const Point& rDestPt, const Size& rDestSize, const Point& rSrcPt, const Size& rSrcSize ); - void DrawOutDev( const Point& rDestPt, const Size& rDestSize, + virtual void DrawOutDev( const Point& rDestPt, const Size& rDestSize, const Point& rSrcPt, const Size& rSrcSize, const OutputDevice& rOutDev ); - void CopyArea( const Point& rDestPt, + void DrawOutDev( const Point& rDestPt, const Size& rDestSize, + const Point& rSrcPt, const Size& rSrcSize, + const Printer& rOutDev ); + virtual void CopyArea( const Point& rDestPt, const Point& rSrcPt, const Size& rSrcSize, sal_uInt16 nFlags = 0 ); protected: diff --git a/include/vcl/print.hxx b/include/vcl/print.hxx index 287152171b43..93deb72e9726 100644 --- a/include/vcl/print.hxx +++ b/include/vcl/print.hxx @@ -393,6 +393,16 @@ public: virtual bool HasMirroredGraphics() const; + virtual void DrawOutDev( const Point& rDestPt, const Size& rDestSize, + const Point& rSrcPt, const Size& rSrcSize ); + virtual void DrawOutDev( const Point& rDestPt, const Size& rDestSize, + const Point& rSrcPt, const Size& rSrcSize, + const OutputDevice& rOutDev ); + virtual void CopyArea( const Point& rDestPt, + const Point& rSrcPt, const Size& rSrcSize, + sal_uInt16 nFlags = 0 ); + + // implementation detail of PrintJob being asynchronous // not exported, not usable outside vcl static void SAL_DLLPRIVATE ImplPrintJob( const boost::shared_ptr<vcl::PrinterController>& i_pController, |