Commit graph

13047 commits

Author SHA1 Message Date
Ashod Nakashian
ee0b5203ec wsd: SaveResult final and Result enum class
This makes the code self-documenting and avoids accidental
comparison or assignment of Result variables/values.

Change-Id: I84b8e36aa999191c8704938552b73ddc1c3dc3fc
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-11-15 13:50:16 -05:00
Ashod Nakashian
2ddc1afb69 wsd: resuse Stat where possible
This replaces Util::getFileTimestamp with
FileUtil::Stat::modifiedTimepoint() and fixes a potential bug:
getFileTimestamp had only 1 second precision (it simply dropped
sub-second data). This could mean that any modifications to a file
within a second could not be detected.

Minor simplifications done where possible and overly long lines
have been reformatted.

This is a non-functional change (except that file modified-time
now supports microsecond precision).

Change-Id: I3606638a86fc3e00c0ad5cb602bdbb2b4651867b
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-11-15 13:50:16 -05:00
Ashod Nakashian
20f95a17a9 wsd: improved Stat modified-time and unit-tests
Change-Id: Ic6e7972e3d69c78681f599b6e6797e3e4164cd34
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-11-15 13:50:16 -05:00
Ashod Nakashian
2fd9bbb509 wsd: socket comments and cosmetics
Change-Id: Icb202f5d44238a436ff5095341c9287a01df1247
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-11-15 13:50:16 -05:00
Ashod Nakashian
23638329bb sample: new form page to load documents via post requests
Often loleaflet.html is loaded via POST requests. This
new sample demonstrates and exercises this approach and
is a handy way to load documents.

Change-Id: I065a946413ab08d399ac5704c67f6f1ba37bdd9e
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-11-15 11:10:20 -05:00
Ashod Nakashian
ebcdaa9e87 sample: added usage and improved url construction in framed.doc.html
This should make this sample much more useful by documenting
the proper usage and helping the user avoid common pitfalls.

Change-Id: I965bed0e4ab685dd2a68f7b246dd9a409d296337
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-11-15 11:10:20 -05:00
mert
8422d2d596 Fix distortion on watermark text
Change-Id: Id1bda715723e717d6f0893dbc1aef937014076e3
Signed-off-by: mert <mert.tumer@collabora.com>
2020-11-15 13:54:33 +03:00
Michael Meeks
7a02a8c24e Ensure consistent canonical view id accounting between wsd and kit.
Confusion arose due to separate creation of session, and watermark
property fetch from CheckFileInfo which happens in DocumentBroker::load
which doesn't do a load. This happens in a subsequent 'load url='
message cf. global.js which can then race vs. the session creation.

This causes mis-ordering of another unhelpfully shared Session,
letting the view canonicalization list to get out of sync between
the two processes.

So instead - tell the view it's canonical id. An example of the
problems of trying to share some unclear subset of the Session
class between kit and wsd perhaps.

Change-Id: I63dc30f9a047e3f889fd339b6aaf392b9fef37b9
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2020-11-14 19:56:09 +03:00
Michael Meeks
0d10c2cae8 Set normalized view id for broadcast (ie. slide preview) thumbnails.
Change-Id: Ica5312ae9c7147c8dc969523e28d460348ba2e76
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2020-11-14 19:54:56 +03:00
Tamás Zolnai
04139d31cd cypress: diable this new multi-user test case for NC and php-proxy.
Change-Id: I18688e130f9ac5b8976ca60ad44b798c48181129
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-14 12:24:36 +01:00
Tamás Zolnai
2c338ef7e2 cypress: this test is unstable recently.
Needs some rework.

Change-Id: Ied3008463e9a7210a400702a0331ab7f09139ed3
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-14 12:24:36 +01:00
Tamás Zolnai
1a6fc4ca05 cypress: disable these unstable tests for now.
Change-Id: I99f166933ddbaf899d2d4fffd218f2824e3adf52
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-13 23:17:06 +01:00
Tamás Zolnai
d9ce03331d cypress: php-proxy: reenable this test.
The issue was fixed triggered by this test case.

Change-Id: I00522835c25ca18aa374958c5b33b13f35e79563
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-13 23:17:06 +01:00
Tamás Zolnai
6611d6359a Fix 'Cannot read property 'getSouthWest' of null' error.
Change-Id: I6344ea781bce1de817a6e73897fc494172550aa9
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-13 23:17:06 +01:00
Tamás Zolnai
28c99d5e46 cypress: remove this old test.
It's duplicated now. It was one of the first
prototype tests.

Change-Id: I6a63644713189c8f56a77cc21df0c2a42d724547
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-13 11:57:23 +01:00
Tamás Zolnai
be8f8ea874 Update eslint of cypress test code: 6.8.0 -> 7.12.0.
Change-Id: I3508579dc608d56e63d842e413dc14d4c760965c
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-13 11:57:23 +01:00
Tamás Zolnai
ffccbfaf4f Update cypress-select-tests: 1.5.7 -> 1.5.8.
Change-Id: I5b3a67b3bacf3efb8ffbef98d8967608c2f81742
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-13 11:57:23 +01:00
Tamás Zolnai
1ed1f0705f Update cypress: 5.3.0 -> 5.5.0.
Change-Id: I0c1431eaa3f49c3a4705a9cd438162cd7ccd0fe8
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-13 11:57:23 +01:00
Tamás Zolnai
2aa37cbaf4 cypress: do not run afterAll method in case of failure.
After a test failure, it's common, that the afterAll
method also fails which covers the right error
message and also makes the following tests to be ignored.

Change-Id: I5c1bbc5dd8b1b48dd2a8f1fc20a8ca3b8ecd8462
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-13 11:57:23 +01:00
Tamás Zolnai
9c65fe9805 cypress: NC: avoid hard coding locale indicator in number formatting tests.
1033 means en-US locale. It can be different in an
NC environment for example.

Change-Id: I929a7308b9f0d4a102f836d1ec66c5c98a6eb9c6
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-13 08:53:14 +01:00
Tamás Zolnai
6620c77c3a cypress: php-proxy: disable this unstable test.
Change-Id: I6fa2f777c95dac57d4ae8b13063c04f44d1ff20c
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-13 08:53:14 +01:00
Tamás Zolnai
10df5de391 cypress: NC: disable retries.
In NC environment it does not work properly.

Change-Id: I9adbb01b450103a6ac2aa211eb933a5ab3f5fcd2
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-13 08:53:14 +01:00
Tamás Zolnai
175b32ddb1 cypress: NC: disable this unstable test.
Change-Id: Ifd7b970aac8e5f6a6bfc1a58d75eddf63ea42fd7
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-13 08:53:14 +01:00
Ezinne Nnamani
4bea7938c5 Created a Cypress test for Format as currency and Format as Percent in Desktop Calc
Signed-off-by: Ezinne Nnamani <nnamani.ezinne@collabora.com>
Change-Id: I90ca9051ce71e9f3bc9b774cd0bdb87c076ceb8d
Signed-off-by: Ezinne Nnamani <nnamani.ezinne@collabora.com>
2020-11-13 05:09:21 +01:00
Tamás Zolnai
d328f930ce cypress: php-proxy: close php-proxy connection by the end of the test.
For some reason if we use proxy.php continuously, then
it will eventually fail on the test. With visiting the
localhost in the afterEach method we can avoid that.

Change-Id: If56c8e40e9e2b9002c1c5b0b91851e4a19a2c9bd
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-12 16:38:11 +01:00
Tamás Zolnai
2581ab44f9 cypress: remove core/master blacklist.
It is outdated.

Change-Id: I29de4a7ddbacb62cd091446929fe9ba56ce9baf9
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-12 16:38:11 +01:00
Ezinne Nnamani
f0f330498e Created a Cypress test for Add Decimal places and Delete decimal places in Desktop Calc
Signed-off-by: Ezinne Nnamani <nnamani.ezinne@collabora.com>
Change-Id: I3420488c79af469cbcc5181106e4ec864f40893d
2020-11-12 13:47:15 +01:00
thais-dev
4c915f5604 Translated using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (17 of 17 strings)

Translated using Weblate (Portuguese (Brazil))

Currently translated at 100.0% (356 of 356 strings)

Co-authored-by: thais-dev <thais.vieira@collabora.com>
Translate-URL: https://hosted.weblate.org/projects/collabora-online/android-lib/pt_BR/
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/pt_BR/
Translation: Collabora Online/Android lib
Translation: Collabora Online/UI
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I9bd887506cfeb282ca01b7d6deacdd289196f278
2020-11-12 13:37:01 +01:00
Mike Kaganski
73f45e6648 Translated using Weblate (Russian)
Currently translated at 100.0% (5 of 5 strings)

Translated using Weblate (Russian)

Currently translated at 100.0% (17 of 17 strings)

Translated using Weblate (Russian)

Currently translated at 100.0% (107 of 107 strings)

Translated using Weblate (Russian)

Currently translated at 100.0% (356 of 356 strings)

Co-authored-by: Mike Kaganski <mikekaganski@hotmail.com>
Translate-URL: https://hosted.weblate.org/projects/collabora-online/android-app/ru/
Translate-URL: https://hosted.weblate.org/projects/collabora-online/android-lib/ru/
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ios-app/ru/
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/ru/
Translation: Collabora Online/Android app
Translation: Collabora Online/Android lib
Translation: Collabora Online/UI
Translation: Collabora Online/iOS app
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I58036ad7c92666a8c029f870a19193edcafa86a3
2020-11-12 13:36:55 +01:00
J. Lavoie
2458a96ce5 Translated using Weblate (Italian)
Currently translated at 99.7% (355 of 356 strings)

Translated using Weblate (French)

Currently translated at 100.0% (356 of 356 strings)

Translated using Weblate (German)

Currently translated at 100.0% (356 of 356 strings)

Co-authored-by: J. Lavoie <j.lavoie@net-c.ca>
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/de/
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/fr/
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/it/
Translation: Collabora Online/UI
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I2cd7320f63f868da91d514f1324145f645e306de
2020-11-12 13:36:27 +01:00
Pedro Pinto Silva
3e53289dbb Vex dialog: close btn: approximate style to regular dialogs
Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I7e25cfd716cba88364682dcf1093fa2224a1da5b
2020-11-12 13:16:45 +01:00
Pedro Pinto Silva
4b1c79058e Vex dialogs: Fix close vertical alignment on hover
to match its height (that is comming from vex theme)

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Ibffc3040d07afd2ea98af65a3aeaa041b0dc73fe
2020-11-12 13:16:45 +01:00
Pedro Pinto Silva
169ab2ce62 iOS: Fix fontname btn styles and inherit defaults from...
existent classes while overruling line-height and padding
for that particular btn (has np chevron since it's a btn and not a combobox)

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I393c972b44402c4030a6d7838750cfbd8156530e
2020-11-12 10:56:56 +01:00
Pedro Pinto Silva
4f2ce5a1ba Notebookbar: Fix the order in which elements are added,
fix logo (document-header) overlap on some devices, namely iPads.

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Ib2ca48d805f6decd941ae3f817f987791a074ed4
2020-11-12 10:56:40 +01:00
Ezinne Nnamani
ccf0c54de0 Created a Cypress test for Clear Direct formatting, Apply font style and Apply font size in Desktop Calc
Signed-off-by: Ezinne Nnamani <nnamani.ezinne@collabora.com>
Change-Id: I7f59d8e9d9597137e26e6d2cc0a20bf3d516ce21
Signed-off-by: Ezinne Nnamani <nnamani.ezinne@collabora.com>
2020-11-12 08:16:49 +01:00
Tamás Zolnai
ffc114e909 cypress: php-proxy: disable calc undo / redo tests.
We might hit a race conidtion here. I'll need to
investigate this later. It seems sometimes the
selectio is what is undo-ed and not the text
modification.

Change-Id: Ib9c6214cefd0b8625116681c3cbca17899beaece
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-12 05:40:08 +01:00
Tamás Zolnai
f9f459fe67 cypress: php-proxy: fix clone formatting test.
Change-Id: Ia83a534eb0f97f70db992239d41d2f25dc69042d
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-12 05:40:08 +01:00
Tor Lillqvist
b5ea4811f0 tdf#133279: Fix typing into tunnelled dialogs on hardware keyboards in iOS app
Let's hope this doesn't have any unintended side effect.

Change-Id: I38d5c6f3a8526ce510fe07f58fba17e98eb09e2e
Signed-off-by: Tor Lillqvist <tml@collabora.com>
2020-11-11 19:22:35 +02:00
Pranam Lashkari
dbca0433a9 leaflet: calc text selection is never removed
problem:
once text inside the cell is selected,
taping on other cell does not remove the selection

Change-Id: I2c4bd4e46a42854bdcc5a09f6af170d33dc4e8c0
Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
2020-11-11 17:42:09 +05:30
Tamás Zolnai
eb4a36c1ec cypress: NC: disable revision history tests for now.
In CI environment this does not work. I'll need to find out
how to make this tests work there too.

Change-Id: If9780796b52aa27fd18d72cc3bf786ab46865e4a
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-11 12:25:56 +01:00
Ezinne Nnamani
fba2ee9ced Created a Cypress test for the HighLight color and Font color attributes in Desktop Calc
Signed-off-by: Ezinne Nnamani <nnamani.ezinne@collabora.com>
Change-Id: I6cdaac6c8465cb97dd801b94f55054100bc46948
2020-11-11 10:40:59 +01:00
Ashod Nakashian
3dff047b16 wsd: support line-breaks in watermark text
New-line breaks can now be inserted in the watermark
text using
. This helps break long watermark texts
at desired points and therefore make watermarks more
readable.

Change-Id: Ifee6faa06c9fb1fac38e5a4036c2e225829d796d
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-11-11 08:14:42 +01:00
Ashod Nakashian
4185c5fd03 wsd: encapsulate watermark details
The watermark handler member has been fully encapsulated
inside ChildSession, so there is no need to have public
members or circular dependencies (ChildSession owns Watermark
instance, and Watermark takes ChildSession instance to
construct and initialize).

Minor refactoring and const-correctness improvements.

This is a non-functional patch.

Change-Id: I32525c47e35e96fc5314e107639be93ebc49a60e
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-11-11 08:14:42 +01:00
Ashod Nakashian
b5921288de wsd: comment typo
Change-Id: Ie75ae1cc73791af2e8f52b7ccab438b7adbd795e
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-11-11 08:14:42 +01:00
Ayhan Yalçınsoy
ec4d35a53a loleaflet: eslint v.bump to 6.0.0 #396
Signed-off-by: Ayhan Yalçınsoy <ayhanyalcinsoy@pisilinux.org>
Change-Id: I08f7cc953aa6434fccbc92d74570c62a43c7dad9
2020-11-10 22:53:23 +03:00
Tamás Zolnai
2297388a32 cypress: NC: try to fix revision history related tests.
Let see whether waiting some time after context switch
makes things better. Cypress does not support iframes
very well.

Change-Id: If6011f16c54e3473bef20546f39bb45941c40dc9
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-10 20:18:32 +01:00
Tamás Zolnai
f4dc257423 cypress: php-proxy: disable formula bar related tests.
It's a known issue that formula bar is very laggy,
which makes test to fail.

Change-Id: Ia2cbee763c596065e36d178913a8df400adb4668
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-10 20:18:32 +01:00
Ezinne Nnamani
cb355967f1 Created a cypress test for Italic, Strikethrough and Underline attributes in top toolbar of Calc Desktop
Signed-off-by: Ezinne Nnamani <nnamani.ezinne@collabora.com>
Change-Id: I1f782710a8728c39d3a40dfb56b6af4d9809947c
Signed-off-by: Ezinne Nnamani <nnamani.ezinne@collabora.com>
2020-11-10 17:53:47 +01:00
Miklos Vajna
59e8c35afc README: mention the tinderbox
Its status is not reported on GitHub, so at least make this easy to
find.

Signed-off-by: Miklos Vajna <vmiklos@collabora.com>
Change-Id: I8a4f5bffbdb6692afa7f55e0f55ce41c04facd39
2020-11-10 14:10:55 +01:00
Tamás Zolnai
6fe727048e cypress: add remaining tests for Writer top toolbar (desktop).
Change-Id: Ie55928532afbb3b59ee348c3a04f38e7cf3304d8
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-11-10 13:57:31 +01:00