From 406597a2dad66cdc53bb4091fc61f59a4ca85a51 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Fri, 9 Dec 2022 21:26:00 +0000 Subject: Related: tdf#152266 open 'event' page by default for SID_CONFIGEVENT MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I7a3f6def8bda00588ef2846e5d3b5ed5d1da04de Reviewed-on: https://gerrit.libreoffice.org/c/core/+/143872 Tested-by: Jenkins Reviewed-by: Caolán McNamara --- sfx2/source/appl/appserv.cxx | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'sfx2') diff --git a/sfx2/source/appl/appserv.cxx b/sfx2/source/appl/appserv.cxx index 17e677277e9f..d20d8c54200d 100644 --- a/sfx2/source/appl/appserv.cxx +++ b/sfx2/source/appl/appserv.cxx @@ -403,14 +403,25 @@ void SfxApplication::MiscExec_Impl( SfxRequest& rReq ) SfxItemSetFixed aSet( GetPool() ); + // SID_CONFIG property will determine the default page shown if ( pStringItem ) { aSet.Put( SfxStringItem( SID_CONFIG, pStringItem->GetValue() ) ); } + else if (rReq.GetSlot() == SID_CONFIGEVENT) + { + aSet.Put( SfxStringItem( + SID_CONFIG, "private:resource/event/" ) ); + } + else if (rReq.GetSlot() == SID_TOOLBOXOPTIONS) + { + aSet.Put( SfxStringItem( + SID_CONFIG, "private:resource/toolbar/" ) ); + } #if HAVE_FEATURE_SCRIPTING - // Preselect a macro: + // Preselect a macro in the 'keyboard' page if (auto const item = rReq.GetArg(SID_MACROINFO)) { aSet.Put(*item); } -- cgit