Commit graph

8487 commits

Author SHA1 Message Date
Iván Sánchez Ortega
8440e286cb Calc: Update clipboard container only on 'celladdress', not 'cellformula'
Change-Id: I5e3f4eb56447060a54751172bd9d891c88a593fe
2019-08-05 19:23:07 -04:00
Michael Meeks
8c80c08729 Add clipboard debugging to our options.
Change-Id: If0e0ced9d9a6e44cc7ba5f390604cc10fd869a52
2019-08-05 19:21:13 -04:00
Marco Cecchetti
3c3a3ee204 loleaflet: copy/paste: upload widget and cross copy/paste widged
Change-Id: I9042b8263d9af51897ed7ba7488fe6399561b965
2019-08-05 19:15:36 -04:00
Marco Cecchetti
fdc5d259ea loleaflet: download widget skeleton for larger copy/paste data operation
Change-Id: I64d8edc014241e94c45677185a935714b8eeb192
2019-08-05 19:15:28 -04:00
Szymon Kłos
94b80a5f13 Add copy paste warning also in mobile
Change-Id: I00357d432ad6d4a05be6494a8bb058dd1793a5ff
2019-08-05 17:06:45 -04:00
Jan Holesovsky
14fa2dd346 Make the (JS) context menus work again.
This was removed by mistake, and caused that no .uno: command was ever
sent to the core.

Change-Id: Iecf050f09bc2a22b936abf49315d4a9d0fbb364a
2019-08-05 17:06:37 -04:00
Michael Meeks
75925bb53d Don't disable Paste based on incorrect server side data.
Leave it always enabled.
2019-08-05 17:04:34 -04:00
Michael Meeks
f2478adb44 Restore Copy/Paste context menus and use execCommand to do it.
Move the warning dialog to the Clipboard helper for now, and show on
failure.

Change-Id: I073248e8959d20b12bc6d3dafd5e81287f759862
2019-08-05 17:04:09 -04:00
Jan Holesovsky
a636f4e91c 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
2019-08-05 17:01:57 -04:00
Michael Meeks
8c1f97a92d Work around Safari behavioral difference with contenteditable. 2019-08-05 16:57:39 -04:00
Michael Meeks
52e477e57e Switch to text/html for paste where we can.
Build special URLs to detect the same host being in-use, and much more.

Change-Id: I0ca639ea416cb78bf5e5274eac4400542b6b2cda
2019-08-05 15:47:47 -04:00
Miklos Vajna
003c98ff93 fakesockettest: respect CPPUNIT_TEST_NAME
This was running unconditionally.

Change-Id: I3de4241230d0f06f7836756e2d9b7fdf84d3477f
2019-08-02 09:57:20 +02:00
Miklos Vajna
773080eb74 Fix failing HTTPWSTest::testInactiveClient()
It seems to me that in this case the test was poor, if other
invalidation types are expected, then this one should be fine, too.

Change-Id: Iae7597eef081acdfb5d6f9152747204a71bd2b66
2019-08-02 09:35:20 +02:00
Samuel Mehrbrodt
119eb7b86f Remove space below ruler
This breaks cursor positioning with the mouse.

Was introduced with 0576a3cced

Change-Id: I85abca224d2bc9d365443bd87c6793db1900e2a4
Reviewed-on: https://gerrit.libreoffice.org/76578
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-07-30 09:27:45 +02:00
Tomaž Vajngerl
42c4c864fe tdf#125425 add cell selection markers and cell auto fill marker
This replaces the standard text selection marker with a cell
selection markers to resize the cell selection. This looks and
behaves better for cells in Calc and it is also easier to deal
with.

Additionally add auto fill marker to perform the auto fill action
on the cells. This was not possible to do previously unless you
hit an invisible part of the cell selection, which is not
convenient when using touch.

Change-Id: Ia02d03b7b8e8d98412ea98eb92fb47d1505ef979
Reviewed-on: https://gerrit.libreoffice.org/76494
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
2019-07-29 08:51:55 +02:00
Michael Meeks
f2c6facb29 Don't combine tiles a long way from each other.
We currently combine only horizontally, but ctrl-right arrow in
calc can throw us to the other side of the sheet, creating a very
large area to re-render.

Change-Id: I7125ab815e3de1296b3af32632626005eeee0ec9
2019-07-26 10:12:00 +01:00
Jan Holesovsky
82bcd8db73 Add a comment where the HULLO response is handled.
Useful for git grep HULLO :-)

Change-Id: Ia7696f91f6452aaab6df95b640ac361b4904d4b5
Reviewed-on: https://gerrit.libreoffice.org/76300
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-07-25 13:03:09 +02:00
Henry Castro
393db38ce2 kit: take ownership when saving a document template
Otherwise, it causes error log:
ERR  Cannot save docKey [/filename], the .uno:Save has failed in LOK.

Change-Id: Ic99807848def72f76471c4f999ebeed9a7c0a2c8
2019-07-25 07:59:24 +02:00
Jan Holesovsky
635f0627f2 Fix build.
Change-Id: I3e7dc00a8acdaf0ad1a07c0cd55ff7bff7b64295
2019-07-25 07:58:19 +02:00
Henry Castro
760864870f wsd: introduce "TemplateSource" WOPI property
Change-Id: I9df1d5d0d4be7fe10ee15c40c36195c86ccf857e
Reviewed-on: https://gerrit.libreoffice.org/76190
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2019-07-24 12:10:15 +02:00
Tor Lillqvist
f7a70ba9d3 tdf#125681: Get rid of ChildSession::getDocumentMutex() and associated code
Now with the "Unipoll" concept all this locking is unnecessary as the
kit process is single-threaded, and actually it is harmful as the bug
shows.

Michael explains in chat:

But in fact - we should be a single threaded kit process there now. We
are protected by the solar-mutex (which is recursive) while our
locking is not. This was the whole point of the Unipoll refactor: to
remove the extra threads, complex queues, etc. etc. I just left the
mutexes. Even a recursive mutex won't work there; since it needs to be
drop-able and transferable to another (LOK internal thread) in Yield,
so - we should remove them.

Change-Id: I7d1e1dfb0e20f14134be5f81da057539b0f86ab9
Reviewed-on: https://gerrit.libreoffice.org/75849
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-07-24 12:09:24 +02:00
Samuel Mehrbrodt
3dd8364056 Font list empty in some cases
The list of font sizes was taken from the font info. This causes
problems when the document uses a font which is not available on the system.

As there is no obvious reason, why the list of font sizes should depend on the font
(and update with every font change), remove this dependency and just populate
the list of fonts once.
If the document uses a font size which is not in the list, it still will be added to
the font size list.

Change-Id: I4d434244b341c8e782138e5a6df85a50ddad3df5
Reviewed-on: https://gerrit.libreoffice.org/75959
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-07-24 07:43:17 +02:00
Jan Holesovsky
68b33ba7f2 android: Load the document only after we've got the permission.
Without this, the first start was failing, there was only a black screen
and the request for permission.

Change-Id: I7929048ca51b044dcb574f48bd2b7bc9a27e0ec8
2019-07-23 14:20:25 +02:00
Jan Holesovsky
1d549fa9dd android: Obviously we need to request for writing, not only reading.
Change-Id: I68927593bd17a6ee6de0c1d879d6b05372c1350e
2019-07-23 12:40:09 +02:00
Jan Holesovsky
a04ed68104 android: No need for the extra wrapper, use the LOActivity directly.
Change-Id: Ie4afaedcc3b255c83c570acea02101d284e85653
2019-07-23 12:40:09 +02:00
kaishu-sahu
73f839164a android: add cut, copy, paste support to document viewer.
Change-Id: I85c3a602ab7e98272a193c392bf7bcfd1050dc90
Reviewed-on: https://gerrit.libreoffice.org/74127
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-07-22 12:03:09 +02:00
kaishu-sahu
f5a67c696d android: fix keyboard popping out on clicking edit button.
Change-Id: I619955a38998ce4091e7d432b989ef487a928a69
Reviewed-on: https://gerrit.libreoffice.org/74720
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-07-22 10:10:43 +02:00
George
360d5a0956 added server uptime field to admin console
Change-Id: Id23fee1299b87095f186ce7aaa8c2d2e0f3cef52
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2019-07-19 21:14:01 +01:00
Jan Holesovsky
2f7fac7547 android: Fix the LOActivity lifecycle in several ways.
First of all, we shouldn't destroy the document in onStop(), instead do
that in onDestroy().  onStop() should only (auto-)save the document, but
otherwise keep it open, so that when we return from the file picker
Activity, the caret is at the same position as it was before.

In addition to that, we should close any open document before we try to
open the new one (in createLOOLWSD).

And finally, when closing the document, we should wait until after the
LOOLWSD is completely torn down, so that we avoid the risk that the user
tries to load another document too quickly, and the messages from the JS
go into the old, still running LOOLWSD.

Change-Id: Ib775021bccc5d5bc69aae392a88dc62a7c05a8fa
2019-07-19 17:59:06 +02:00
Jan Holesovsky
155718796e android: Fix a threading / ordering issue.
Sometimes when closing & reloading a document, the JS ended up with:

cmd=/storage/0/...document_name... type=unknown

error.  The problem was that the HULLO response came later than the next
message in the queue which was

loolclient 0.1

So LOOLWSd tried to load the document called "loolclient 0.1", which
failed, and then it did not know what to do with the "/storage/0/..."
which it understood as a command.

Seems we don't need to send the stuff from a thread on Android, so let's
avoid that, instead of setting up another sender queue here.

Change-Id: I96b4ad13153f1cad6aeb7fc71efcb402edbdc6d2
2019-07-19 17:58:58 +02:00
kaishu-sahu
89a8ce6009 android: add insert image feature to document viewer
Change-Id: I19cb8ef93606cf1bba7341f0d258487b604ad10e
2019-07-19 17:58:49 +02:00
Samuel Mehrbrodt
ec56d52f61 Fix tooltip for "BackColor"
Change-Id: Ic7c41851e79bb74e6080795fe4823cc637047bfe
Reviewed-on: https://gerrit.libreoffice.org/75868
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-07-19 13:06:18 +02:00
Samuel Mehrbrodt
15e2e91fc7 Add API methods to hide/show ruler
Change-Id: I4d14d9d68e7ebda56c80a1ad678a21c67ffd5ac2
Reviewed-on: https://gerrit.libreoffice.org/72265
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-07-16 09:11:21 +02:00
Jan Holesovsky
397e7236c9 android: Issue an error message when the document cannot be loaded.
Instead of keep spinning the spinner, show an error message.

Relevant for iOS too I guess.

Change-Id: I9fb45a1808a12e133bc2548c4cf07c1ba8bb629f
2019-07-15 20:18:09 +02:00
Jan Holesovsky
fd4d896a7f android: Rename the .xml files to avoid potential conflicts.
Change-Id: I6209309c038f16aff150494adf14953aa6f31541
2019-07-15 19:41:44 +02:00
Henry Castro
41c6d402f4 loleaflet: mobile: enable graphic dragging
Change-Id: Ia6ef34ff99891ad249d6f7aa6ed5915723d1013b
Reviewed-on: https://gerrit.libreoffice.org/75619
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
2019-07-15 11:31:22 +02:00
Marco Cecchetti
c72e68154f loleaflet: mobile enable tripletap for opening links
Change-Id: I9bcf7dfda7984b51f7be4c195496a892046077bc
Reviewed-on: https://gerrit.libreoffice.org/75618
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
2019-07-15 11:31:13 +02:00
Szymon Kłos
02be8f962d Increase selectable cell area
Change-Id: If9ca302253369bfa5708097106507e8f3d8d398b
Reviewed-on: https://gerrit.libreoffice.org/75617
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
2019-07-15 11:31:03 +02:00
Jan Holesovsky
2b13c69d75 android: Split the actual editing Activity into an own library.
This way, it is more naturally visible what is the actuall app (with the
initial recent documents / file picker) and the editing part.

Change-Id: Ia764f2900939e980f703e3da9f9abd6c0aee7cbb
2019-07-12 11:52:56 +02:00
Florin Ciornei
fa6e1054a9 Set focus on document after closing copy/paste/cut warning.
Change-Id: I4e241278bea441f77e6b7780d69e540f9e6d4771
Reviewed-on: https://gerrit.libreoffice.org/72838
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
(cherry picked from commit 79468654f54358c77ee8240053cccdd69fc055b3)
Reviewed-on: https://gerrit.libreoffice.org/75435
Reviewed-by: Aron Budea <aron.budea@collabora.com>
Tested-by: Aron Budea <aron.budea@collabora.com>
2019-07-11 21:57:54 +02:00
Henry Castro
5a1a057854 loleaflet: mobile: remove Map.CalcTap initialisation
follow up:
"create Map.CalcTap handler when initialize L.Map"

remove init in Socket.js which was include in the
original commit

Change-Id: If26278dc655ff4434bce0ca21d4b63623f2cdd17
2019-07-11 16:51:02 +09:00
Henry Castro
fcdcfa3e7c aloleaflet: mobile: activate manual drag and drop
In order to reuse code to handle drag and drop, it is necessary to
handle without listening the drag events. The Hammer library has an
event called "swipe" and it can be used to simulate drag and drop.

Change-Id: I1ed4e9422cd9bd98bdede88f2c994bdbba4adc4c
2019-07-11 16:51:02 +09:00
Henry Castro
b5f2ad76db loleaflet: mobile: prevent more default actions
Occurs that some devices support touch and pointer events,
and the combination emit mouse events

Change-Id: I85a6a918d2e39ec1b60105a15d35856fd5600ebb
2019-07-11 16:51:02 +09:00
Henry Castro
f519ff51c4 Revert "loleaflet: mobile: check against undefined values"
This reverts commit aa0c968976416b16af071787c99204068f91482c.

It was a bad idea, it breaks panning on IOS devices
2019-07-11 16:51:02 +09:00
Henry Castro
166d0beb79 loleaflet: mobile: avoid undefined values when panning
Change-Id: I3e67b52b383e11ea2e98831e040edc5ae0650910
2019-07-11 16:51:02 +09:00
Henry Castro
fb2a9a0e37 loleaflet: mobile: remove Map.TouchZoom
It is obsolete and now we use hammerjs library

Change-Id: I9126e694767a8fca372c8e6c608f38626b76537b
2019-07-11 16:51:02 +09:00
Henry Castro
fa757db186 loleaflet: mobile: check against undefined values
Change-Id: Ic353d381b8a39eb548122d0324d2048728d887fe
2019-07-11 16:51:02 +09:00
Henry Castro
7e71b32a00 loleaflet: mobile: add handlers to pinch events
Change-Id: Ibc757415e6bb9da9654b08c05e96560991d9d4b1
2019-07-11 16:51:02 +09:00
Henry Castro
f0d803b7c0 loleaflet: mobile: remove context toolbar
It is no longer need it because the context menu has the same
functionality

Change-Id: I8f0cfa0ff8ea6d0d564e5edb7eeabdf369952926
2019-07-11 16:51:02 +09:00
Henry Castro
cf7436a58e loleaflet: mobile: do no use setTimeout to set focus
Change-Id: I83f03f00aa3a09af04a83368c14a79901ea401e6
2019-07-11 16:51:02 +09:00