From 22f2cf3ccc6d0c9ba2c2860735e789d6b3a25f72 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Mon, 29 Apr 2019 16:24:12 +0200 Subject: implement std::hash for css::uno::Reference and rtl::Reference The declaration in BarChart.cxx is particularly suspicious, because it was using a < for the KeyEqual template parameter. Been there since: commit b2c3233e5f267b5d244d722a94424a3b224b3314 Date: Thu Dec 21 20:08:33 2017 +0900 chart2: suspend/resume setting rects dirty for 3D shapes comphelper::OInterfaceCompare is no longer necessary Change-Id: I8278c4a3d9113a18570ca237cd05d553ec8f3975 Reviewed-on: https://gerrit.libreoffice.org/71537 Tested-by: Jenkins Reviewed-by: Noel Grandin --- chart2/source/view/charttypes/BarChart.cxx | 23 +---------------------- 1 file changed, 1 insertion(+), 22 deletions(-) (limited to 'chart2') diff --git a/chart2/source/view/charttypes/BarChart.cxx b/chart2/source/view/charttypes/BarChart.cxx index b3d27a933d7a..bb1c50387d2e 100644 --- a/chart2/source/view/charttypes/BarChart.cxx +++ b/chart2/source/view/charttypes/BarChart.cxx @@ -45,27 +45,6 @@ using namespace ::com::sun::star; using namespace ::rtl::math; using namespace ::com::sun::star::chart2; -namespace -{ - -struct XShapeCompare -{ - bool operator() (uno::Reference const & lhs, uno::Reference const & rhs) const - { - return lhs.get() < rhs.get(); - } -}; - -struct XShapeHash -{ - bool operator()(uno::Reference const & rXShape) const - { - return rXShape->getShapeType().hashCode(); - } -}; - -} // end anonymous namespace - BarChart::BarChart( const uno::Reference& xChartTypeModel , sal_Int32 nDimensionCount ) : VSeriesPlotter( xChartTypeModel, nDimensionCount ) @@ -501,7 +480,7 @@ void BarChart::createShapes() bool bDrawConnectionLinesInited = false; bool bOnlyConnectionLinesForThisPoint = false; - std::unordered_set, XShapeHash, XShapeCompare> aShapeSet; + std::unordered_set> aShapeSet; const comphelper::ScopeGuard aGuard([aShapeSet]() { -- cgit