diff options
-rw-r--r-- | desktop/qa/desktop_lib/test_desktop_lib.cxx | 4 | ||||
-rw-r--r-- | desktop/source/lib/init.cxx | 34 | ||||
-rw-r--r-- | include/LibreOfficeKit/LibreOfficeKit.h | 8 | ||||
-rw-r--r-- | include/LibreOfficeKit/LibreOfficeKit.hxx | 25 |
4 files changed, 1 insertions, 70 deletions
diff --git a/desktop/qa/desktop_lib/test_desktop_lib.cxx b/desktop/qa/desktop_lib/test_desktop_lib.cxx index c143662d7dd4..217b537fa214 100644 --- a/desktop/qa/desktop_lib/test_desktop_lib.cxx +++ b/desktop/qa/desktop_lib/test_desktop_lib.cxx @@ -3635,11 +3635,9 @@ void DesktopLOKTest::testABI() CPPUNIT_ASSERT_EQUAL(documentClassOffset(67), offsetof(struct _LibreOfficeKitDocumentClass, getEditMode)); CPPUNIT_ASSERT_EQUAL(documentClassOffset(68), offsetof(struct _LibreOfficeKitDocumentClass, setViewTimezone)); - CPPUNIT_ASSERT_EQUAL(documentClassOffset(69), offsetof(struct _LibreOfficeKitDocumentClass, paintThumbnail)); - // As above - CPPUNIT_ASSERT_EQUAL(documentClassOffset(70), sizeof(struct _LibreOfficeKitDocumentClass)); + CPPUNIT_ASSERT_EQUAL(documentClassOffset(69), sizeof(struct _LibreOfficeKitDocumentClass)); } CPPUNIT_TEST_SUITE_REGISTRATION(DesktopLOKTest); diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx index 903dc2b06687..ee1f47a8ea96 100644 --- a/desktop/source/lib/init.cxx +++ b/desktop/source/lib/init.cxx @@ -1114,12 +1114,6 @@ static void doc_paintTile(LibreOfficeKitDocument* pThis, const int nCanvasWidth, const int nCanvasHeight, const int nTilePosX, const int nTilePosY, const int nTileWidth, const int nTileHeight); -static void doc_paintThumbnail(LibreOfficeKitDocument* pThis, - unsigned char* pBuffer, - int bufferWidth, - int bufferHeight, - int width, - const char* pURL); #ifdef IOS static void doc_paintTileToCGContext(LibreOfficeKitDocument* pThis, void* rCGContext, @@ -1393,7 +1387,6 @@ LibLODocument_Impl::LibLODocument_Impl(uno::Reference <css::lang::XComponent> xC m_pDocumentClass->setPartMode = doc_setPartMode; m_pDocumentClass->getEditMode = doc_getEditMode; m_pDocumentClass->paintTile = doc_paintTile; - m_pDocumentClass->paintThumbnail = doc_paintThumbnail; #ifdef IOS m_pDocumentClass->paintTileToCGContext = doc_paintTileToCGContext; #endif @@ -4015,33 +4008,6 @@ static void doc_paintTileToCGContext(LibreOfficeKitDocument* pThis, #endif -static void doc_paintThumbnail(LibreOfficeKitDocument* pThis, - unsigned char* pBuffer, - int bufferWidth, - int bufferHeight, - int width, - const char* pURL) -{ -#if 0 - constexpr float zoom = 0.5f; - constexpr int pixelWidth = 120; - constexpr int pixelHeight = 120; - constexpr int pixelWidthTwips = pixelWidth * 15 / zoom; - constexpr int pixelHeightTwips = pixelHeight * 15 / zoom; - constexpr int offsetXTwips = 15 * 15; // start 15 px/twips before the target to get a clearer thumbnail - constexpr int offsetYTwips = 15 * 15; - - doc_paintTile(pThis, pBuffer, pixelWidth, pixelHeight, x-offsetXTwips, y-offsetYTwips, pixelWidthTwips, pixelHeightTwips); -#else - (void) pThis; - (void) pBuffer; - (void) bufferWidth; - (void) bufferHeight; - (void) width; - (void) pURL; -#endif -} - static void doc_paintPartTile(LibreOfficeKitDocument* pThis, unsigned char* pBuffer, const int nPart, diff --git a/include/LibreOfficeKit/LibreOfficeKit.h b/include/LibreOfficeKit/LibreOfficeKit.h index a54c364737c6..3887d3d3c412 100644 --- a/include/LibreOfficeKit/LibreOfficeKit.h +++ b/include/LibreOfficeKit/LibreOfficeKit.h @@ -501,14 +501,6 @@ struct _LibreOfficeKitDocumentClass /// @see lok::Document::setViewTimezone(). void (*setViewTimezone) (LibreOfficeKitDocument* pThis, int nId, const char* timezone); - /// @see lok::Document::paintThumbnail(). - void (*paintThumbnail) (LibreOfficeKitDocument* pThis, - unsigned char* pBuffer, - int bufferWidth, - int bufferHeight, - int width, - const char* pURL); - #endif // defined LOK_USE_UNSTABLE_API || defined LIBO_INTERNAL_ONLY }; diff --git a/include/LibreOfficeKit/LibreOfficeKit.hxx b/include/LibreOfficeKit/LibreOfficeKit.hxx index 04a3b82e6eca..d3c2e5de78aa 100644 --- a/include/LibreOfficeKit/LibreOfficeKit.hxx +++ b/include/LibreOfficeKit/LibreOfficeKit.hxx @@ -886,31 +886,6 @@ public: mpDoc->pClass->setViewTimezone(mpDoc, nId, timezone); } - /** - * Create a thumbnail of a location in the document. - * - * @param pBuffer Where the thumbnail is painted. Same format as a tile painted - * by paintTile(). - * @param bufferWidth number of pixels in a row of pBuffer. - * @param bufferHeight number of pixels in a column of pBuffer. - * @param width logical width of the rendered rectangle, in TWIPs. - * @param pURL Just the fragment part of a URL, indicating the location in the document - * to render as a thumbnail. As returned by extractRequest(), or null, meaning the start - * of the document. - * - * Note that there is no parameter for the logical height of the - * rendered rectangle. The aspect ratio of the rendered rectangle - * is determined by the bufferWidth and bufferHeight parameters. - */ - void paintThumbnail(unsigned char* pBuffer, - int bufferWidth, - int bufferHeight, - int width, - const char* pURL) - { - return mpDoc->pClass->paintThumbnail(mpDoc, pBuffer, bufferWidth, bufferHeight, width, pURL); - } - #endif // defined LOK_USE_UNSTABLE_API || defined LIBO_INTERNAL_ONLY }; |