diff options
author | panoskorovesis <panoskorovesis@outlook.com> | 2021-08-05 10:20:49 +0300 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2021-08-12 02:23:33 +0200 |
commit | d7fc4cfb90d688ff2b5a774f60f87d8d120ddb1e (patch) | |
tree | bd2e32c33f1b66507edd0c9efe46fbf08b0559e3 | |
parent | 526646cb631bf56fc0fae25499a867399db81b02 (diff) |
Add Handler for ISectRegionClipRegion Write
The handler separates MetaISectRegionClipRegionAction::Write from metaact.hxx
Write implementation is now in SvmWriter.hxx
Change-Id: I734e574c9a292fd44f36c155ba976908512ee588
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120309
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
-rw-r--r-- | include/vcl/filter/SvmWriter.hxx | 1 | ||||
-rw-r--r-- | vcl/source/filter/svm/SvmWriter.cxx | 14 |
2 files changed, 15 insertions, 0 deletions
diff --git a/include/vcl/filter/SvmWriter.hxx b/include/vcl/filter/SvmWriter.hxx index 10d7658c3bb7..c89b93fb52e7 100644 --- a/include/vcl/filter/SvmWriter.hxx +++ b/include/vcl/filter/SvmWriter.hxx @@ -71,6 +71,7 @@ public: void WallpaperHandler(MetaWallpaperAction* pAction); void ClipRegionHandler(MetaClipRegionAction* pAction); void ISectRectClipRegionHandler(MetaISectRectClipRegionAction* pAction); + void ISectRegionClipRegionHandler(MetaISectRegionClipRegionAction* pAction); void OverlineColorHandler(MetaOverlineColorAction* pAction); void TextAlignHandler(MetaTextAlignAction* pAction); void MapModeHandler(MetaMapModeAction* pAction); diff --git a/vcl/source/filter/svm/SvmWriter.cxx b/vcl/source/filter/svm/SvmWriter.cxx index e5635e31a141..402d397dc21b 100644 --- a/vcl/source/filter/svm/SvmWriter.cxx +++ b/vcl/source/filter/svm/SvmWriter.cxx @@ -305,6 +305,13 @@ void SvmWriter::MetaActionHandler(MetaAction* pAction, ImplMetaWriteData* pData) } break; + case MetaActionType::ISECTREGIONCLIPREGION: + { + auto* pMetaAction = static_cast<MetaISectRegionClipRegionAction*>(pAction); + ISectRegionClipRegionHandler(pMetaAction); + } + break; + case MetaActionType::OVERLINECOLOR: { auto* pMetaAction = static_cast<MetaOverlineColorAction*>(pAction); @@ -836,6 +843,13 @@ void SvmWriter::ISectRectClipRegionHandler(MetaISectRectClipRegionAction* pActio aSerializer.writeRectangle(pAction->GetRect()); } +void SvmWriter::ISectRegionClipRegionHandler(MetaISectRegionClipRegionAction* pAction) +{ + mrStream.WriteUInt16(static_cast<sal_uInt16>(pAction->GetType())); + VersionCompatWrite aCompat(mrStream, 1); + WriteRegion(mrStream, pAction->GetRegion()); +} + void SvmWriter::OverlineColorHandler(MetaOverlineColorAction* pAction) { mrStream.WriteUInt16(static_cast<sal_uInt16>(pAction->GetType())); |