diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2014-12-14 22:18:11 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2014-12-14 22:33:16 +0100 |
commit | 68b8f008c8893b6b7d2314c21679bf2dbcd1b4e5 (patch) | |
tree | a11dac23e400e99b8fb3746d2dce7ad1feaab402 /svl | |
parent | a818cda870ecf0e2a13949c29063812ecbbdc6b7 (diff) |
Factor out SfxUInt16Item::dumpAsXml() from sw
Change-Id: Ia58bed9c4a0be4b909789e8bdcd64f06230c0f43
Diffstat (limited to 'svl')
-rw-r--r-- | svl/Library_svl.mk | 1 | ||||
-rw-r--r-- | svl/source/items/intitem.cxx | 8 |
2 files changed, 9 insertions, 0 deletions
diff --git a/svl/Library_svl.mk b/svl/Library_svl.mk index 36413857965b..075415776025 100644 --- a/svl/Library_svl.mk +++ b/svl/Library_svl.mk @@ -22,6 +22,7 @@ $(eval $(call gb_Library_Library,svl)) $(eval $(call gb_Library_use_externals,svl,\ boost_headers \ mdds_headers \ + libxml2 \ )) $(eval $(call gb_Library_set_componentfile,svl,svl/util/svl)) diff --git a/svl/source/items/intitem.cxx b/svl/source/items/intitem.cxx index f71c72e4bf9b..a9405d7daf5a 100644 --- a/svl/source/items/intitem.cxx +++ b/svl/source/items/intitem.cxx @@ -24,6 +24,7 @@ #include <tools/bigint.hxx> #include <tools/stream.hxx> #include <svl/metitem.hxx> +#include <libxml/xmlwriter.h> // class SfxByteItem @@ -141,6 +142,13 @@ SfxFieldUnit SfxInt16Item::GetUnit() const TYPEINIT1_AUTOFACTORY(SfxUInt16Item, CntUInt16Item); +void SfxUInt16Item::dumpAsXml(xmlTextWriterPtr pWriter) const +{ + xmlTextWriterStartElement(pWriter, BAD_CAST("sfxUInt16Item")); + xmlTextWriterWriteAttribute(pWriter, BAD_CAST("whichId"), BAD_CAST(OString::number(Which()).getStr())); + xmlTextWriterWriteAttribute(pWriter, BAD_CAST("value"), BAD_CAST(OString::number(GetValue()).getStr())); + xmlTextWriterEndElement(pWriter); +} // class SfxInt32Item |