diff options
author | Attila Szűcs <attila.szucs@collabora.com> | 2023-05-04 16:59:54 +0200 |
---|---|---|
committer | Szymon Kłos <szymon.klos@collabora.com> | 2023-05-12 14:02:59 +0200 |
commit | 39b25518ce96a50f54459f681edcb95057507251 (patch) | |
tree | 379ed96391778e959e8fa0f9460197bbd2cd166e /sw/source/uibase/utlui/navipi.cxx | |
parent | 9c8e38ef8c69d519d72737b404d54d6413a98518 (diff) |
LOK: Navi-10 hide not needed controls
Hide controls we dont need in navigator now.
Change-Id: Ibf6843be2976bcd4d90e67130dd0cc08d0988c0b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151397
Tested-by: Szymon Kłos <szymon.klos@collabora.com>
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151702
Tested-by: Jenkins
Diffstat (limited to 'sw/source/uibase/utlui/navipi.cxx')
-rw-r--r-- | sw/source/uibase/utlui/navipi.cxx | 29 |
1 files changed, 24 insertions, 5 deletions
diff --git a/sw/source/uibase/utlui/navipi.cxx b/sw/source/uibase/utlui/navipi.cxx index e609aa539e4c..0489f5146ae9 100644 --- a/sw/source/uibase/utlui/navipi.cxx +++ b/sw/source/uibase/utlui/navipi.cxx @@ -49,6 +49,8 @@ #include <workctrl.hxx> +#include <comphelper/lok.hxx> + using namespace ::com::sun::star::uno; using namespace ::com::sun::star::frame; @@ -682,6 +684,14 @@ SwNavigationPI::SwNavigationPI(weld::Widget* pParent, m_xDocListBox->set_accessible_name(m_aStatusArr[3]); m_aExpandedSize = m_xContainer->get_preferred_size(); + + if(comphelper::LibreOfficeKit::isActive()) + { + m_xBuilder->weld_container("gridcontent16")->hide(); + m_xDocListBox->hide(); + m_xGlobalBox->hide(); + m_xGlobalToolBox->hide(); + } } weld::Window* SwNavigationPI::GetFrameWeld() const @@ -765,12 +775,15 @@ void SwNavigationPI::NotifyItemUpdate(sal_uInt16 nSID, SfxItemState /*eState*/, } else if (nSID == FN_STAT_PAGE) { - SwView *pActView = GetCreateView(); - if(pActView) + if(!comphelper::LibreOfficeKit::isActive()) { - SwWrtShell &rSh = pActView->GetWrtShell(); - m_xEdit->set_max(rSh.GetPageCnt()); - m_xEdit->set_width_chars(3); + SwView *pActView = GetCreateView(); + if(pActView) + { + SwWrtShell &rSh = pActView->GetWrtShell(); + m_xEdit->set_max(rSh.GetPageCnt()); + m_xEdit->set_width_chars(3); + } } } } @@ -1045,6 +1058,12 @@ void SwNavigationPI::SetRegionDropMode(RegionMode nNewMode) void SwNavigationPI::ToggleTree() { + if (comphelper::LibreOfficeKit::isActive()) + { + m_xGlobalTree->HideTree(); + return; + } + bool bGlobalDoc = IsGlobalDoc(); if (!IsGlobalMode() && bGlobalDoc) { |