[Libreoffice-commits] online.git: bundled/include

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Mon Dec 10 22:23:55 UTC 2018


 bundled/include/LibreOfficeKit/LibreOfficeKit.h   |   10 +++++++
 bundled/include/LibreOfficeKit/LibreOfficeKit.hxx |   29 ++++++++++++++++++++++
 2 files changed, 39 insertions(+)

New commits:
commit cd389cb6b0fffa4ba1b2a8c6428252715774f09a
Author:     Tor Lillqvist <tml at collabora.com>
AuthorDate: Tue Dec 11 00:23:25 2018 +0200
Commit:     Tor Lillqvist <tml at collabora.com>
CommitDate: Tue Dec 11 00:23:25 2018 +0200

    Update from core master
    
    Change-Id: Iae9ae1d0227a40bfc6de95557bd99210c7e437fa

diff --git a/bundled/include/LibreOfficeKit/LibreOfficeKit.h b/bundled/include/LibreOfficeKit/LibreOfficeKit.h
index 4dd23a2cb..68074a637 100644
--- a/bundled/include/LibreOfficeKit/LibreOfficeKit.h
+++ b/bundled/include/LibreOfficeKit/LibreOfficeKit.h
@@ -94,6 +94,16 @@ struct _LibreOfficeKitClass
         @since LibreOffice 6.0
      */
     int (*runMacro) (LibreOfficeKit *pThis, const char* pURL);
+
+    /** @see lok::Office::translateGet().
+        @since LibreOffice 6.3
+     */
+    char* (*translateGet) (LibreOfficeKit *pThis, const char* pId, const char* pPrefixName, const char* pBcp47LanguageTag);
+
+    /** @see lok::Office::translateNGet().
+        @since LibreOffice 6.3
+     */
+    char* (*translateNGet) (LibreOfficeKit *pThis, const char* pId, int n, const char* pPrefixName, const char* pBcp47LanguageTag);
 };
 
 #define LIBREOFFICEKIT_DOCUMENT_HAS(pDoc,member) LIBREOFFICEKIT_HAS_MEMBER(LibreOfficeKitDocumentClass,member,(pDoc)->pClass->nSize)
diff --git a/bundled/include/LibreOfficeKit/LibreOfficeKit.hxx b/bundled/include/LibreOfficeKit/LibreOfficeKit.hxx
index 5d7771cf8..923af7136 100644
--- a/bundled/include/LibreOfficeKit/LibreOfficeKit.hxx
+++ b/bundled/include/LibreOfficeKit/LibreOfficeKit.hxx
@@ -791,6 +791,35 @@ public:
     {
         return mpThis->pClass->runMacro( mpThis, pURL );
     }
+
+    /**
+     * Fetch translation for a string.
+     *
+     * @since LibreOffice 6.3
+     * @returns the translated string, if available
+     * @param pId the context and string, separated by a '\004' character
+     * @param pPrefixName the prefix passed to Translate::Create()
+     * @param pBcp47LanguageTag the locale into which the string should be translated
+     */
+    char* translateGet( const char* pId, const char* pPrefixName, const char* pBcp47LanguageTag )
+    {
+        return mpThis->pClass->translateGet( mpThis, pId, pPrefixName, pBcp47LanguageTag );
+    }
+
+    /**
+     * Fetch translation for a string corresponding to a specific number of something.
+     *
+     * @since LibreOffice 6.3
+     * @returns the translated string, if available
+     * @param pId the context and string, separated by a '\004' character
+     * @param n the number
+     * @param pPrefixName the prefix passed to Translate::Create()
+     * @param pBcp47LanguageTag the locale into which the string should be translated
+     */
+    char* translateNGet( const char* pId, int n, const char* pPrefixName, const char* pBcp47LanguageTag )
+    {
+        return mpThis->pClass->translateNGet( mpThis, pId, n, pPrefixName, pBcp47LanguageTag );
+    }
 };
 
 /// Factory method to create a lok::Office instance.


More information about the Libreoffice-commits mailing list