Commit graph

8267 commits

Author SHA1 Message Date
Michael Meeks
4f804a48fe Initial HTTP Expect: 100-continue implementation.
Change-Id: Ic9aa59cac5103151d91f6eb59d12313e545c7916
2019-05-22 02:56:11 +01:00
Michael Meeks
1845ed42af tdf#123482 - cleanup convert-to folder even more reliably.
Problems could occur if exceptiosn thrown when parsing the input stream.

Change-Id: Id82b3816450194164fc2093554c730b4a94acef1
Reviewed-on: https://gerrit.libreoffice.org/72695
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-05-22 01:57:48 +02:00
Samuel Mehrbrodt
1dbbc5acc7 Change package name to "libreoffice-online" instead of "loolwsd"
The name on master is "loolwsd" while the official relase branches
(libreoffice-6-2 e.g.) have "libreoffice-online".

This leads to various issues, e.g. some scripts expect the config files
to be in /etc/loolwsd while changing the name also changes that folder name
to /etc/libreoffice-online.
So at least docker builds from the release branches don't work.

The package name should be consistent, either we use "libreoffice-online"
on master also, or we change the release branches to also use "loolwsd".

My preference is to have "libreoffice-online" as the name. "loolwsd" is an
internal term and hard to associate with LibreOffice online for "outsiders".

Change-Id: I1b1efda2fa6083f1a0d211fd73f1fa062f3286cc
Reviewed-on: https://gerrit.libreoffice.org/72590
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-21 17:29:15 +02:00
Tor Lillqvist
936f3a1435 tdf#125410: Handle pasting of text/plain strings into the iOS app
Also, initialise this._keyHandled as true in L.Control.MobileInput, as
that is the value it has between key event sequences, so presumably it
should be so before the first key is hit, too.

Change-Id: Ie67e9fcdd14871e76f9d9487c14f03ae54476e60
2019-05-21 16:05:57 +03:00
Florin Ciornei
0297c42549 android: Send a BYE signal when stopping.
This triggers the save-on-exit operation.

Change-Id: Ibf76ca5a5e87906e6abbc9d8ae17871ec4d5d11a
2019-05-21 11:55:48 +02:00
Jan Holesovsky
11000f11f0 android: Logging must be initialized only once, otherwise it crashes.
Change-Id: I78d5f03951bef5603f0e84d992e656c222a1416e
2019-05-21 11:31:28 +02:00
Jan Holesovsky
aa33301997 android: Update to a newer gradle.
Change-Id: I5eec51a8531ab763634aa78ef80b2fc1964444ac
2019-05-21 11:30:56 +02:00
Miklos Vajna
73108db913 wsd: fix -Werror,-Winconsistent-missing-override
Change-Id: Ide9921e410a8e1401a25b85fda04de1b5a45617a
2019-05-21 09:13:13 +02:00
Miklos Vajna
6fb9fcceca Disable HTTPCrashTest::testBarren() for now
Till it's clear how to fix it, so 'make check' keeps passing, without a
second consistently failing test appearing.

Change-Id: I80a1ebd2b1264819c3e98f816b4c13984b961fbb
2019-05-21 09:10:40 +02:00
Tor Lillqvist
b5154eaf69 Make the document-specific threads in the iOS app go away more reliably
After a document is closed, the prisoner_poll, accept_poll,
websrv_poll, docbroker_nnn, and lokit_main threads that served that
document are supposed to go away as quickly and reliably as possible.
This change improves that significantly.

Change-Id: If658bea74f70a77d2d537f0ec6455a6b36f2667e
2019-05-21 02:40:28 +03:00
Michael Meeks
4e7f8b6e00 Remove vestige of legacy sockets.
Change-Id: I5c2175e95144b7e93eafce2a273ed5f3549850bb
2019-05-20 21:32:59 +01:00
Andras Timar
157e4bd680 loleaflet: updated pot files
Change-Id: I746741e060c9e995c58fd67a9542577231cf31ae
2019-05-20 22:02:07 +02:00
Jan Holesovsky
aa1d9ce196 The Internal Copy / Internal Cut / Internal Paste is just confusing.
Every user so far is confused of the existence of two clipboards - the
system one, and the Online internal one.

We are able to detect that the copy / paste is happening inside the
document and perform the "internal copy / paste" accordingly, so let's
do what the other online office suites do, and just warn when the user
tries to access copy / paste from the menu.

Change-Id: I904fc120fcf65b8ad4ba8fb5178803f976d707f4
Reviewed-on: https://gerrit.libreoffice.org/72614
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2019-05-20 21:50:30 +02:00
Tor Lillqvist
058b68fc3e tdf#122281: Prevent the WebView from scrolling
It is presumably possible to do it in the JavaScript, too, and then
the same problem would go away for normal Online viewed in Mobile
Safari, too. But I couldn't figure out how. Googling turned up various
advice that suggested using '-webkit-overflow-scrolling: auto;' for
the body of the page but it didn't seem to help. (I tried adding that
to the style attribute of the body element in loleaflet.html.m4.)

Change-Id: Iac3487a73eca218130583dde9decdb89c316c1fc
2019-05-20 16:25:52 +03:00
Tor Lillqvist
a31c7c851c Add some more core source files from sfx2/source/view
Change-Id: I3e7183ecea24ee0282cbd6fa6ad7d457fa5a781c
2019-05-20 16:25:52 +03:00
Michael Meeks
046ab32e46 Use compile-time rather than run-time string concatenation.
Saves some time & space.

Change-Id: If1e62056447fb7e8f26e8cf107451876adf3fecb
2019-05-20 12:30:01 +01:00
Tor Lillqvist
8c15d4f938 tdf#124906: Hack for dead keys in iOS app and iOS Safari against Online
Handle key events fairly separately for the iOS app and Mobile Safari
than for other mobile platforms. Use the key property of the keypress
event and avoid looking at the keyCode property of keyboard events.

There is still one problem left: After typing the dead key, it is not
displayed temporarily "waiting" for the following letter, as it
should. But that didn't work before either in the iOS app, as far as I
see.

Change-Id: I9df174ba294f855697df59dd016b39cd1b3d905b
2019-05-20 13:20:06 +03:00
DarkByt31
8e34705fe2 tdf#107038 Poco::DateTimeFormatter with Util::getHttpTimeNow()
Added a function to Util to get current time in HTTP
format using std::chrono.

Change-Id: I9e7a732f585c1758c9348c450a01713a66f1e7b7
Reviewed-on: https://gerrit.libreoffice.org/72585
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-05-20 11:53:13 +02:00
Marco Cecchetti
502dc97cb2 lok: update graphic selection callback description
Change-Id: Iebc3d17ac8e81ea99dda64cd97807656f5941637
Reviewed-on: https://gerrit.libreoffice.org/70574
Reviewed-by: Marco Cecchetti <mrcekets@gmail.com>
Tested-by: Marco Cecchetti <mrcekets@gmail.com>
2019-05-20 10:40:05 +02:00
Marco Cecchetti
ba4cd1563d loleaflet: constrained dragging for pie segment
The extra information for the graphic selection is now formatted
according to JSON syntax so that is easier to parse.

Dragging a pie segment now is constrained as on desktop and there is
also a preview of the pie segment while it is dragged.

On drag end a msg is sent to core with the new pie segment offset
from the pie center, which allows core to move the pie segment to
the correct position.

Change-Id: I7f76d21d622006fca5d0922c5932daec50b13836
Reviewed-on: https://gerrit.libreoffice.org/70573
Reviewed-by: Marco Cecchetti <mrcekets@gmail.com>
Tested-by: Marco Cecchetti <mrcekets@gmail.com>
2019-05-20 10:39:52 +02:00
Marco Cecchetti
88e941c659 loleaflet: exploiting new selection handling properties
We use the new information sent by core through the graphic selection
message, for showing only the meaning handler for the current selected
object.

Change-Id: I20a2d59583b89701b0f61c27c469fa916eabe20a
Reviewed-on: https://gerrit.libreoffice.org/70572
Reviewed-by: Marco Cecchetti <mrcekets@gmail.com>
Tested-by: Marco Cecchetti <mrcekets@gmail.com>
2019-05-20 10:39:40 +02:00
Marco Cecchetti
d3f8982944 leaflet: after resizing a shape, dragging cursor with mouse pans view
The problem was in Path.Transform._apply executed at scale/rotate end
which enabled map dragging unconditionally.

Change-Id: Id42dc7de397a2ca2774f9d31a698c32b5e1c8514
Reviewed-on: https://gerrit.libreoffice.org/70571
Reviewed-by: Marco Cecchetti <mrcekets@gmail.com>
Tested-by: Marco Cecchetti <mrcekets@gmail.com>
2019-05-20 10:39:25 +02:00
Marco Cecchetti
3c3770e370 loleaflet: correct resize of rotated images in Writer.
A new format for selection extra properties has been introduced:
"x, y, width, height, angle, { property=value, ... }"

Change-Id: Ic03dbaba0af1b5c84bcd0f02587e907e799f66d8
Reviewed-on: https://gerrit.libreoffice.org/70570
Reviewed-by: Marco Cecchetti <mrcekets@gmail.com>
Tested-by: Marco Cecchetti <mrcekets@gmail.com>
2019-05-20 10:38:55 +02:00
Samuel Mehrbrodt
f5954a015b Browsersync: Also sync html files
Change-Id: I55db923954fc0c59e1726640c980a539a12293ba
Reviewed-on: https://gerrit.libreoffice.org/72455
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-20 09:59:45 +02:00
Samuel Mehrbrodt
e23ea28621 Reference: Add heading markup to headings
Change-Id: I426a49a17488b88924845fefb549126844c962a2
Reviewed-on: https://gerrit.libreoffice.org/72448
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-20 09:59:34 +02:00
Samuel Mehrbrodt
433f66ca8b Improve formatting: Add some linebreaks
Change-Id: I1e7fde64d84690cf8cb3e16d4ddd0baba3917151
Reviewed-on: https://gerrit.libreoffice.org/72447
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-20 09:59:23 +02:00
Samuel Mehrbrodt
e45f7998dc Insert_Button: Add parameter to specify insert position
Change-Id: I362f4c67506c1e98c47d7bd55127ded63758c334
Reviewed-on: https://gerrit.libreoffice.org/72446
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-20 09:59:13 +02:00
DarkByt31
a243fdef88 tdf#107038 Poco::Timestamp replacement with std::chrono
Change-Id: Ic577d304f2152c53895f4602cf55a98dd1e63ed0
Reviewed-on: https://gerrit.libreoffice.org/72531
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-05-18 23:42:14 +02:00
Michael Meeks
8be093ed67 Tolerate empty first lines.
Change-Id: Ib9aaf82560fc3f5adaa97f40a3de5f3946c6f65d
2019-05-17 14:27:47 +01:00
Samuel Mehrbrodt
8d359cedbe Statusbar search: Placeholder instead of label
Matches the desktop layout and reduces clutter

Change-Id: Ibbee6206281b37bbd9acaad23778389a20fe883f
Reviewed-on: https://gerrit.libreoffice.org/72466
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-17 14:38:28 +02:00
Michael Meeks
d8bcc1cf9c debug: cleanup ID display as a simple link.
And cleanup debug printout in 'make run' too.

Change-Id: I7a399eb00f15e43ceb230f66a2b17d437c5c79b0
2019-05-17 13:24:32 +01:00
Michael Meeks
289894c66c debug: show WebSocketURI & a unique host id in help -> about.
Rather useful for debugging clustering issues.

Change-Id: I6d5f224bf8a3e4034c419137c8ad2b17fdf265ed
2019-05-17 13:24:32 +01:00
Michael Meeks
1955287013 debug: dump content of paste messages.
Problematic not to be able to see the content, helps hunt weirdness
in eg. pasted RTF.

Change-Id: I301bfe040a2424b6ca84ab94b8eee865439fb680
2019-05-17 13:24:32 +01:00
Jan Holesovsky
85b2bd3ab2 Prefer HTML over RTF for pasting on the Mac.
Safari provides RTF clipboard content which doesn't contain the images.
We do not know where the content comes from, so let's always prefer HTML
over RTF on Mac.

Change-Id: I2f449ff4cf025e5f51dbe6e0683667f2d319ac21
Reviewed-on: https://gerrit.libreoffice.org/72461
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
(cherry picked from commit 2998ab914e057d5c9bae3e3b03c0cf5f13e531b9)
Reviewed-on: https://gerrit.libreoffice.org/72465
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-05-17 14:11:32 +02:00
Jan Holesovsky
8aea4599e2 git-review: Use the hostname instead of alias.
Change-Id: Iaf7ea129e7fec3201af68107d327acc902a5b9d6
Reviewed-on: https://gerrit.libreoffice.org/72462
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Miklos Vajna <vmiklos@collabora.com>
(cherry picked from commit 1bf8e78cac760dc0100012ca72488a18af0a6d20)
Reviewed-on: https://gerrit.libreoffice.org/72464
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-05-17 14:10:33 +02:00
Samuel Mehrbrodt
6cd248a29c Remove obsolete comment
Change-Id: Ie2034737461d4dd9c42f31a9968e8109bfd87488
Reviewed-on: https://gerrit.libreoffice.org/72445
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Tested-by: Tor Lillqvist <tml@collabora.com>
2019-05-17 12:24:40 +02:00
Alexandru Vlăduţu
60dca5cf5e loleaflet: minor followup changes after vex upgrade
Change-Id: I9cee6ee5b0592f067718399a4ccaf1c25203c01c
Reviewed-on: https://gerrit.libreoffice.org/71851
Reviewed-by: Iván Sánchez Ortega <ivan.sanchez@collabora.com>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-16 16:12:27 +02:00
Tor Lillqvist
8ffd192856 Add also DocumentBroker.hpp for breakpointing convenience
Change-Id: I16e81ea16ad332b72f5af0df91c0249b5a2984f1
2019-05-16 14:59:41 +03:00
Iván Sánchez Ortega
5f79f5d894 loleaflet: Background color for Calc
This adds a new L.Layer, L.CalcBackground, which reacts to 'statechange' websocket
messages, and sets the background style of the Leaflet container to match
the color of the current Calc sheet.

Change-Id: I33d39c86fb52708419756b85660d7be450c91eba
Reviewed-on: https://gerrit.libreoffice.org/71995
Reviewed-by: Iván Sánchez Ortega <ivan.sanchez@collabora.com>
Tested-by: Iván Sánchez Ortega <ivan.sanchez@collabora.com>
2019-05-16 12:21:35 +02:00
Tor Lillqvist
d9e5a47058 Introduce new flag to speed up shutdown of the Online plumbing in the iOS app
Spent hours on trying to cleverly use the existing TerminationFlag
(with minor modifications to the code that checks it, and some
additional code to set and reset it), but could not get it to work.
This is simpler, but sure, using a global variable is ugly of course.
At least the new MobileTerminationFlag is very specific in semantics
and only used in the mobile apps.

Change-Id: I0775fdfa7880750ca12c6fd7ec41d3d3ceb2f0ad
2019-05-16 11:44:41 +03:00
Tor Lillqvist
ebda7c6b8b Use same kind of thread id as Xcode and osl_getThreadIdentifier() on iOS
Reduce the number of different kinds of identifiers for threads that
are displayed in various places. Use the number that you get with
pthread_threadid_np(), in hex, which is the same that Xcode (i.e.
lldb) displays in its "thread list" command. It also is the same
number that osl_getThreadIdentifier() returns.

Change-Id: I0c14ad99badd7e742d15b7d1f37037fa66c892b4
2019-05-16 11:42:19 +03:00
Tor Lillqvist
d59956aa3d Use consistent terminology in LOG_INF() calls around runLoop() call
Change-Id: I46d954250447dea6ffa60c6e0e341f23a9ad4ff9
2019-05-16 11:41:56 +03:00
Tor Lillqvist
8ae35c6348 No need to call Log::shutdown() in a mobile app
The process never exists voluntarily. It is killed by the OS when
inactive and its resources are needed.

Change-Id: I9a7fa8200a44bba8dfcd2b09882f1b87814025be
2019-05-16 11:41:08 +03:00
Tor Lillqvist
32c1dd0a5d Add more core source files for breakpointing convenience 2019-05-16 11:39:32 +03:00
Tor Lillqvist
420bedaadc Edit ios/README
Point out that in my way, you will (sadly) need GNU libtool for the
running of the autogen.sh script, even if not actually at all
otherwise.

(We should really try to get rid of the need for libtool. A minor
amount of hacking to loleaflet/Makefile.am should be enough.)
2019-05-16 02:17:54 +03:00
Samuel Mehrbrodt
50e5690d30 Simplify code
Change-Id: Ifc3a04c38b6449ef289f8092e8be6cee3b5865c3
Reviewed-on: https://gerrit.libreoffice.org/72275
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-15 07:25:39 +02:00
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