summaryrefslogtreecommitdiff
path: root/sd
diff options
context:
space:
mode:
authorAshod Nakashian <ashod.nakashian@collabora.co.uk>2018-09-16 17:27:35 -0400
committerAshod Nakashian <ashnakash@gmail.com>2019-04-15 02:32:45 +0200
commit3c9660f99e477436348ff5a4afed423ff2888df5 (patch)
treefe01effb2b33873ae1cfd23c2811885d685f1bf4 /sd
parenta3c8895563833a1d46850cb5cca38765d4f4bedb (diff)
LOK: support for ordering/moving parts
Currently reordering of slides is only supported for presentations, although it is provisioned for spreadsheets as well. Change-Id: I6c35066d6a5ef7586d34a8e8b89db69a20b86572 Reviewed-on: https://gerrit.libreoffice.org/69612 Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Ashod Nakashian <ashnakash@gmail.com>
Diffstat (limited to 'sd')
-rw-r--r--sd/source/ui/inc/unomodel.hxx2
-rw-r--r--sd/source/ui/unoidl/unomodel.cxx7
2 files changed, 9 insertions, 0 deletions
diff --git a/sd/source/ui/inc/unomodel.hxx b/sd/source/ui/inc/unomodel.hxx
index 993749bbcb3d..b0345ce2d140 100644
--- a/sd/source/ui/inc/unomodel.hxx
+++ b/sd/source/ui/inc/unomodel.hxx
@@ -267,6 +267,8 @@ public:
virtual OUString getPostIts() override;
/// @see vcl::ITiledRenderable::selectPart().
virtual void selectPart(int nPart, int nSelect) override;
+ /// @see vcl::ITiledRenderable::moveSelectedParts().
+ virtual void moveSelectedParts(int nPosition, bool bDuplicate) override;
/// @see vcl::ITiledRenderable::getPartInfo().
virtual OUString getPartInfo(int nPart) override;
diff --git a/sd/source/ui/unoidl/unomodel.cxx b/sd/source/ui/unoidl/unomodel.cxx
index 2aa5dc247208..fe0c82d9309a 100644
--- a/sd/source/ui/unoidl/unomodel.cxx
+++ b/sd/source/ui/unoidl/unomodel.cxx
@@ -2298,6 +2298,13 @@ void SdXImpressDocument::selectPart(int nPart, int nSelect)
pViewSh->SelectPage(nPart, nSelect);
}
+void SdXImpressDocument::moveSelectedParts(int nPosition, bool bDuplicate)
+{
+ // Duplicating is currently unsupported.
+ if (!bDuplicate)
+ mpDoc->MovePages(nPosition);
+}
+
OUString SdXImpressDocument::getPartInfo(int nPart)
{
DrawViewShell* pViewSh = GetViewShell();