diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-02-18 15:05:28 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-02-19 09:40:22 +0100 |
commit | d4cafd20506a60a148b55e716c690a74c943def7 (patch) | |
tree | 208ea984d2c9f33cffdf4f1f0729964a7ca7d78f /sw | |
parent | ddaaf6d1ae63320e15ce797ca2c0f11a2b539bee (diff) |
use boost::optional in EditFieldInfo
it is inefficient to allocate a tiny object like Color separately on the
heap
Change-Id: I2f03538f987ff032857f3316ed2d8c2c8d731549
Reviewed-on: https://gerrit.libreoffice.org/67968
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/doc/docdraw.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sw/source/core/doc/docdraw.cxx b/sw/source/core/doc/docdraw.cxx index 9eb49b95a44b..2087fbbe58d8 100644 --- a/sw/source/core/doc/docdraw.cxx +++ b/sw/source/core/doc/docdraw.cxx @@ -541,8 +541,8 @@ IMPL_LINK(SwDoc, CalcFieldValueHdl, EditFieldInfo*, pInfo, void) } else if (dynamic_cast<const SdrMeasureField*>( pField)) { - // Measure field - pInfo->ClearFieldColor(); + // Clear measure field + pInfo->SetFieldColor(boost::optional<Color>()); } else if ( auto pTimeField = dynamic_cast<const SvxExtTimeField*>( pField) ) { |