diff options
author | Caolán McNamara <caolanm@redhat.com> | 2017-12-02 20:35:42 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2017-12-03 10:28:13 +0100 |
commit | 0c566771c433ec3c29b2bda7d9cb4efaf30e14e4 (patch) | |
tree | 82e1f1d6908c23406e50444cc9b5ec46e4436336 /starmath | |
parent | 8c89cfe3cdf6595d5f3bb87ecc45b9f450195aac (diff) |
let mathtype import take a SvStream of the contents
Change-Id: I3c02dbee53554aa644b78f8a425b6a4333f2b95d
Reviewed-on: https://gerrit.libreoffice.org/45729
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'starmath')
-rw-r--r-- | starmath/source/mathtype.cxx | 7 | ||||
-rw-r--r-- | starmath/source/mathtype.hxx | 3 |
2 files changed, 8 insertions, 2 deletions
diff --git a/starmath/source/mathtype.cxx b/starmath/source/mathtype.cxx index dda5523d8be7..9f58ee1ece4a 100644 --- a/starmath/source/mathtype.cxx +++ b/starmath/source/mathtype.cxx @@ -564,7 +564,12 @@ bool MathType::Parse(SotStorage *pStor) StreamMode::STD_READ); if ( (!xSrc.is()) || (ERRCODE_NONE != xSrc->GetError())) return false; - pS = xSrc.get(); + return Parse(xSrc.get()); +} + +bool MathType::Parse(SvStream* pStream) +{ + pS = pStream; pS->SetEndian( SvStreamEndian::LITTLE ); EQNOLEFILEHDR aHdr; diff --git a/starmath/source/mathtype.hxx b/starmath/source/mathtype.hxx index caa651acbd75..6bf10cba01ad 100644 --- a/starmath/source/mathtype.hxx +++ b/starmath/source/mathtype.hxx @@ -97,7 +97,8 @@ public: Init(); } - bool Parse( SotStorage* pStor ); + bool Parse(SotStorage* pStor); + bool Parse(SvStream* pStor); bool ConvertFromStarMath( SfxMedium& rMedium ); private: |