Commit graph

8199 commits

Author SHA1 Message Date
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
Tor Lillqvist
d550944053 tdf#124918: More logging in template download error situations 2019-04-26 12:04:09 +03:00
Tor Lillqvist
4e2ad4d2bc tdf#124918: Allow empty lines in the template list file 2019-04-26 12:04:01 +03:00
Tor Lillqvist
4247dad6f5 tdf#124950: Don't pop up keyboard on iOS when clicking in toolbar 2019-04-25 17:29:01 +03:00
Tor Lillqvist
981db95a28 tdf#124950: Don't pop up keyboard on iOS when clicking the mobile-edit-button
Only when the user taps in the document, or selects some text in it,
is it obvious that they want to be able to type into it.

This is just one of the instances where the on-screen keyboard popped
up for no good reason.
2019-04-25 17:27:30 +03:00
Tor Lillqvist
05e4cf90f9 Remove leftovers of loading.html from iOS app project, too
Change-Id: Iecbbbc8ea42c0e26e6dde3f38a57482ad60135d5
2019-04-25 17:25:15 +03:00
Henry Castro
a97b592b30 loleaflet: validate that the rectangle coordinates (x, y) belongs to ZxZ
Change-Id: Ibbb1cf1416ec441f1e3d4baaf6fdf6f47ab6041c
Reviewed-on: https://gerrit.libreoffice.org/71150
Reviewed-by: Henry Castro <hcastro@collabora.com>
Tested-by: Henry Castro <hcastro@collabora.com>
2019-04-24 16:05:10 +02:00
Henry Castro
e7d3e5e37f loleaflet: enable Conditional Formatting dialog
This reverts commit b3532ebb828035dc9db8c027472bd050494fce3c.

Change-Id: Iac31520b1444832059c99e0bfb52eb99d1fd91ca
2019-04-24 10:02:06 -04:00
Tor Lillqvist
824834dfa8 Turn on Unipoll for the iOS app, too
Change-Id: Ib0b7ac53b7c936e75446004c4581ace415b1dd5c
2019-04-24 13:24:53 +03:00
Szymon Kłos
dfd22ba35c Show progressbar centered in the mobile
When Online was embodied in the nextcloud app (Android)
the progressbar was moved into top-left corner.
During a loading all functions to get container
or browser size were returning (0,0).
This hack assumed that webview size is almost equal
to the mobile screen size.

Change-Id: I0fff53639a3baa88b57d91bf671e00ad8c71180d
Reviewed-on: https://gerrit.libreoffice.org/71117
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Tested-by: Szymon Kłos <szymon.klos@collabora.com>
2019-04-23 11:59:45 +02:00
Andras Timar
92562991bd change default HelpRootURL to 'https://help.libreoffice.org/help.html?'
Change-Id: I6463ad84b5c0df2860504f4e51f87b5537107f42
2019-04-23 10:05:05 +02:00
Miklos Vajna
fdc731a07d gtk: fix typo
Change-Id: Ib8bcf8b578f1d926f26a0ebae15cfa36e5d922d2
2019-04-23 09:10:18 +02:00
Ashod Nakashian
69995fa0f1 Move the Help URL to a new config path
Change-Id: I76468d1c032689099b371449aedc0e5583f0ae2d
Reviewed-on: https://gerrit.libreoffice.org/69107
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/71087
2019-04-23 07:47:04 +02:00
Ashod Nakashian
e8bcf06330 Add help URL to loolkitconfig.xcu
When blank the help button is hidden from
all dialogs.

Change-Id: Ibd43411bed496bfd3bc81056ebc8657fb77fb8fe
Reviewed-on: https://gerrit.libreoffice.org/69072
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/71086
2019-04-23 07:46:46 +02:00
Ashod Nakashian
4f4bcbc982 leaflet: do not disable the Close Document menu for read-only docs
Change-Id: I6a52b0bd807ae68ea6bf59e103c004375afae50b
Reviewed-on: https://gerrit.libreoffice.org/69110
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/71088
2019-04-23 07:46:22 +02:00
Tor Lillqvist
ede2c3432f tdf#124235: Fix the same problem on all platforms the same way
Change-Id: Ie7ede59841898a0738af7e44a3c0fe89db1cd3ee
Reviewed-on: https://gerrit.libreoffice.org/71023
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2019-04-23 04:52:05 +02:00
Ashod Nakashian
83a73e24e0 wsd: set the language when creating a new view
This uses the new createViewWithOptions API to
set the language of the user at the point of
creating a new view.

Change-Id: Ibf3e0af1b0cc300126388c1217692d8d969be0f3
Reviewed-on: https://gerrit.libreoffice.org/67501
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2019-04-23 03:44:07 +02:00
Ashod Nakashian
ca1a83f96b wsd: reduce tile logging from debug to trace level
These are very frequent and not very useful without
the ability to trace them across the system, which
are all done at trace level. So it's highly unlikely
that these would be used at debug.

Change-Id: I479f2ead1bbd2996b9972082e00ebf984072f785
Reviewed-on: https://gerrit.libreoffice.org/71073
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2019-04-23 03:02:36 +02:00
Ashod Nakashian
2ec5023dbf wsd: assert on 0-sized tiles
Change-Id: I10a20bb5a3ad31e368f554bdc5e1701a7ff6a22d
Reviewed-on: https://gerrit.libreoffice.org/71072
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2019-04-23 03:02:09 +02:00
Ashod Nakashian
c45dfe194b leaflet: process the most common message first
The 'tile:' message is the most common and most
latency sensitive message, so give it priority.

Change-Id: Id5790369cd493423a47acab8a3d5107ce91b0d39
Reviewed-on: https://gerrit.libreoffice.org/71071
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2019-04-23 03:01:46 +02:00
Ashod Nakashian
c7ac68e8e3 wsd: tile serializer now supports adding a suffix
Moves appending tokens into the serializer and
avoids making extra copies of itself.

Change-Id: I62d374e69d9c4a55643ea20cb5f8c2b9c75c88c5
Reviewed-on: https://gerrit.libreoffice.org/71022
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2019-04-23 03:01:30 +02:00
Ashod Nakashian
c053dc38b2 wsd: set vector size when constructing
Change-Id: I68718554017b47b6df1c6bf3b997483d4c753136
Reviewed-on: https://gerrit.libreoffice.org/71021
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2019-04-23 03:01:17 +02:00
Ashod Nakashian
ce78fec310 wsd: reuse ostringstream when logging
This is faster and reduces memory fragmentation.

Also, cleans up the logging macros and implementation.

Change-Id: I7fb00da041d1261c694c4b48b67a3c66ad0cbf8d
Reviewed-on: https://gerrit.libreoffice.org/71020
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2019-04-23 03:01:00 +02:00