[Libreoffice-commits] core.git: include/vcl vcl/source
panoskorovesis (via logerrit)
logerrit at kemper.freedesktop.org
Tue Aug 3 22:54:50 UTC 2021
include/vcl/filter/SvmWriter.hxx | 1 +
vcl/source/filter/svm/SvmWriter.cxx | 14 ++++++++++++++
2 files changed, 15 insertions(+)
New commits:
commit ca6e32efb563490a2c18599ee483c796fc5b159a
Author: panoskorovesis <panoskorovesis at outlook.com>
AuthorDate: Tue Aug 3 09:59:59 2021 +0300
Commit: Tomaž Vajngerl <quikee at gmail.com>
CommitDate: Wed Aug 4 00:54:13 2021 +0200
Add Handler for Push Write
The handler separates MetaPushAction::Write from metaact.hxx
Write implementation is now in SvmWriter.hxx
Change-Id: I60d3b618ccb14e82b195c84271921189fe41b904
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119924
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee at gmail.com>
diff --git a/include/vcl/filter/SvmWriter.hxx b/include/vcl/filter/SvmWriter.hxx
index f437ee7eff46..044d7981b776 100644
--- a/include/vcl/filter/SvmWriter.hxx
+++ b/include/vcl/filter/SvmWriter.hxx
@@ -60,4 +60,5 @@ public:
void TextAlignHandler(MetaTextAlignAction* pAction);
void MapModeHandler(MetaMapModeAction* pAction);
void FontHandler(MetaFontAction* pAction, ImplMetaWriteData* pData);
+ void PushHandler(MetaPushAction* pAction);
};
\ No newline at end of file
diff --git a/vcl/source/filter/svm/SvmWriter.cxx b/vcl/source/filter/svm/SvmWriter.cxx
index 96509316d1c5..f37a945d9c4c 100644
--- a/vcl/source/filter/svm/SvmWriter.cxx
+++ b/vcl/source/filter/svm/SvmWriter.cxx
@@ -227,6 +227,13 @@ void SvmWriter::MetaActionHandler(MetaAction* pAction, ImplMetaWriteData* pData)
}
break;
+ case MetaActionType::PUSH:
+ {
+ auto* pMetaAction = static_cast<MetaPushAction*>(pAction);
+ PushHandler(pMetaAction);
+ }
+ break;
+
/* default case prevents test failure and will be
removed once all the handlers are completed */
default:
@@ -511,4 +518,11 @@ void SvmWriter::FontHandler(MetaFontAction* pAction, ImplMetaWriteData* pData)
if (pData->meActualCharSet == RTL_TEXTENCODING_DONTKNOW)
pData->meActualCharSet = osl_getThreadTextEncoding();
}
+
+void SvmWriter::PushHandler(MetaPushAction* pAction)
+{
+ mrStream.WriteUInt16(static_cast<sal_uInt16>(pAction->GetType()));
+ VersionCompatWrite aCompat(mrStream, 1);
+ mrStream.WriteUInt16(static_cast<sal_uInt16>(pAction->GetFlags()));
+}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
More information about the Libreoffice-commits
mailing list