summaryrefslogtreecommitdiff
path: root/chart2/source/model/main
diff options
context:
space:
mode:
authorTünde Tóth <tundeth@gmail.com>2019-12-18 09:49:26 +0100
committerLászló Németh <nemeth@numbertext.org>2020-01-10 14:21:35 +0100
commit6e847aa817999ab18acd534f9e6a86685bb268fc (patch)
tree640176e25db6e79ef4976b9fd6c527b684456c7d /chart2/source/model/main
parent04b2310aaa094794ceedaa1bb6ff1823a2d29d3e (diff)
tdf#129859 XLSX import: don't show deleted legend entries
by adding a new feature to disable selected data points in pie charts. Fixing also tdf#129858 by deleting the correct legend entry in bar charts. Change-Id: Iaaf3a864e9404b8b6d3e2affbb366e18d0f4b43e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86160 Reviewed-by: László Németh <nemeth@numbertext.org> Tested-by: László Németh <nemeth@numbertext.org>
Diffstat (limited to 'chart2/source/model/main')
-rw-r--r--chart2/source/model/main/DataSeriesProperties.cxx6
-rw-r--r--chart2/source/model/main/DataSeriesProperties.hxx3
2 files changed, 8 insertions, 1 deletions
diff --git a/chart2/source/model/main/DataSeriesProperties.cxx b/chart2/source/model/main/DataSeriesProperties.cxx
index c43ced71f40c..5d0cb777e151 100644
--- a/chart2/source/model/main/DataSeriesProperties.cxx
+++ b/chart2/source/model/main/DataSeriesProperties.cxx
@@ -63,6 +63,12 @@ void DataSeriesProperties::AddPropertiesToVector(
beans::PropertyAttribute::BOUND
| beans::PropertyAttribute::MAYBEDEFAULT );
+ rOutProperties.emplace_back( "DeletedLegendEntries",
+ PROP_DATASERIES_DELETED_LEGEND_ENTRIES,
+ cppu::UnoType<uno::Sequence<sal_Int32>>::get(),
+ beans::PropertyAttribute::BOUND
+ | beans::PropertyAttribute::MAYBEVOID );
+
// add properties of service DataPointProperties
DataPointProperties::AddPropertiesToVector( rOutProperties );
}
diff --git a/chart2/source/model/main/DataSeriesProperties.hxx b/chart2/source/model/main/DataSeriesProperties.hxx
index 6791078d5678..b0f6283db54c 100644
--- a/chart2/source/model/main/DataSeriesProperties.hxx
+++ b/chart2/source/model/main/DataSeriesProperties.hxx
@@ -37,7 +37,8 @@ namespace DataSeriesProperties
PROP_DATASERIES_STACKING_DIRECTION,
PROP_DATASERIES_VARY_COLORS_BY_POINT,
PROP_DATASERIES_ATTACHED_AXIS_INDEX,
- PROP_DATASERIES_SHOW_LEGEND_ENTRY
+ PROP_DATASERIES_SHOW_LEGEND_ENTRY,
+ PROP_DATASERIES_DELETED_LEGEND_ENTRIES
};
void AddPropertiesToVector(