summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2014-07-31LOK: add document loading failure test.feature/lok_sofficemainAndrzej Hunt1-0/+13
We don't really have any way of telling the client that the file didn't exist yet though, so not very useful so far. Change-Id: I1db386781b88b345f3e9cb4f37838ca1d95f92f9
2014-07-31LOK documentLoad needs SolarMutex protection too.Andrzej Hunt1-0/+2
We probably need to do this for most of LOK now that we use soffice_main. Change-Id: I77be7865511c083679cf2f68b0e5df106506fd70
2014-07-31LOK: add test for getDocumentType.Andrzej Hunt3-0/+30
Change-Id: I264567f73dae9ecd061e09c4413857f793fcac48
2014-07-31LOK: add slide name retrieval test.Andrzej Hunt2-0/+23
Change-Id: I6d2bc4dfa634223da662af6f7c9a91f06cfe7534
2014-07-31Use one test instance to run all LOK tests.Andrzej Hunt1-7/+18
Recreating Office instances after destruction (when still within the same process) currently fails, hence we need to do all tests at once for now. Change-Id: Ic7652c909e1cd970fe1ee76995e61fb6aae8f96c
2014-07-30Make common paths member variables.Andrzej Hunt1-6/+7
We'll need these for other tests too. Change-Id: Ia99c2e60f5e5bb24a83875a9dcf85a6b4f54beb4
2014-07-30Use SolarMutexGuard instead of pairs of Acquire/ReleaseSolarMutexAndrzej Hunt1-53/+46
Change-Id: I7ff41dd932fd9860dff944b3bf8ff5bdc230ae5d
2014-07-30LokDocView: Update part selector when mode changes.Andrzej Hunt1-5/+21
Change-Id: Ice754a46d07ce2714257c30e1aef27193b614cd3
2014-07-30LokDocView: set current item for part selector.Andrzej Hunt1-1/+2
Change-Id: Idbb3d63803bd60a182a9b8e26620d11b2d643cb6
2014-07-29gtktiledviewer: add part mode selector.Andrzej Hunt1-1/+34
Change-Id: Ia1e78df1d833f9b0fbda0b78136590c9c960fa27
2014-07-29Protect setPartMode and ensure we actually show the new mode.Andrzej Hunt1-1/+25
Change-Id: I3642702c5bf268f3c9ab04162166078052804270
2014-07-29Impress/Tiled Rendering: implement setPartMode.Andrzej Hunt2-1/+35
Change-Id: I831953ac3fa1d0a15b64aa008cc3bfb79e72575a
2014-07-29LOKDocView: add set_part_mode.Andrzej Hunt2-0/+9
Change-Id: I0e14a535124e93979ef05431255911245a11aa29
2014-07-29Impress/Tiled Rendering: return correct number for getPart.Andrzej Hunt1-1/+2
It looks like page ids begin with 1. Change-Id: I367285b8cfa1fcc9b8f22a9bb3c679d7e9579099
2014-07-29ITiledRenderable: provide default implementations for some methods.Andrzej Hunt3-21/+12
Writer doesn't understand the concept of parts at the moment, it makes most sense to keep these dummy implementations central. Change-Id: Iafbd89864b753ba2bed28a05b0f59df85f364feb
2014-07-29Impress: Implement getPartName.Andrzej Hunt2-0/+8
Change-Id: I614838505fef901fc37e8d3906bb59c60b034453
2014-07-29gtktiledviewer: show part names in selector.Andrzej Hunt1-5/+15
Change-Id: I02ae5b729f96e36b3f226218b32495907cb63cf3
2014-07-29LOKDocView: add part name retrieval.Andrzej Hunt2-2/+6
Change-Id: Iac31de0410d7f6187e5884152c329375047a23f4
2014-07-29Remove horrifically outdated comment.Andrzej Hunt1-5/+0
Change-Id: I1362489c9aecf536b31bf6ab57ad8c149f37a876
2014-07-29LOK: add setPartMode.Andrzej Hunt3-0/+37
This API seems to be simplest in the long run where we'll want to be able to select between rendering slides/notes/both/embedded objects, and maybe even adding the option of switching between continuous and single page mode in writer (although I have no idea how hard getting a single page mode out of writer would be). Change-Id: I5bdfdb61854c37281c6992c8f3ed1c50c8aa0919
2014-07-29LOK: Add getPartName.Andrzej Hunt4-0/+39
By default (i.e. for writer) we can just return an empty string, and we only actually need to implement ITiledRenderable's getPartName for components that actually support it (i.e. calc/impress). Change-Id: I8b381e5d7a8000638b02f763b4bea8ef0226f8e0
2014-07-29Fix comment typo.Andrzej Hunt1-1/+1
Change-Id: I8ebe3ad2a6efcf1797a2dc941994c7fc1e36f4bf
2014-07-29One final removal of libreofficekit static library.Andrzej Hunt1-4/+0
(Seems you need a clean build to notice this...)
2014-07-29Upgrade lokconf_init to LibreOfficeKitInit.hAndrzej Hunt1-0/+1
Change-Id: I0581a107c3eefd33c25b003afe9f7be217598441
2014-07-29Kill the libreofficekit static library / shim.c.Andrzej Hunt10-39/+25
It looks like the cleanest method of getting lok_init into a LibreOfficeKitInit.h header (in a c89 compatible way) is to have it as a static function. (inline is only available in C99 or later -- this is actually available on Linux which is the only place that we can actually use lok_init anyways currently, however given we have to keep c89 for the C code (for MSVC) compatibility, selectively enabling c99 would likely be more messy.) Conflicts: libreofficekit/Module_libreofficekit.mk Change-Id: I0493e7a68ed5397479220bb6ba8c3db870b6dd32
2014-07-28LOK: do clean main thread shutdown cleanly.Andrzej Hunt1-4/+8
Change-Id: If44971f67a489f6b50dee6c1683707c47e695de4
2014-07-26Make sure LOK is actually headless.Andrzej Hunt1-1/+12
This prevents e.g. the document recovery dialog from trying to be shown. Change-Id: I253720f7fa1abd1c053670434f8394473517b670
2014-07-26Don't fail on --protector.Andrzej Hunt1-0/+12
If we have any "unknown" command line arguments Desktop init will fail, however our LOK Tiled Rendering test uses Desktop (via soffice_main). (Other unit tests don't use soffice_main hence this check never comes into play.) It looks like it's most reliable simply to ignore --protector here, rather than try to filter it out elsewhere (which is difficult as it is passed to osl via SAL_IMPLEMENT_MAIN). Change-Id: I95d047892851ba2cf9edd2e26bacc6efa0320f71
2014-07-26Don't start Impress Remote server in headless mode.Andrzej Hunt1-0/+15
Change-Id: Ibafe57413a60745e949dc3146fbc843c52c029d6
2014-07-26Use gb_CppunitTest_use_confpreinit for LOK tiled rendering.Andrzej Hunt1-1/+2
Now that we use the event loop for LOK we need to make sure that it is able to run successfully first time, as unit tests start with a completely clean config. Change-Id: If9ddcb75fe8286381d71ecdc76ac7eb3697960d0
2014-07-26Add gb_CppunitTest_use_confpreinit:Andrzej Hunt1-0/+8
For unit tests that use the VCL event loop we can use this to avoid the otherwise required restart. Change-Id: I48265d7e7188a4efaa6f87432c762320331c0c78
2014-07-26Implement lokconf_init.Andrzej Hunt4-0/+85
This is a simple executable which can be used to ensure there is a pe-pared configuration for unit-tests to avoid the usually required re-start on the first run. Change-Id: I49b706e8daa93bc34db508a24615b63b9babddba
2014-07-26Fail LOK initialisation if restart is required.Andrzej Hunt1-0/+9
Change-Id: Ia13a3523666147f002b5a5177fd6962d55556f56
2014-07-26Add OfficeIPCThread::IsEnabled.Andrzej Hunt2-0/+6
This lets us easily check whether Desktop::Main has shut down, i.e. which happens on the first restart-requiring initialisation. Change-Id: I7fe5699a4bf59e2c3b891ac73abd9b147773d22e
2014-07-26Use OfficeIPCThread::WaitForReady rather than sleeping.Andrzej Hunt1-13/+20
This way we actually continue when we're ready to, rather than dumbly hoping we wait for long enough. This isn't entirely unproblematic though -- if we have no config pre-prepared (i.e. first-run), then we just end up hanging on this since soffice_main exits without doing anything to the OfficeIPCThread. (Which is especially problematic for unit tests which specifically run on an empty config.) Change-Id: I064fb500a224cfe37a0d3ba24b6154ffd72a71a3
2014-07-26Bin outdated / incorrect comment.Andrzej Hunt1-4/+1
Change-Id: I7b8f97377b9606a2228f172f772d8051a64703d2
2014-07-26Add OfficeIPCThread::WaitForReady.Andrzej Hunt2-0/+15
For LibreOfficeKit we need to start up the event loop, and can't continue initialisation until all the related (VCL etc.) setup is complete -- the OfficeIPCThread is also enabled as one of the last items, and can be used to indicate whether or not we can start actually working with VCL. Change-Id: I0450b65584ddf6e8d02ce0c6e66e06f47841d1b7
2014-07-26Hack soffice_main into LOK.Andrzej Hunt2-1/+37
Change-Id: I86e13192ddb5904afabca38d3a201f17f145de09
2014-07-26gtktiledviewer: make sure we clean up the office instance.Andrzej Hunt1-0/+4
Change-Id: I12c3e9df8b8fcf8dcd6fb5fa781c2f7c10ab0a0c
2014-07-26drop rtl:: and staticsCaolán McNamara6-27/+27
Change-Id: I6108efad77cf1c21dea3826ae149f3750552b0ed
2014-07-26Related: #i125293# Further corrections for CssStyle handling in SVG importerArmin Le Grand25-136/+279
(cherry picked from commit f00d6d2ea3e73e687edb1da4c32c0960eaf5010b) Conflicts: svgio/source/svgreader/svgnode.cxx svgio/source/svgreader/svgstyleattributes.cxx svgio/source/svgreader/svgstylenode.cxx svgio/source/svgreader/svgsvgnode.cxx Change-Id: I335b292fcdf1ebac925c9fd76ad624efb923447d
2014-07-26We're using the same rectangle for both calls, let's reuse it.Andrzej Hunt1-2/+5
Change-Id: I884832fc92e0fe9c10711d9fdaf103076a05f721
2014-07-26libreofficekit_tilederendering: test all 4 tiles.Andrzej Hunt1-2/+2
The use of VisPortChgd ensures that the tiles all render as expected, i.e. that the pixels match 1:1 irrespective of actual tile size (for identical zoom factors and document areas). Change-Id: Ib1e1df4f8257546c2f7993a8160c309a52037d8b
2014-07-26Tiled Rendering: ensure rendered area is visible correctly.Andrzej Hunt1-2/+8
Using SetVisArea can cause problems due to various internal state getting confused, however this gives correct output without viewport assertion problems or missing content. Change-Id: I8d206ab201167ea96a0ac853187861e8c3d541e5
2014-07-26Revert "Tiled Rendering: ensure rendered area is visible."Andrzej Hunt1-8/+2
This reverts commit ff6a38b76df80d0f907f2f92cb851dea43c91d81.
2014-07-26Revert "CppunitTest_tiledrendering: disable SwVirtFlyDrawObj assert for now"Andrzej Hunt2-4/+1
This is a real problem, which is fixed in a following commit -- tiled rendering does not currently set the viewport at all, which can result in an empty (or otherwise incorrect viewport), so this assert is definitely valid. This reverts commit fb0b42b89af95b42cc6caadf8c22321e5c9386e8.
2014-07-26Massive 'Dialogdiet fail' and similar to 'Dialog creation failed'Matteo Casalin84-225/+225
Change-Id: I6ca6914e80c186699df42253de46a3690c5130f2
2014-07-26sal_uInt16 to short, constifyMatteo Casalin1-2/+2
Change-Id: Id7f6e69aeec4f3ed20611d798214777ca0966a7c
2014-07-26sal_uInt16: avoid temporaries, simplify, constify, use USHRT_MAXMatteo Casalin3-33/+28
Change-Id: Ibfa44aa10d08ac1b19b7d34790f76effc9de0c9c
2014-07-26sal_uInt16: constify and avoid temporariesMatteo Casalin1-8/+5
Change-Id: I27a9b1c9aed70b8b16fd74bf76f5ce1941de0221