From f646e8c8e275dd984ad8aa8592228a89998abf79 Mon Sep 17 00:00:00 2001 From: Andrzej Hunt Date: Tue, 10 Jun 2014 11:31:51 +0100 Subject: Rename C api of LibreOfficeKit. However for the sake of ABI compatibility we can't change liblibreoffice_hook. Change-Id: I0e921efeeab40ef1b53a67c0e7a89d4c75ced831 --- include/LibreOfficeKit/LibreOfficeKit.h | 24 ++++++++++++------------ include/LibreOfficeKit/LibreOfficeKit.hxx | 12 ++++++------ 2 files changed, 18 insertions(+), 18 deletions(-) (limited to 'include') diff --git a/include/LibreOfficeKit/LibreOfficeKit.h b/include/LibreOfficeKit/LibreOfficeKit.h index 9176eba0ae38..97acbab80821 100644 --- a/include/LibreOfficeKit/LibreOfficeKit.h +++ b/include/LibreOfficeKit/LibreOfficeKit.h @@ -15,34 +15,34 @@ extern "C" { #endif -typedef struct _LibreOffice LibreOffice; -typedef struct _LibreOfficeDocument LibreOfficeDocument; +typedef struct _LibreOfficeKit LibreOfficeKit; +typedef struct _LibreOfficeKitDocument LibreOfficeKitDocument; -struct _LibreOffice +struct _LibreOfficeKit { int nSize; - void (*destroy) (LibreOffice *pThis); - int (*initialize) (LibreOffice *pThis, const char *pInstallPath); - LibreOfficeDocument* (*documentLoad) (LibreOffice *pThis, const char *pURL); - char* (*getError) (LibreOffice *pThis); + void (*destroy) (LibreOfficeKit *pThis); + int (*initialize) (LibreOfficeKit *pThis, const char *pInstallPath); + LibreOfficeKitDocument* (*documentLoad) (LibreOfficeKit *pThis, const char *pURL); + char* (*getError) (LibreOfficeKit *pThis); }; -struct _LibreOfficeDocument +struct _LibreOfficeKitDocument { int nSize; - void (*destroy) (LibreOfficeDocument* pThis); - int (*saveAs) (LibreOfficeDocument* pThis, + void (*destroy) (LibreOfficeKitDocument* pThis); + int (*saveAs) (LibreOfficeKitDocument* pThis, const char *pUrl, const char *pFormat); - int (*saveAsWithOptions) (LibreOfficeDocument* pThis, + int (*saveAsWithOptions) (LibreOfficeKitDocument* pThis, const char *pUrl, const char *pFormat, const char *pFilterOptions); }; -LibreOffice* lo_init (const char* pInstallPath); +LibreOfficeKit* lok_init (const char* pInstallPath); #ifdef __cplusplus } diff --git a/include/LibreOfficeKit/LibreOfficeKit.hxx b/include/LibreOfficeKit/LibreOfficeKit.hxx index d689e4b9bc97..de8224c4e0b6 100644 --- a/include/LibreOfficeKit/LibreOfficeKit.hxx +++ b/include/LibreOfficeKit/LibreOfficeKit.hxx @@ -22,10 +22,10 @@ class LODocument { private: - LibreOfficeDocument* mpDoc; + LibreOfficeKitDocument* mpDoc; public: - inline LODocument(LibreOfficeDocument* pDoc) : + inline LODocument(LibreOfficeKitDocument* pDoc) : mpDoc(pDoc) {} @@ -53,10 +53,10 @@ public: class LibLibreOffice { private: - LibreOffice* mpThis; + LibreOfficeKit* mpThis; public: - inline LibLibreOffice(LibreOffice* pThis) : + inline LibLibreOffice(LibreOfficeKit* pThis) : mpThis(pThis) {} @@ -72,7 +72,7 @@ public: inline LODocument* documentLoad(const char* pUrl) { - LibreOfficeDocument* pDoc = mpThis->documentLoad(mpThis, pUrl); + LibreOfficeKitDocument* pDoc = mpThis->documentLoad(mpThis, pUrl); if (pDoc == NULL) return NULL; return new LODocument(pDoc); @@ -87,7 +87,7 @@ public: inline LibLibreOffice* lo_cpp_init(const char* pInstallPath) { - LibreOffice* pThis = lo_init(pInstallPath); + LibreOfficeKit* pThis = lok_init(pInstallPath); if (pThis == NULL || pThis->nSize == 0) return NULL; return new LibLibreOffice(pThis); -- cgit