diff options
author | Muhammet Kara <muhammet.kara@pardus.org.tr> | 2017-01-12 11:17:11 +0300 |
---|---|---|
committer | Katarina Behrens <Katarina.Behrens@cib.de> | 2017-01-17 13:08:15 +0000 |
commit | ce0f9962d1d1d5a4f6301be18c23b2d14efd9d6b (patch) | |
tree | 22fd305e1f659d2c4a6acbf0755581471f35e9e9 /cui/source | |
parent | 38a1e19ae49ac30757e4020b60adee7c30f3deb9 (diff) |
tdf#105014: Disable related buttons when there is no menu to edit
Clicking the "Add Separator" or the "Add Submenu" button, when there is
no menu edit, causes LibreOffice to crash. So disable them properly.
Change-Id: Ibf685145a87c9e4343d83e1bb5ef6f08136c8f31
Reviewed-on: https://gerrit.libreoffice.org/32987
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
Diffstat (limited to 'cui/source')
-rw-r--r-- | cui/source/customize/cfg.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cui/source/customize/cfg.cxx b/cui/source/customize/cfg.cxx index a3406f2f10e0..d411fa820373 100644 --- a/cui/source/customize/cfg.cxx +++ b/cui/source/customize/cfg.cxx @@ -2544,7 +2544,6 @@ void SvxMenuConfigPage::UpdateButtonStates() m_pMoveUpButton->Enable( false ); m_pMoveDownButton->Enable( false ); m_pDeleteCommandButton->Enable(false); - m_pAddSeparatorButton->Enable(); pPopup->EnableItem( "modrename", false ); @@ -2653,6 +2652,7 @@ IMPL_LINK_NOARG( SvxMenuConfigPage, SelectMenu, ListBox&, void ) m_pModifyCommandButton->Enable( pMenuData != nullptr ); m_pAddCommandsButton->Enable( pMenuData != nullptr ); m_pAddSeparatorButton->Enable( pMenuData != nullptr ); + m_pAddSubmenuButton->Enable( pMenuData != nullptr ); PopupMenu* pPopup = m_pModifyTopLevelButton->GetPopupMenu(); if ( pMenuData ) |