diff options
author | Mark Hung <marklh9@gmail.com> | 2020-03-04 19:16:47 +0800 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2020-03-06 20:40:17 +0100 |
commit | 32c8bd660e74169a17fdfd4cdbf42bb79dc5a10d (patch) | |
tree | 9af03076116f64675304bb2a2db458887292c438 /include | |
parent | e3b14639dca24f5ca559044651d2140f8f4a0e74 (diff) |
tdf#120216 improve svx table performance.
By defining operator== for SdrConnectStyleData and
SdrFrameBorderData, and make a deeper comparison instead
of the pointer stored shared_ptr in SdrFrameBorderPrimitive2D.
The SdrFrameBorderPrimitive2D::operator== always
return false before. The response time of clicking a cell
and then entering editing mode improved from 4s to 0.5s
in my environment.
Change-Id: I625d9f69a07f42cac4a6cba45ec9e1c4195b6d58
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90120
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include')
-rw-r--r-- | include/svx/sdr/primitive2d/sdrframeborderprimitive2d.hxx | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/svx/sdr/primitive2d/sdrframeborderprimitive2d.hxx b/include/svx/sdr/primitive2d/sdrframeborderprimitive2d.hxx index b06b5f92d71e..82072669829d 100644 --- a/include/svx/sdr/primitive2d/sdrframeborderprimitive2d.hxx +++ b/include/svx/sdr/primitive2d/sdrframeborderprimitive2d.hxx @@ -54,6 +54,7 @@ namespace drawinglayer const svx::frame::Style& getStyle() const { return maStyle; } const basegfx::B2DVector& getNormalizedPerpendicular() const { return maNormalizedPerpendicular; } bool getStyleMirrored() const { return mbStyleMirrored; } + bool operator==(const SdrConnectStyleData& rCompare) const; }; std::vector<SdrConnectStyleData> maStart; @@ -77,6 +78,7 @@ namespace drawinglayer double fMinDiscreteUnit) const; double getMinimalNonZeroBorderWidth() const; + bool operator==(const SdrFrameBorderData& rCompare) const; }; typedef std::vector<SdrFrameBorderData> SdrFrameBorderDataVector; |