summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorShivam Kumar Singh <shivamhere247@gmail.com>2020-08-17 10:46:27 +0530
committerHeiko Tietze <heiko.tietze@documentfoundation.org>2020-08-25 11:29:49 +0200
commiteef202b0659a8ef5f2c1d0b38f292039f0ceaa8d (patch)
tree93306d85b28dcb4777ac979eb1af7dbc03415503 /sw
parentba9c11e0186844fffa02c594a5c49aad4a52242c (diff)
tdf#135334 Add keyboard shortcut to launch SI
Change-Id: Id4e911e36527395eb0ed5f29a089a66e0908e882 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100835 Tested-by: Jenkins Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
Diffstat (limited to 'sw')
-rw-r--r--sw/inc/cmdid.h2
-rw-r--r--sw/sdi/_viewsh.sdi4
-rw-r--r--sw/sdi/swriter.sdi15
-rw-r--r--sw/source/uibase/uiview/view2.cxx9
4 files changed, 30 insertions, 0 deletions
diff --git a/sw/inc/cmdid.h b/sw/inc/cmdid.h
index fda0486edbe2..0728b983bc89 100644
--- a/sw/inc/cmdid.h
+++ b/sw/inc/cmdid.h
@@ -864,6 +864,8 @@
#define SID_ATTR_PAGE_FOOTER_LAYOUT (FN_SIDEBAR + 10)
#define SID_ATTR_PAGE_MARGIN (FN_SIDEBAR + 11)
+#define SID_INSPECTOR_DECK (FN_SIDEBAR + 13)
+
//Member IDs for Fill / SetVariable of items
#define MID_STYLE 0xe0
#define MID_PWIDTH 0xe1
diff --git a/sw/sdi/_viewsh.sdi b/sw/sdi/_viewsh.sdi
index 3959e54b3cc2..e4c419c05a31 100644
--- a/sw/sdi/_viewsh.sdi
+++ b/sw/sdi/_viewsh.sdi
@@ -65,6 +65,10 @@ interface BaseTextEditView
[
ExecMethod = Execute;
]
+ SID_INSPECTOR_DECK
+ [
+ ExecMethod = Execute;
+ ]
FN_PAGEDOWN // status(final|play)
[
ExecMethod = Execute ;
diff --git a/sw/sdi/swriter.sdi b/sw/sdi/swriter.sdi
index ae5c0765ccd4..c815e1285670 100644
--- a/sw/sdi/swriter.sdi
+++ b/sw/sdi/swriter.sdi
@@ -431,6 +431,21 @@ SfxVoidItem SwBackspace FN_BACKSPACE
GroupId = SfxGroupId::Edit;
]
+SfxVoidItem InspectorDeck SID_INSPECTOR_DECK
+[
+ AutoUpdate = TRUE,
+ FastCall = FALSE,
+ ReadOnlyDoc = FALSE,
+ Toggle = FALSE,
+ Container = FALSE,
+ RecordAbsolute = FALSE,
+ RecordPerSet;
+ AccelConfig = TRUE,
+ MenuConfig = FALSE,
+ ToolBoxConfig = FALSE,
+ GroupId = ;
+]
+
SfxVoidItem BorderDialog FN_FORMAT_BORDER_DLG
()
[
diff --git a/sw/source/uibase/uiview/view2.cxx b/sw/source/uibase/uiview/view2.cxx
index 780bfba16c33..bf235be5d1ec 100644
--- a/sw/source/uibase/uiview/view2.cxx
+++ b/sw/source/uibase/uiview/view2.cxx
@@ -125,6 +125,7 @@
#include <docstat.hxx>
#include <wordcountdialog.hxx>
#include <sfx2/sidebar/Sidebar.hxx>
+#include <sfx2/sidebar/SidebarController.hxx>
#include <vcl/GraphicNativeTransform.hxx>
#include <vcl/GraphicNativeMetadata.hxx>
@@ -534,6 +535,14 @@ void SwView::Execute(SfxRequest &rReq)
bool bIgnore = false;
switch( nSlot )
{
+ case SID_INSPECTOR_DECK:
+ {
+ OUString deckId;
+ if (nSlot == SID_INSPECTOR_DECK)
+ deckId = "InspectorDeck";
+ ::sfx2::sidebar::Sidebar::ToggleDeck(deckId, GetViewFrame());
+ }
+ break;
case SID_CREATE_SW_DRAWVIEW:
m_pWrtShell->getIDocumentDrawModelAccess().GetOrCreateDrawModel();
break;