diff options
author | Gulsah Kose <gulsah.1004@gmail.com> | 2017-10-17 15:09:37 +0300 |
---|---|---|
committer | Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> | 2017-10-18 15:56:20 +0200 |
commit | e149c4f3dcd08b9331dbbecf31c200d4d3bb02b5 (patch) | |
tree | 4fa8164c11fdedcb26aeb21dd5bbf42f3ee2dd2a | |
parent | 087a90e27b7219e8c1aaa880b39376c94a0dcaae (diff) |
tdf#112808 Disable "Edit Region" command while cursor in an index.
Change-Id: Icefa1e42831ad0ba7a9f5346545adac0033ce3e0
Signed-off-by: Gulsah Kose <gulsah.1004@gmail.com>
Reviewed-on: https://gerrit.libreoffice.org/43456
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
-rw-r--r-- | sw/source/uibase/shells/basesh.cxx | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sw/source/uibase/shells/basesh.cxx b/sw/source/uibase/shells/basesh.cxx index 8dbfd4e91cc8..c053715bd4ad 100644 --- a/sw/source/uibase/shells/basesh.cxx +++ b/sw/source/uibase/shells/basesh.cxx @@ -1398,8 +1398,12 @@ void SwBaseShell::GetState( SfxItemSet &rSet ) break; case FN_EDIT_CURRENT_REGION: - if( !rSh.GetCurrSection() ) + //tdf#112808 if cursor is in an index, don't show the edit section. + if( !rSh.GetCurrSection() || + rSh.GetCurrSection()->GetType() != CONTENT_SECTION ) + { rSet.DisableItem(nWhich); + } break; case FN_INSERT_REGION: |