diff options
author | Justin Luth <justin_luth@sil.org> | 2021-11-23 10:23:37 +0200 |
---|---|---|
committer | Justin Luth <jluth@mail.com> | 2021-11-23 11:27:20 +0100 |
commit | 87fafdb9dc045735e235cbba2ef37198043422c7 (patch) | |
tree | 09d1e74945da0bd7bf9e045487b006b9e77eca93 /sw/source/uibase | |
parent | acd820a47e90ceb9404f05dbc9f6c040bd7a9fee (diff) |
tdf#131150 sw menu: use nSlotId=0 to avoid adding to set
This fixes a regression in LO 6.4 caused by
commit 86cb2a1f98c0585d2121e6ae34fe62f072ef9a63
Not surprisingly, adding a new condition that multiple
other items match on caused a regression.
bFlag is always set to false at the top of the loop.
In the above commit, bFlag was not set to true,
and so thus it would always be false.
So just set the SlotId to 0
to avoid rSet.Put - like so many other cases already do.
Change-Id: I02e9ca9d8dd75db519e801ad0e86fc8d541ae20a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125688
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
Reviewed-by: Justin Luth <jluth@mail.com>
Diffstat (limited to 'sw/source/uibase')
-rw-r--r-- | sw/source/uibase/shells/drwtxtex.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sw/source/uibase/shells/drwtxtex.cxx b/sw/source/uibase/shells/drwtxtex.cxx index 1d0a8ee58ccc..3f7a1e5e5dad 100644 --- a/sw/source/uibase/shells/drwtxtex.cxx +++ b/sw/source/uibase/shells/drwtxtex.cxx @@ -957,6 +957,7 @@ void SwDrawTextShell::GetState(SfxItemSet& rSet) { if (!URLFieldHelper::IsCursorAtURLField(pOLV)) rSet.DisableItem(nWhich); + nSlotId = 0; } break; default: @@ -964,7 +965,7 @@ void SwDrawTextShell::GetState(SfxItemSet& rSet) break; } - if (nSlotId && bFlag) + if (nSlotId) rSet.Put(SfxBoolItem(nWhich, bFlag)); nWhich = aIter.NextWhich(); |