summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPranam Lashkari <lpranam@collabora.com>2021-03-30 21:52:13 +0530
committerJan Holesovsky <kendy@collabora.com>2021-03-31 10:45:43 +0200
commit9180416ee296acad5bcd482569c6c53ecfff5b20 (patch)
treecd52d53a6d56eebddd251e83f4647ba9679f0cff
parent41b66bb6701cc8de67b1dd0d72a10f6b92372f30 (diff)
LOK: getPartInfo now returns master page count
master page count will be used when switching to master view to know how many slide previews to be shown Change-Id: I11735797d16538a9f667a85b90a86b1e6cf9b5aa Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113383 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Jan Holesovsky <kendy@collabora.com>
-rw-r--r--sd/source/ui/unoidl/unomodel.cxx3
1 files changed, 3 insertions, 0 deletions
diff --git a/sd/source/ui/unoidl/unomodel.cxx b/sd/source/ui/unoidl/unomodel.cxx
index 21298e4da4af..5de97c06936f 100644
--- a/sd/source/ui/unoidl/unomodel.cxx
+++ b/sd/source/ui/unoidl/unomodel.cxx
@@ -2274,11 +2274,14 @@ OUString SdXImpressDocument::getPartInfo(int nPart)
const bool bIsVisible = pViewSh->IsVisible(nPart);
const bool bIsSelected = pViewSh->IsSelected(nPart);
+ const sal_Int16 nMasterPageCount= pViewSh->GetDoc()->GetMasterSdPageCount(pViewSh->GetPageKind());
OUString aPartInfo = "{ \"visible\": \"" +
OUString::number(static_cast<unsigned int>(bIsVisible)) +
"\", \"selected\": \"" +
OUString::number(static_cast<unsigned int>(bIsSelected)) +
+ "\", \"masterPageCount\": \"" +
+ OUString::number(nMasterPageCount) +
"\" }";
return aPartInfo;
}