diff options
author | Szymon Kłos <szymon.klos@collabora.com> | 2021-06-08 14:05:14 +0200 |
---|---|---|
committer | Szymon Kłos <szymon.klos@collabora.com> | 2021-07-19 18:10:46 +0200 |
commit | e4f804852279006934731008a1b37aa674dcbe97 (patch) | |
tree | 3f58de5e8cdf06d9d9078b507a0bce76a408fb21 /sd/source | |
parent | 695d926248acf6e26222b26242f95fb46066aae6 (diff) |
jsdialog: sidebar: avoid duplicated widget ids
all controls for sidebar goes to the same window id
we need different names for every widget so
create valuesets with different name every time
Change-Id: I69074e607bfe5fa6db665c0dbcae1f029d13a161
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116836
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119196
Tested-by: Jenkins
Diffstat (limited to 'sd/source')
-rw-r--r-- | sd/source/ui/sidebar/AllMasterPagesSelector.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/sidebar/CurrentMasterPagesSelector.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/sidebar/LayoutMenu.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/sidebar/MasterPagesSelector.cxx | 8 | ||||
-rw-r--r-- | sd/source/ui/sidebar/MasterPagesSelector.hxx | 4 | ||||
-rw-r--r-- | sd/source/ui/sidebar/RecentMasterPagesSelector.cxx | 2 |
6 files changed, 12 insertions, 8 deletions
diff --git a/sd/source/ui/sidebar/AllMasterPagesSelector.cxx b/sd/source/ui/sidebar/AllMasterPagesSelector.cxx index 21fbff298633..76e056120ec8 100644 --- a/sd/source/ui/sidebar/AllMasterPagesSelector.cxx +++ b/sd/source/ui/sidebar/AllMasterPagesSelector.cxx @@ -103,7 +103,7 @@ AllMasterPagesSelector::AllMasterPagesSelector ( ViewShellBase& rBase, const std::shared_ptr<MasterPageContainer>& rpContainer, const css::uno::Reference<css::ui::XSidebar>& rxSidebar) - : MasterPagesSelector(pParent, rDocument, rBase, rpContainer, rxSidebar), + : MasterPagesSelector(pParent, rDocument, rBase, rpContainer, rxSidebar, "modules/simpress/ui/masterpagepanelall.ui", "allvalueset"), mpSortedMasterPages(new SortedMasterPageDescriptorList()) { MasterPagesSelector::Fill(); diff --git a/sd/source/ui/sidebar/CurrentMasterPagesSelector.cxx b/sd/source/ui/sidebar/CurrentMasterPagesSelector.cxx index fbad335c4b26..269099edd0c1 100644 --- a/sd/source/ui/sidebar/CurrentMasterPagesSelector.cxx +++ b/sd/source/ui/sidebar/CurrentMasterPagesSelector.cxx @@ -67,7 +67,7 @@ CurrentMasterPagesSelector::CurrentMasterPagesSelector ( ViewShellBase& rBase, const std::shared_ptr<MasterPageContainer>& rpContainer, const css::uno::Reference<css::ui::XSidebar>& rxSidebar) - : MasterPagesSelector (pParent, rDocument, rBase, rpContainer, rxSidebar) + : MasterPagesSelector (pParent, rDocument, rBase, rpContainer, rxSidebar, "modules/simpress/ui/masterpagepanel.ui", "usedvalueset") { Link<sd::tools::EventMultiplexerEvent&,void> aLink (LINK(this,CurrentMasterPagesSelector,EventMultiplexerListener)); rBase.GetEventMultiplexer()->AddEventListener(aLink); diff --git a/sd/source/ui/sidebar/LayoutMenu.cxx b/sd/source/ui/sidebar/LayoutMenu.cxx index 2c71b8f921dc..469ee474a222 100644 --- a/sd/source/ui/sidebar/LayoutMenu.cxx +++ b/sd/source/ui/sidebar/LayoutMenu.cxx @@ -160,7 +160,7 @@ LayoutMenu::LayoutMenu ( : PanelLayout( pParent, "LayoutPanel", "modules/simpress/ui/layoutpanel.ui" ), mrBase(rViewShellBase), mxLayoutValueSet(new LayoutValueSet(*this)), - mxLayoutValueSetWin(new weld::CustomWeld(*m_xBuilder, "valueset", *mxLayoutValueSet)), + mxLayoutValueSetWin(new weld::CustomWeld(*m_xBuilder, "layoutvalueset", *mxLayoutValueSet)), mbIsMainViewChangePending(false), mxSidebar(rxSidebar), mbIsDisposed(false) diff --git a/sd/source/ui/sidebar/MasterPagesSelector.cxx b/sd/source/ui/sidebar/MasterPagesSelector.cxx index a70ba8ce22dd..fe4af9be67a4 100644 --- a/sd/source/ui/sidebar/MasterPagesSelector.cxx +++ b/sd/source/ui/sidebar/MasterPagesSelector.cxx @@ -57,12 +57,14 @@ MasterPagesSelector::MasterPagesSelector ( SdDrawDocument& rDocument, ViewShellBase& rBase, const std::shared_ptr<MasterPageContainer>& rpContainer, - const css::uno::Reference<css::ui::XSidebar>& rxSidebar) - : PanelLayout( pParent, "MasterPagePanel", "modules/simpress/ui/masterpagepanel.ui" ), + const css::uno::Reference<css::ui::XSidebar>& rxSidebar, + const OUString& rUIFileName, + const OString& rValueSetName) + : PanelLayout( pParent, "MasterPagePanel", rUIFileName ), maMutex(), mpContainer(rpContainer), mxPreviewValueSet(new PreviewValueSet), - mxPreviewValueSetWin(new weld::CustomWeld(*m_xBuilder, "valueset", *mxPreviewValueSet)), + mxPreviewValueSetWin(new weld::CustomWeld(*m_xBuilder, rValueSetName, *mxPreviewValueSet)), mrDocument(rDocument), mrBase(rBase), maCurrentItemList(), diff --git a/sd/source/ui/sidebar/MasterPagesSelector.hxx b/sd/source/ui/sidebar/MasterPagesSelector.hxx index 951a4d6c1667..1b69327892b9 100644 --- a/sd/source/ui/sidebar/MasterPagesSelector.hxx +++ b/sd/source/ui/sidebar/MasterPagesSelector.hxx @@ -51,7 +51,9 @@ public: SdDrawDocument& rDocument, ViewShellBase& rBase, const std::shared_ptr<MasterPageContainer>& rpContainer, - const css::uno::Reference<css::ui::XSidebar>& rxSidebar); + const css::uno::Reference<css::ui::XSidebar>& rxSidebar, + const OUString& rUIFileName, + const OString& rValueSetName); virtual ~MasterPagesSelector() override; virtual void LateInit(); diff --git a/sd/source/ui/sidebar/RecentMasterPagesSelector.cxx b/sd/source/ui/sidebar/RecentMasterPagesSelector.cxx index 4d6cd31ebe94..6e5a46c736a1 100644 --- a/sd/source/ui/sidebar/RecentMasterPagesSelector.cxx +++ b/sd/source/ui/sidebar/RecentMasterPagesSelector.cxx @@ -57,7 +57,7 @@ RecentMasterPagesSelector::RecentMasterPagesSelector ( ViewShellBase& rBase, const std::shared_ptr<MasterPageContainer>& rpContainer, const css::uno::Reference<css::ui::XSidebar>& rxSidebar) - : MasterPagesSelector (pParent, rDocument, rBase, rpContainer, rxSidebar) + : MasterPagesSelector (pParent, rDocument, rBase, rpContainer, rxSidebar, "modules/simpress/ui/masterpagepanelrecent.ui", "recentvalueset") { } |