summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.co.uk>2015-09-15 09:31:49 +0200
committerMiklos Vajna <vmiklos@collabora.co.uk>2015-09-21 07:30:14 +0200
commit10a0cad9d6990abac507899a34fbcdeb466187f7 (patch)
treefc7e4aacd8d98ba29e80bc31498126165a87df64 /include
parent4f62c14748c0e62ad0212e831d606ac32e694eca (diff)
lok::Document: add destroyView()
Change-Id: Id9e92593217541b4123e95279019cec3c958056c
Diffstat (limited to 'include')
-rw-r--r--include/LibreOfficeKit/LibreOfficeKit.h2
-rw-r--r--include/LibreOfficeKit/LibreOfficeKit.hxx9
-rw-r--r--include/sfx2/lokhelper.hxx2
3 files changed, 13 insertions, 0 deletions
diff --git a/include/LibreOfficeKit/LibreOfficeKit.h b/include/LibreOfficeKit/LibreOfficeKit.h
index b59d3f8c9f5d..7f41d13ff393 100644
--- a/include/LibreOfficeKit/LibreOfficeKit.h
+++ b/include/LibreOfficeKit/LibreOfficeKit.h
@@ -168,6 +168,8 @@ struct _LibreOfficeKitDocumentClass
/// @see lok::Document::createView().
int (*createView) (LibreOfficeKitDocument* pThis);
+ /// @see lok::Document::destroyView().
+ void (*destroyView) (LibreOfficeKitDocument* pThis, int nId);
#endif // LOK_USE_UNSTABLE_API
};
diff --git a/include/LibreOfficeKit/LibreOfficeKit.hxx b/include/LibreOfficeKit/LibreOfficeKit.hxx
index 32f190227719..3e1a0ac20b07 100644
--- a/include/LibreOfficeKit/LibreOfficeKit.hxx
+++ b/include/LibreOfficeKit/LibreOfficeKit.hxx
@@ -267,6 +267,15 @@ public:
{
return mpDoc->pClass->createView(mpDoc);
}
+
+ /**
+ * Destroy a view of an existring document.
+ * @param nId a view ID, returned by createView().
+ */
+ void destroyView(int nId)
+ {
+ mpDoc->pClass->destroyView(mpDoc, nId);
+ }
#endif // LOK_USE_UNSTABLE_API
};
diff --git a/include/sfx2/lokhelper.hxx b/include/sfx2/lokhelper.hxx
index bc3f43010c41..9430cd5665d8 100644
--- a/include/sfx2/lokhelper.hxx
+++ b/include/sfx2/lokhelper.hxx
@@ -16,6 +16,8 @@ class SFX2_DLLPUBLIC SfxLokHelper
public:
/// Create a new view shell for pViewShell's object shell.
static int createView(SfxViewShell* pViewShell);
+ /// Destroy a view shell from the global shell list.
+ static void destroyView(size_t nId);
/// Total number of view shells.
static int getViews();