diff options
author | Armin Le Grand (allotropia) <armin.le.grand.extern@allotropia.de> | 2023-12-28 13:18:23 +0100 |
---|---|---|
committer | Armin Le Grand <Armin.Le.Grand@me.com> | 2023-12-28 15:23:48 +0100 |
commit | 2ddec231d513cf317f9fb2c2a82c7e3a0a2d7ef3 (patch) | |
tree | b05b5b166ae135f63990c4200c058a98027d6b7a /sfx2/source/control/request.cxx | |
parent | 249fb2c6b1b8163bfa4bd6c1fcff000a42d2e967 (diff) |
Added boolean op's to SfxPoolItemHolder
...and adapted code to make use of it. This makes checking if
the SfxPoolItemHolder instance contains an Item or not simpler
and thus more readable, no need to access the Item* every time
using getItem() - is okay, but not intuitive.
Change-Id: I8042267cce670aca2641a91cd36285058f17ffbb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161380
Tested-by: Jenkins
Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
Diffstat (limited to 'sfx2/source/control/request.cxx')
-rw-r--r-- | sfx2/source/control/request.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sfx2/source/control/request.cxx b/sfx2/source/control/request.cxx index c838ddfdfc77..c44ebef2eb55 100644 --- a/sfx2/source/control/request.cxx +++ b/sfx2/source/control/request.cxx @@ -418,7 +418,7 @@ void SfxRequest::RemoveItem( sal_uInt16 nID ) void SfxRequest::SetReturnValue(const SfxPoolItem &rItem) { - DBG_ASSERT(nullptr == pImpl->aRetVal.getItem(), "Set Return value multiple times?"); + DBG_ASSERT(!pImpl, "Set Return value multiple times?"); DBG_ASSERT(nullptr != pImpl->pPool, "Missing SfxItemPool (!)"); if (nullptr != pImpl->pPool) pImpl->aRetVal = SfxPoolItemHolder(*pImpl->pPool, &rItem); |