diff options
author | Eike Rathke <erack@redhat.com> | 2016-01-05 22:26:45 +0100 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2016-01-05 23:42:07 +0100 |
commit | 4ae7b66286f391839b0d8d6c5a73ee7849eb4d1f (patch) | |
tree | c28933b70a8c5bcf62d93a6e5feaa86d62183a5c /include/formula | |
parent | tdf#93565 Use multiple docs for individual PDF MM (diff) | |
download | core-4ae7b66286f391839b0d8d6c5a73ee7849eb4d1f.tar.gz core-4ae7b66286f391839b0d8d6c5a73ee7849eb4d1f.zip |
use new'ed FormulaToken and FormulaTokenArray::Add()
... instead of a temporary instance and AddToken() that just clones it
again.
Add function comment describing the difference.
Change-Id: I3f089965d394b33d7bbbb9a1c3f69dc1c4182fd2
Diffstat (limited to 'include/formula')
-rw-r--r-- | include/formula/tokenarray.hxx | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/formula/tokenarray.hxx b/include/formula/tokenarray.hxx index 292b3182cb8b..bf3056a392b3 100644 --- a/include/formula/tokenarray.hxx +++ b/include/formula/tokenarray.hxx @@ -296,7 +296,12 @@ public: */ virtual void CheckToken( const FormulaToken& t ); + /** Clones the token and then adds the clone to the pCode array. + For just new'ed tokens use Add() instead of cloning it again. + Use this AddToken() when adding a token from another origin. + */ FormulaToken* AddToken( const FormulaToken& ); + FormulaToken* AddString( const svl::SharedString& rStr ); FormulaToken* AddDouble( double fVal ); FormulaToken* AddExternal( const sal_Unicode* pStr ); |