[Libreoffice-commits] core.git: filter/CppunitTest_filter_pict_test.mk filter/source
Stephan Bergmann
sbergman at redhat.com
Tue Jun 10 22:46:39 PDT 2014
filter/CppunitTest_filter_pict_test.mk | 6 +++++-
filter/source/graphicfilter/ipict/ipict.cxx | 23 +++++++++++------------
filter/source/graphicfilter/ipict/ipict.hxx | 8 +-------
3 files changed, 17 insertions(+), 20 deletions(-)
New commits:
commit 7b72e5051437d7ecfdb3658375b3cb09b1b4abf8
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Wed Jun 11 07:46:03 2014 +0200
Access code under test via gb_Library_use_library_objects
Change-Id: Ib92dc55827b69cf33a04fe4084cf296049efc9c6
diff --git a/filter/CppunitTest_filter_pict_test.mk b/filter/CppunitTest_filter_pict_test.mk
index 1e4e0be..6722712 100644
--- a/filter/CppunitTest_filter_pict_test.mk
+++ b/filter/CppunitTest_filter_pict_test.mk
@@ -18,7 +18,7 @@ $(eval $(call gb_CppunitTest_add_exception_objects,filter_pict_test, \
))
$(eval $(call gb_CppunitTest_use_libraries,filter_pict_test, \
- ipt \
+ basegfx \
sal \
test \
tl \
@@ -27,6 +27,10 @@ $(eval $(call gb_CppunitTest_use_libraries,filter_pict_test, \
$(gb_UWINAPI) \
))
+$(eval $(call gb_CppunitTest_use_library_objects,filter_pict_test, \
+ ipt \
+))
+
$(eval $(call gb_CppunitTest_use_api,filter_pict_test,\
udkapi \
offapi \
diff --git a/filter/source/graphicfilter/ipict/ipict.cxx b/filter/source/graphicfilter/ipict/ipict.cxx
index c0f1955..4566288 100644
--- a/filter/source/graphicfilter/ipict/ipict.cxx
+++ b/filter/source/graphicfilter/ipict/ipict.cxx
@@ -1913,6 +1913,16 @@ void PictReader::ReadPict( SvStream & rStreamPict, GDIMetaFile & rGDIMetaFile )
if (pPict->GetError()) pPict->Seek(nOrigPos);
}
+namespace pict {
+
+void ReadPictFile(SvStream &rStreamPict, GDIMetaFile& rGDIMetaFile)
+{
+ PictReader aPictReader;
+ aPictReader.ReadPict(rStreamPict, rGDIMetaFile);
+}
+
+}
+
//================== GraphicImport - the exported function ================
// this needs to be kept in sync with
@@ -1926,10 +1936,9 @@ extern "C" SAL_DLLPUBLIC_EXPORT bool SAL_CALL
GraphicImport( SvStream& rIStm, Graphic & rGraphic, FilterConfigItem* )
{
GDIMetaFile aMTF;
- PictReader aPictReader;
bool bRet = false;
- aPictReader.ReadPict( rIStm, aMTF );
+ pict::ReadPictFile( rIStm, aMTF );
if ( !rIStm.GetError() )
{
@@ -1940,14 +1949,4 @@ GraphicImport( SvStream& rIStm, Graphic & rGraphic, FilterConfigItem* )
return bRet;
}
-namespace pict {
-
-void ReadPictFile(SvStream &rStreamPict, GDIMetaFile& rGDIMetaFile)
-{
- PictReader aPictReader;
- aPictReader.ReadPict(rStreamPict, rGDIMetaFile);
-}
-
-}
-
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/filter/source/graphicfilter/ipict/ipict.hxx b/filter/source/graphicfilter/ipict/ipict.hxx
index a7ca2bf..5b2de27 100644
--- a/filter/source/graphicfilter/ipict/ipict.hxx
+++ b/filter/source/graphicfilter/ipict/ipict.hxx
@@ -13,19 +13,13 @@
#include <sal/config.h>
#include <sal/types.h>
-#if defined PCT_DLLIMPLEMENTATION
-#define PCT_DLLPUBLIC SAL_DLLPUBLIC_EXPORT
-#else
-#define PCT_DLLPUBLIC SAL_DLLPUBLIC_IMPORT
-#endif
-
class GDIMetaFile;
class SvStream;
namespace pict {
/// Function to access PictReader::ReadPict for unit testing.
-PCT_DLLPUBLIC void ReadPictFile(SvStream &rStreamPict, GDIMetaFile& rGDIMetaFile);
+void ReadPictFile(SvStream &rStreamPict, GDIMetaFile& rGDIMetaFile);
}
More information about the Libreoffice-commits
mailing list