diff options
author | Armin Le Grand (allotropia) <armin.le.grand.extern@allotropia.de> | 2024-03-19 18:39:10 +0100 |
---|---|---|
committer | Armin Le Grand <Armin.Le.Grand@me.com> | 2024-03-21 21:39:57 +0100 |
commit | d053413402956fecbcf65c9319ebbe2cd6c08dfa (patch) | |
tree | 4bafd4584551d8a36431a483fbd6e1161a94c14b /svx/inc/sdr | |
parent | 1f912bdbf7848f8d4073be62ccb589927d60a95f (diff) |
ITEM: Remove InvalidateAllItems()
I checked if this is used, but it can be replaced
using Clear() -> all. This prevents that the whole
array of Items in an ItemSet gets set to
INVALID_POOL_ITEM.
I also checked if INVALID_POOL_ITEM/IsInvalidItem
is needed at all representing SfxItemState::DONTCARE
but it is and still will need to be set for individual
Items.
At last checked if SfxItemState::UNKNOWN and
::DISABLED really need to be separate states, but
indeed there are some rare cases that need that.
To make things more consistent I also renamed
SfxItemState::DONTCARE to SfxItemState::INVALID
to better match Set/IsInvalid calls at ItemSet.
The build showed a missing UT and led to a problem
due to the hand-made ItemSet-like SearchAttrItemList.
The state 'invalid' seems to be used as 'unused'
marker. It should be changed to use SfxPoolItemHolder
and not need that. For now, set by using an own loop
to set to that state.
Change-Id: Ifc51aad60570569a1e37d3084a5e307eed47d06c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165035
Tested-by: Jenkins
Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
Diffstat (limited to 'svx/inc/sdr')
-rw-r--r-- | svx/inc/sdr/properties/e3dcompoundproperties.hxx | 2 | ||||
-rw-r--r-- | svx/inc/sdr/properties/e3dsceneproperties.hxx | 2 | ||||
-rw-r--r-- | svx/inc/sdr/properties/groupproperties.hxx | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/svx/inc/sdr/properties/e3dcompoundproperties.hxx b/svx/inc/sdr/properties/e3dcompoundproperties.hxx index 96abc06f2df2..e776abfdbc59 100644 --- a/svx/inc/sdr/properties/e3dcompoundproperties.hxx +++ b/svx/inc/sdr/properties/e3dcompoundproperties.hxx @@ -47,7 +47,7 @@ namespace sdr::properties // Get merged ItemSet. Normally, this maps directly to GetObjectItemSet(), but may // be overridden e.g for group objects to return a merged ItemSet of the object. // When using this method the returned ItemSet may contain items in the state - // SfxItemState::DONTCARE which means there were several such items with different + // SfxItemState::INVALID which means there were several such items with different // values. virtual const SfxItemSet& GetMergedItemSet() const override; diff --git a/svx/inc/sdr/properties/e3dsceneproperties.hxx b/svx/inc/sdr/properties/e3dsceneproperties.hxx index 4606499bdffe..4ffa1a4f4815 100644 --- a/svx/inc/sdr/properties/e3dsceneproperties.hxx +++ b/svx/inc/sdr/properties/e3dsceneproperties.hxx @@ -46,7 +46,7 @@ namespace sdr::properties // get merged ItemSet. Normally, this maps directly to GetObjectItemSet(), but may // be overridden e.g for group objects to return a merged ItemSet of the object. // When using this method the returned ItemSet may contain items in the state - // SfxItemState::DONTCARE which means there were several such items with different + // SfxItemState::INVALID which means there were several such items with different // values. virtual const SfxItemSet& GetMergedItemSet() const override; diff --git a/svx/inc/sdr/properties/groupproperties.hxx b/svx/inc/sdr/properties/groupproperties.hxx index d31806d06bd1..49e6107a25dd 100644 --- a/svx/inc/sdr/properties/groupproperties.hxx +++ b/svx/inc/sdr/properties/groupproperties.hxx @@ -49,7 +49,7 @@ namespace sdr::properties // get merged ItemSet. Normally, this maps directly to GetObjectItemSet(), but may // be overridden e.g for group objects to return a merged ItemSet of the object. // When using this method the returned ItemSet may contain items in the state - // SfxItemState::DONTCARE which means there were several such items with different + // SfxItemState::INVALID which means there were several such items with different // values. virtual const SfxItemSet& GetMergedItemSet() const override; |