summaryrefslogtreecommitdiffstats
path: root/bundled
diff options
context:
space:
mode:
authorPranav Kant <pranavk@collabora.co.uk>2017-11-09 14:57:09 +0530
committerPranav Kant <pranavk@collabora.co.uk>2017-11-09 14:57:09 +0530
commitfea82f5d48b73d238527dfd079d328223072ce81 (patch)
treed99c5d3546a028189ba0338ca019c824365343ab /bundled
parentlokdialog: Let floating window pop out of the dialog container (diff)
downloadonline-fea82f5d48b73d238527dfd079d328223072ce81.tar.gz
online-fea82f5d48b73d238527dfd079d328223072ce81.zip
Update bundled headers
Change-Id: I3480b7465c19203699a68a148dde20dc7d36f47a
Diffstat (limited to 'bundled')
-rw-r--r--bundled/include/LibreOfficeKit/LibreOfficeKit.h10
-rw-r--r--bundled/include/LibreOfficeKit/LibreOfficeKit.hxx38
-rw-r--r--bundled/include/LibreOfficeKit/LibreOfficeKitInit.h13
3 files changed, 44 insertions, 17 deletions
diff --git a/bundled/include/LibreOfficeKit/LibreOfficeKit.h b/bundled/include/LibreOfficeKit/LibreOfficeKit.h
index cc4752e04a..14824821cf 100644
--- a/bundled/include/LibreOfficeKit/LibreOfficeKit.h
+++ b/bundled/include/LibreOfficeKit/LibreOfficeKit.h
@@ -268,7 +268,15 @@ struct _LibreOfficeKitDocumentClass
/// Paints dialog with given dialog id to the buffer
/// @see lok::Document::paintDialog().
- void (*paintDialog) (LibreOfficeKitDocument* pThis, const char* pDialogId, unsigned char* pBuffer, char** pDialogTitle, int* nWidth, int* nHeight);
+ void (*paintDialog) (LibreOfficeKitDocument* pThis, const char* pDialogId,
+ unsigned char* pBuffer,
+ const int x, const int y,
+ const int width, const int height);
+
+ /// Get info about dialog with given dialog id
+ /// @see lok::Document::getDialogInfo().
+ void (*getDialogInfo) (LibreOfficeKitDocument* pThis, const char* pDialogId,
+ char** pDialogTitle, int* pWidth, int* pHeight);
/// @see lok::Document::paintActiveFloatingWindow().
void (*paintActiveFloatingWindow) (LibreOfficeKitDocument* pThis, const char* pDialogId, unsigned char* pBuffer, int* nWidth, int* nHeight);
diff --git a/bundled/include/LibreOfficeKit/LibreOfficeKit.hxx b/bundled/include/LibreOfficeKit/LibreOfficeKit.hxx
index 9534bf3d42..19e121fe65 100644
--- a/bundled/include/LibreOfficeKit/LibreOfficeKit.hxx
+++ b/bundled/include/LibreOfficeKit/LibreOfficeKit.hxx
@@ -12,8 +12,8 @@
#include <cstddef>
-#include "LibreOfficeKit.h"
-#include "LibreOfficeKitInit.h"
+#include <LibreOfficeKit/LibreOfficeKit.h>
+#include <LibreOfficeKit/LibreOfficeKitInit.h>
/*
* The reasons this C++ code is not as pretty as it could be are:
@@ -162,19 +162,37 @@ public:
*
* @param pDialogId Unique dialog id to be painted
* @param pBuffer Buffer with enough memory allocated to render any dialog
- * @param pDialogTitle output parameter pointing to a dialog title
- * string. Should be freed by the caller.
- * @param nWidth output parameter returning the width of the rendered dialog.
- * @param nHeight output parameter returning the height of the rendered dialog
+ * @param x x-coordinate from where the dialog should start painting
+ * @param y y-coordinate from where the dialog should start painting
+ * @param width The width of the dialog image to be painted
+ * @param height The height of the dialog image to be painted
*/
void paintDialog(const char* pDialogId,
unsigned char* pBuffer,
- char** pDialogTitle,
- int& nWidth,
- int& nHeight)
+ const int x,
+ const int y,
+ const int width,
+ const int height)
{
return mpDoc->pClass->paintDialog(mpDoc, pDialogId, pBuffer,
- pDialogTitle, &nWidth, &nHeight);
+ x, y, width, height);
+ }
+
+ /* Get info about dialog with given dialog id
+ *
+ * @param pDialogId Unique dialog id for which to get info about
+ * @param pDialogTitle Pointer to pointer pointing to string containing the
+ * dialog title. Caller should the pointer to allocated string themselves.
+ * @param pWidth The width of the dialog
+ * @param pHeight The height of the dialog
+ */
+ void getDialogInfo(const char* pDialogId,
+ char** pDialogTitle,
+ int& pWidth,
+ int& pHeight)
+ {
+ return mpDoc->pClass->getDialogInfo(mpDoc, pDialogId, pDialogTitle, &pWidth, &pHeight);
+
}
/**
diff --git a/bundled/include/LibreOfficeKit/LibreOfficeKitInit.h b/bundled/include/LibreOfficeKit/LibreOfficeKitInit.h
index 73e2bbb83d..f95ee49634 100644
--- a/bundled/include/LibreOfficeKit/LibreOfficeKitInit.h
+++ b/bundled/include/LibreOfficeKit/LibreOfficeKitInit.h
@@ -10,7 +10,7 @@
#ifndef INCLUDED_LIBREOFFICEKIT_LIBREOFFICEKITINIT_H
#define INCLUDED_LIBREOFFICEKIT_LIBREOFFICEKITINIT_H
-#include "LibreOfficeKit.h"
+#include <LibreOfficeKit/LibreOfficeKit.h>
#ifdef __cplusplus
extern "C"
@@ -28,7 +28,7 @@ extern "C"
#ifndef _WIN32
- #include "dlfcn.h"
+ #include <dlfcn.h>
#ifdef _AIX
# include <sys/ldr.h>
@@ -42,7 +42,7 @@ extern "C"
#endif
#define SEPARATOR '/'
-#if !defined(TARGET_OS_IPHONE)
+#if !defined(IOS)
static void *lok_loadlib(const char *pFN)
{
return dlopen(pFN, RTLD_LAZY
@@ -68,7 +68,7 @@ extern "C"
{
(void)pPath;
}
-#endif // TARGET_OS_IPHONE
+#endif // IOS
static void *lok_dlsym(void *Hnd, const char *pName)
{
@@ -100,7 +100,8 @@ extern "C"
static char *lok_dlerror(void)
{
LPSTR buf = NULL;
- FormatMessageA(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM, NULL, GetLastError(), 0, reinterpret_cast<LPSTR>(&buf), 0, NULL);
+ FormatMessageA(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS,
+ NULL, GetLastError(), 0, reinterpret_cast<LPSTR>(&buf), 0, NULL);
return buf;
}
@@ -169,7 +170,7 @@ static void *lok_dlopen( const char *install_path, char ** _imp_lib )
char *imp_lib;
void *dlhandle;
-#if !defined(TARGET_OS_IPHONE)
+#if !defined(IOS)
size_t partial_length, imp_lib_size;
struct stat dir_st;