summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorpanoskorovesis <panoskorovesis@outlook.com>2021-07-15 11:50:34 +0300
committerTomaž Vajngerl <quikee@gmail.com>2021-07-27 08:04:19 +0200
commit96294b206f02c9856dbcb8a21a0b20ce1180dd8c (patch)
tree2b4f185a8e35d233b367ea2546558fd6e1d5bcd4 /vcl
parentf8847233c5b935d7ad1ea82bd464868d2bc3f69e (diff)
Add Handler for RefPoint Read
The handler separates MetaRefPointAction::Read from metaact.hxx Read implementation is now in SvmReader.hxx Change-Id: I0de2cbefbb91a89e24b8c6e43fea80a7595baa5a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119193 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'vcl')
-rw-r--r--vcl/source/filter/svm/SvmReader.cxx20
1 files changed, 19 insertions, 1 deletions
diff --git a/vcl/source/filter/svm/SvmReader.cxx b/vcl/source/filter/svm/SvmReader.cxx
index 44c6705007b3..675bba95f7da 100644
--- a/vcl/source/filter/svm/SvmReader.cxx
+++ b/vcl/source/filter/svm/SvmReader.cxx
@@ -308,7 +308,7 @@ rtl::Reference<MetaAction> SvmReader::MetaActionHandler(ImplMetaReadData* pData)
return EPSHandler();
break;
case MetaActionType::REFPOINT:
- pAction = new MetaRefPointAction;
+ return RefPointHandler();
break;
case MetaActionType::COMMENT:
pAction = new MetaCommentAction;
@@ -1359,4 +1359,22 @@ rtl::Reference<MetaAction> SvmReader::EPSHandler()
return pAction;
}
+
+rtl::Reference<MetaAction> SvmReader::RefPointHandler()
+{
+ auto pAction = new MetaRefPointAction();
+
+ VersionCompatRead aCompat(mrStream);
+ TypeSerializer aSerializer(mrStream);
+
+ Point aRefPoint;
+ aSerializer.readPoint(aRefPoint);
+ bool bSet;
+ mrStream.ReadCharAsBool(bSet);
+
+ pAction->SetRefPoint(aRefPoint);
+ pAction->SetSetting(bSet);
+
+ return pAction;
+}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */