Commit graph

8221 commits

Author SHA1 Message Date
Michael Meeks
65540da9dc test: use process groups as well to allow concurrent make checks.
Change-Id: Ib1a55f53c51835a8f9fb1c17146f30e887103906
2019-05-14 21:29:12 +01:00
Szymon Kłos
07f924baf6 loleaflet: Allow to hide dialog
Change-Id: Ieb6ba7e51ad91916e550a529cd94151d062b33d3
Reviewed-on: https://gerrit.libreoffice.org/71549
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Tested-by: Szymon Kłos <szymon.klos@collabora.com>
2019-05-14 22:17:19 +02:00
Jan Holesovsky
40f840a4ab Fix build.
Change-Id: I2196731cf680ae9d466bf243ddbbb6e10da2455c
2019-05-14 10:11:21 +02:00
Samuel Mehrbrodt
9e529e84bf Add UI customizing example to framed.html
Change-Id: I137edcaf9b46f4bff4c30204174215d170abc1eb
Reviewed-on: https://gerrit.libreoffice.org/72241
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-14 08:19:41 +02:00
Samuel Mehrbrodt
0010ca1fb7 Add API methods to hide/show menu bar
Change-Id: I6b0731dbeda29edb311b460e1356fc6b97b9cebe
Reviewed-on: https://gerrit.libreoffice.org/72239
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-14 08:19:30 +02:00
merttumer
0dbf9bcf27 Added RenameFile Support for WOPI
This patch concerns rename file operation when the integration
supports it
Signed-off-by: merttumer <mert.tumer@collabora.com>

Change-Id: Ibb4f615b91dda2491bfcd4d4738198d69eca4e6f
Reviewed-on: https://gerrit.libreoffice.org/71587
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
Signed-off-by: merttumer <mert.tumer@collabora.com>
2019-05-13 22:29:40 +03:00
Szymon Kłos
ded421bfd6 Update WOPI Extensions docs: App_LoadingStatus
Change-Id: I245aec62da3b19e7b81275b0a0a5e84bf0f5b699
Reviewed-on: https://gerrit.libreoffice.org/71958
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Tested-by: Szymon Kłos <szymon.klos@collabora.com>
2019-05-13 13:46:45 +02:00
Michael Meeks
70eb802184 unipoll: remove now redundant SocketPoll parameters.
Change-Id: I8308a0b503db34ac43658a5461005a32132d392f
2019-05-10 18:03:11 +01:00
Michael Meeks
501caaa164 test: better zombie handling for more recent kernels.
Change-Id: I2ae0bcc4c42100ee08ee3fcf68cb7022f38aed7b
2019-05-10 17:38:08 +01:00
Michael Meeks
638fb0316d unipoll: restore missing asserts & some cleanup.
Change-Id: I4277b5e044ead54d91bc834ea05bec649a608678
2019-05-10 17:37:59 +01:00
Michael Meeks
47a0f836dd tests: re-factor PNG save to allow easy re-use elsewhere.
Change-Id: Ic24f67d9a078ae49fa4ac187cc924fe36f482879
2019-05-10 17:37:50 +01:00
Miklos Vajna
eb376d122f Fix recently introduced clang warnings
kit/Kit.cpp:2166:17: error: private field '_socketPoll' is not used [-Werror,-Wunused-private-field]

/usr/lib64/gcc/x86_64-suse-linux/7/../../../../include/c++/7/ext/new_allocator.h:140:22: error: destructor called on non-final 'Document' that has virtual functions but non-virtual destructor [-Werror,-Wdelete-non-abstract-non-virtual-dtor]

Change-Id: I47849db2b0bc64e811577e3a8cede0e2d2c0e2e6
2019-05-10 16:39:10 +02:00
Michael Meeks
73dc711e0a Unipoll: terminate repeated polling loop on wakeup.
Wakeup wakes up the nested SocketPoll::poll nicely, but that's no
use if we immediately ignore that and re-poll, so shorten the
timeout in this case.

Change-Id: I927d2375b92c9ce6c6ebe3f0ab33e2863894e2ef
2019-05-10 15:13:40 +01:00
Michael Meeks
8360f2c951 unipoll: process lots of events at once.
Change-Id: I8b0a37d114a55e5d64d7e5dd7df6c494971087ca
2019-05-10 15:13:40 +01:00
Henry Castro
ee7e1f136a Revert "loleaflet: move jquery.contextMenu.js to loleaflet/js"
This is no longer required because d6fe8ff085

This reverts commit 2ea141c02f.
2019-05-10 10:05:06 -04:00
Michael Meeks
956f8bf5e8 Unipoll: move event processing into the same thread.
Change-Id: I15aff3b5f18201eca915da94dbaa05148026e244
2019-05-10 14:43:27 +01:00
Iván Sánchez Ortega
d6fe8ff085 loleaflet: Make Calc sheet context menu work on iOS safari
This is done with a combination of a 'contextment' event shim in
loleaflet/src/dom/DomEvent.LongTap.js, mimicking the technique from
loleaflet/src/map/handler/Map.Tap.js, and triggering the jQuery
contextmenu manually from such a shimmed 'contextmenu'.

Change-Id: I5cba975b7a5559315c91a8bf4c9a5ced00dfc6e1
Reviewed-on: https://gerrit.libreoffice.org/72115
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Tested-by: Szymon Kłos <szymon.klos@collabora.com>
2019-05-10 12:40:58 +02:00
Michael Meeks
4e1ad1af8d SVG: update for current core.
Reviewed-on: https://gerrit.libreoffice.org/71684
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
(cherry picked from commit f68e68a7b1a6b985f06aff92d95ce178d323e91c)

Conflicts:
	test/data/non_shape_writer_image.svg
	test/data/shapes_writer.svg

Change-Id: Ibb5da2d71ebd68a13b8ccc2a23f891320508f0a5
2019-05-09 15:00:05 +02:00
Miklos Vajna
1d32dc1742 Fix HTTPWSTest::testRenderShapeSelectionImpress() against product core
This test only passed when core.git was built in a way so that '#if
OSL_DEBUG_LEVEL > 0' was true (debug, dbgutil builds). Re-generate this
against a product build, since 2 other tests already have references
like that.

We already have infrastructure for stripping <desc> XML elements from
the actual result.

Change-Id: I9cdd53bf9625266d94313a90946270bfc266bd47
2019-05-09 14:25:21 +02:00
Miklos Vajna
aa5b28ceb0 test: fix HTTPWSTest::testRenderShapeSelectionWriterImage() failure with ...
... debug core.git. Same problem, need to filter out <desc> XML
elements.

Change-Id: I84973b831508e6a073d9c75868307d98a2ada370
2019-05-09 10:40:25 +02:00
Miklos Vajna
0fbabb7a22 test: fix HTTPWSTest::testRenderShapeSelectionWriter() failure with ...
... debug core.git.

SVGActionWriter::ImplWriteActions() in core.git writes additional <desc>
XML elements, guarded with a '#if OSL_DEBUG_LEVEL > 0' block.

Filter these out, so the reference SVG will match both product and debug
builds.

Change-Id: Iba3fb25af206c70d5a4ff5801a934dcfd74704de
2019-05-09 10:30:11 +02:00
Ashod Nakashian
8136bbc1b5 wsd: parse empty json string as empty map
Change-Id: I11335e82e42e9f896ae33c2e57cb9d79b642171e
Reviewed-on: https://gerrit.libreoffice.org/69633
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
Reviewed-on: https://gerrit.libreoffice.org/71097
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Tested-by: Szymon Kłos <szymon.klos@collabora.com>
2019-05-08 20:38:27 +02:00
kaishu-sahu
b67e0d45dd android: resolve the deprecation of PreferenceFragment in DocumentProviderSettingsAcitvity
Change-Id: I736807d6bb47df7b3766a849ce77f87968ebda05
Reviewed-on: https://gerrit.libreoffice.org/71435
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-05-07 17:40:49 +02:00
kaishu-sahu
d50ce4f86c android: replace PreferenceFragment with PreferenceFragmentCompat
PreferenceFragment is deprecated.

Also add debug info option in settings.

Change-Id: I0e55079bc82c85d6ad7ffeb86f821bf7ad07a792
Reviewed-on: https://gerrit.libreoffice.org/71151
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-05-07 17:37:38 +02:00
kaishu-sahu
b33c3f1ffd android: preserve the state of MainActivity upon restart
Change-Id: Ia2956162291c331e1463a1c3267e0698a03e25fa
Reviewed-on: https://gerrit.libreoffice.org/71050
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-05-07 17:34:27 +02:00
Andras Timar
21012c1c74 do not ignore the result of fwrite...
... at least from compiler point of view.
On some systems with old glibc (<= 2.15) the fwrite function has
the warn_unused_result attribute. That makes the build fail.
Starting with glibc 2.16 the attribute was removed [1].

[1]
The bug: https://sourceware.org/bugzilla/show_bug.cgi?id=11959
Release notes to 2.16:
https://sourceware.org/ml/libc-alpha/2012-06/msg00807.html

Change-Id: Ia62ccff2120dce51e311303124aadc60c134a1aa
Reviewed-on: https://gerrit.libreoffice.org/71880
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2019-05-06 23:11:08 +02:00
Szymon Kłos
e62cdfae82 Handle storage load errors
Pass information about storage loading failures
to the wopi host.

Change-Id: I8da3a80e47b15f246343dc8e4199d8f860e1fb8a
Reviewed-on: https://gerrit.libreoffice.org/71354
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Tested-by: Szymon Kłos <szymon.klos@collabora.com>
2019-05-06 14:01:26 +02:00
Samuel Mehrbrodt
203c8be217 Fix admin dasboard after vex update
Change-Id: I302f0213a460cd0dd3d4644373f4b75d4d419696
Reviewed-on: https://gerrit.libreoffice.org/71839
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-06 09:00:10 +02:00
Michael Meeks
264450758a test: close testCrashKit race.
LOOLWSD is conservative and leaves forkit to start processes for a
while. If we kill a kit before it has started and registered we can
end up with LOOLWSD holding off to wait for the (now dead) kit, and
the tearDown assertions that we have 1 kit failing.

Change-Id: Id25e48bf55d1757d2223816293500fde6ff9df1b
Reviewed-on: https://gerrit.libreoffice.org/71811
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-05-05 00:04:00 +02:00
Michael Meeks
92603013de test: recommend --verbose mode, and interleave output chronologically.
Avoids a number of unpleasant attempts to interleave output.

Change-Id: I84b25e338b576d88f7f5fc47fbfcae34c3d377fd
2019-05-04 22:57:00 +01:00
Michael Meeks
2943d09669 test: encourage the test script to sleep for the debugger too.
Change-Id: I538b2d80f57ecc8a342a38a64864d16b9128a04f
Reviewed-on: https://gerrit.libreoffice.org/71804
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-05-04 23:53:38 +02:00
Jan Holesovsky
ec5aec113f Tell the user which link they are about to visit.
Change-Id: Ice177eeda7a11fe20d0188abceee3ef520769bbf
Reviewed-on: https://gerrit.libreoffice.org/71756
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-05-03 16:46:34 +02:00
Michael Meeks
abbe1de459 Update unit test data for recent master.
Also add better printout for unit-client case.

Change-Id: Ic3c5573eab55ad5469adefa5bbfbd6c0e05e571e
2019-05-03 14:04:57 +01:00
Michael Meeks
c08b2f2ba4 Improve pid collection and printout for tests.
Change-Id: I820c1acbdbae41dd2c2c6bb7285b84bbb61e79d5
2019-05-03 13:52:15 +01:00
Iván Sánchez Ortega
e6576f0447 tdf#124749:loleaflet: use "KeyboardEvent.key" to detect ignored key events
Replace KeyboardEvent.keyCode with KeyboardEvent.key for detection of "Delete" and
"Insert" keys. keyCode misbehaves when using an AZERTY/DVORAK keyboard layout, e.g.
the keyCode for "Delete" in QWERTY is the same as "." in AZERTY.

This works on all major browsers, the only outlier being MSIE8:
https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key#Browser_compatibility

Change-Id: I5cbfa18ef59ab4989a866fdf4b5708610beccaad
Reviewed-on: https://gerrit.libreoffice.org/71657
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2019-05-03 13:53:12 +02:00
Alexandru Vlăduţu
ef1669b389 loleaflet: update vex.js library
Change-Id: I6b32c6a60a27aa27eb32784bb73e40c979f67def
Reviewed-on: https://gerrit.libreoffice.org/71726
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-03 12:17:02 +02:00
Henry Castro
2ea141c02f loleaflet: move jquery.contextMenu.js to loleaflet/js
for next patch I require to modify the contextMenu
to trigger on touch start event.

I should do updating archived-packages, but ...

Change-Id: I20f1fbda1e7e60f97cd790c055599edcf8da9d1a
2019-05-02 18:19:59 -04:00
Michael Meeks
8172885f74 PNG compression a bottleneck: thread it to accelerate things.
Also have a separate hash <-> wid cache to avoid re-rendering
older tiles as/when we see them.

Change-Id: I238fe6701a1d1cb486473c67faba8c56e9c98dcb
2019-05-02 22:36:52 +01:00
Henry Castro
9c2ca2d502 loleaflet: makefile: create variable to expand more JS libs
It simplifies and expand more Javascript Libraries to be used in
"loleaflet" bundle

Change-Id: I94aab1989fcef844344a297cd511c796ba642bd4
2019-05-02 15:53:28 -04:00
Michael Meeks
5406a25b24 tests: make SVG comparison tests much more helpful.
Dump the SVG we actually get as a .new file for easy upgrade and
comparison on mismatch.

Change-Id: I607a97ff27a9bf480524efc31877e46d74c5ee3d
Reviewed-on: https://gerrit.libreoffice.org/71681
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-05-02 17:16:08 +02:00
Michael Meeks
95e1034d27 test: help people run just the one that matters.
Change-Id: I1916e250613f8d50377180e38505045f71f51fd0
Reviewed-on: https://gerrit.libreoffice.org/71642
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-05-01 23:14:04 +02:00
Michael Meeks
98fb165c69 Adapt test for new hiddenparts field.
Change-Id: Id2173a38167b97327d0735dfe2a8c88e2dcc4bc7
Reviewed-on: https://gerrit.libreoffice.org/71640
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-05-01 22:56:17 +02:00
Henry Castro
bf3c4c5695 loleaflet: remove GeoJSON.js file
GeoJSON data is no longer used for document tiled rendering

Change-Id: Ic95371947b7e1705ac2431ca06b9a5814d249207
2019-04-29 22:23:18 -04:00
Michael Meeks
685709080d Revert attempts at re-using ostringstream
Cleaning up the thread variable with the shared string stream is
    something of a nightmare, for a rather marginal gain.

    ==9296== Invalid write of size 1
    ...
    ==9296==    by 0x738C092: str (sstream:195)
    ==9296==    by 0x738C092: std::__cxx11::basic_ostringstream<char, std::char_traits<char>, std::allocator<char> >::str(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) (sstream:649)
    ==9296==    by 0x65383A: Log::beginLog[abi:cxx11](char const*) (Log.cpp:141)
    ==9296==    by 0x551823: Admin::~Admin() (Admin.cpp:381)
    ==9296==    by 0x7D9ECF7: __run_exit_handlers (exit.c:83)
    ==9296==    by 0x7D9ED49: exit (exit.c:105)
    ==9296==    by 0x7D86F50: (below main) (libc-start.c:342)
    ==9296==  Address 0x8ba41c0 is 0 bytes inside a block of size 513 free'd
    ==9296==    at 0x4C2FA1D: operator delete(void*) (vg_replace_malloc.c:576)
    ...
    ==9296==    by 0x738784A: ~basic_stringbuf (sstream:65)
    ==9296==    by 0x738784A: std::__cxx11::basic_ostringstream<char, std::char_traits<char>, std::allocator<char> >::~basic_ostringstream() (sstream:591)
    ==9296==    by 0x7D9F27E: __call_tls_dtors (cxa_thread_atexit_impl.c:155)
    ==9296==    by 0x7D9EC0A: __run_exit_handlers (exit.c:41)
    ==9296==    by 0x7D9ED49: exit (exit.c:105)
    ==9296==    by 0x7D86F50: (below main) (libc-start.c:342)

    Good to log during shutdown / exit.

This reverts commit c315d219d5967f23fb1769e78021f61b8f9da6ec.
This reverts commit ce78fec310.

Change-Id: Ia4a15be336d89d8d883530943724d48e4b0ec9fe
Reviewed-on: https://gerrit.libreoffice.org/71444
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-04-27 23:18:11 +02:00
Michael Meeks
c2c5bd0e3e Reset the stringstream properly.
Avoids some N^2 log-line explosion; also make the method name
more findable.

Change-Id: I3ee8c521f1ac98a939cd4d758c720b577d3bfa57
Reviewed-on: https://gerrit.libreoffice.org/71443
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-04-27 23:03:16 +02:00
Tor Lillqvist
f21665f2ac tdf#124981: Fix a few object leaks
The pointer to the DocumentViewController object in the Document class
can be a weak property. This avoids a circular reference.

When the DocumentViewController is being dismissed, remove the script
message handlers and remove the view from its superview. Also, set the
webView property to nil.
2019-04-26 18:04:10 +03:00
Henry Castro
71496cfdb2 loleaflet: add 'paste' event listener to dialog
Change-Id: I2ec69117683e4dd75722b1873a373ee6b7ec7782
Reviewed-on: https://gerrit.libreoffice.org/70961
Reviewed-by: Henry Castro <hcastro@collabora.com>
Tested-by: Henry Castro <hcastro@collabora.com>
2019-04-26 15:36:28 +02:00
Henry Castro
6bb4edd62c wsd: allow paste content to tunneled dialog
Change-Id: I32fabaa533a0e9d853226b329d2d8b1c489dd776
Reviewed-on: https://gerrit.libreoffice.org/70960
Reviewed-by: Henry Castro <hcastro@collabora.com>
Tested-by: Henry Castro <hcastro@collabora.com>
2019-04-26 15:32:58 +02:00
Tor Lillqvist
bf520d5fa5 Log the timestamp of the template file at its site and of its cached version 2019-04-26 12:04:28 +03:00
Tor Lillqvist
db9208d364 tdf#124918: Don't crash on invalid URLs in the template list file 2019-04-26 12:04:20 +03:00