Commit graph

13520 commits

Author SHA1 Message Date
Andreas-Kainz
81a5d029e0 NB shortcuts-bar vertical alignment update
Signed-off-by: Andreas-Kainz <andreas_k@abwesend.de>
Change-Id: Ia93ff33742d16417a2a325ffcf649b2ca3499e23
2020-12-29 17:39:54 +01:00
Ashod Nakashian
01138d7ae0 wsd: save errno before invoking any other functions
Most C and Posix API clobber errno. By failing to save
it immediately after invoking an API we risk simply
reporting the result of an arbitrary subsequent API call.

This adds LOG_SYS_ERRNO to take errno explicitly.
This is necessary because sometimes logging is not done
immediately after calling the function for which we
want to report errno. Similarly, log macros that log
errno need to save errno before calling any functions.
This is necessary as the argements might contain calls
that clobber errno.

This also converts some LOG_SYS entries to LOG_ERR
because there can be no relevant errno in that context
(f.e. in a catch clause).

A couple of LOG_ macros have been folded into others,
reducing redundancy.

Finally, both of these log macros append errno to the
log message, so there is little point in ending the
messages with a period.

Change-Id: Iecc656f67115fec78b65cad4e7c17a17623ecf43
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-29 11:40:17 +00:00
Szymon Kłos
d4c8378782 Revert "NB update: calc file tab: bottom align labels"
This reverts commit 6cceee7e43.

Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I641487f7325f1e8ce439db479bccc072682ae3de
2020-12-29 11:33:33 +01:00
Szymon Kłos
1aa90ad787 Revert "NB: Update writer and impress file tab according to calc #1080"
This reverts commit d9cadd1259.

Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I91e1420e28030e6e30177c290de8afdcaee9355e
2020-12-29 11:33:33 +01:00
Pranam Lashkari
e7718ebc7b leaflet: prevent entering non numeric value in spin field
Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: I78403b489f8057b3131e1ccc1cbeef74377bedc4
2020-12-29 11:15:22 +01:00
Pranam Lashkari
ea3d78c9bf leaflet: avoid keyboard suggestions after undo/redo
problem:
undoing something on mobile does not trigger any input method
this causes problem in mobile working with suggestions
i.e: type "than" and then select "thank" from suggestion
now undo and then again select "thanks" from suggestions
final output is "thans"
this happens because undo doesn't change the textArea value
and no other way to maintain the history
So better to clean the textarea so no suggestions appear

Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: Idfdfd8acfa6d738bf695a473610d399b123e7019
2020-12-29 10:50:54 +01:00
Tamás Zolnai
09fbbf43b0 cypress: extract clean-up code into a function.
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Change-Id: I572b164f89023cd66fca2d392b830417eb6a9d74
2020-12-29 10:42:51 +01:00
Tamás Zolnai
5ebbe451e0 cypress: simplify run_iteratively.sh script.
Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Change-Id: Ibdecf2a70d83a4ef4b021657b3238951d7bbd3b2
2020-12-29 10:42:51 +01:00
Szymon Kłos
26ea341b7d notebookbar: hide non-async dialogs in graphic tab
Change-Id: Idb3dda5152c2baf7e967dccbbd442675c7d6a5e9
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
2020-12-29 10:09:31 +01:00
Henry Castro
8a768e6554 test: makefile: fix build builddir!=srcdir
fatal error: test/lokassert.hpp: No such file or dire
ctory
   17 | #include <test/lokassert.hpp>

Change-Id: I935cc4e0afd6862469d27b3d2620dfa83e38ef69
Signed-off-by: Henry Castro <hcastro@collabora.com>
2020-12-28 15:07:35 -04:00
Ashod Nakashian
0072a4080e wsd: test: log timeout better
Change-Id: I3643a2bad8611d1f6402615435295717eb2e93c1
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-28 12:04:53 -04:00
Ashod Nakashian
2edbf1c5e1 wsd: test: check if a WS Close Frame message exists
The text message in the WS Close Frame is optional.
Here we actually copy the remaining data after parsing
the status code, not assuming it exists or that the
status code was exactly 2 bytes (although in a well-
behaving WS implementation it always will be 2 bytes).

Also, no good reason to wait a full second between
socket reads in getErrorCode. However a small sleep
seems sensible to avoid logging "got 0 bytes" or so.

Change-Id: I162dfb0dd3ebf615a3e8e237006883388b9ff494
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-28 12:04:53 -04:00
Ashod Nakashian
d2e29d592a wsd: test: httpcrashtest drain using the getErrorCode helper
Reading the messages using a different helper means
we may miss (=consume without checking) the close frame.

Change-Id: I93a529723ba8d2b516319d54496c56c7e6d7da27
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-28 12:04:53 -04:00
Ashod Nakashian
96c9e03b88 wsd: test: catch and fail WSD tests when exceptions are thrown
Change-Id: Ifaabb6387d86c5a80e00cd5de34093520a1e9d66
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-28 12:04:53 -04:00
Ashod Nakashian
39e69e8168 wsd: test: improved UnitWOPIDocumentConflict
This adds proper phases instead of arbitrary
sleeping and similar workarounds. Also,
each phase documents what it expects, so
debugging failures are now self-explanatory.

Change-Id: Id51f4c285c5cf98aceba3415f0ffe14bd7605acc
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-28 12:04:53 -04:00
Ashod Nakashian
b3366cfef0 wsd: test: better logging in WopiTestServer
Change-Id: I8e33172d5c474c1d56e0af214f7a6281510d0836
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-28 12:04:53 -04:00
Ashod Nakashian
7972ded44f wsd: test: log test assertions
Change-Id: Ibf9274b1812f70f54ccd4e7be991b08a11f36c86
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-28 12:04:53 -04:00
Ashod Nakashian
64251966d5 wsd: test: use LOG_TST in new-style tests
Change-Id: I0d4558d44bc6cb92ba820ae8471d7ed2528277fc
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-28 12:04:53 -04:00
Ashod Nakashian
3b4add03ef wsd: test: store the current test name in UnitBase
Change-Id: Iaf521f6a99dcd6e6465769aed7f3757332e04f7d
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-28 12:04:53 -04:00
Ashod Nakashian
b4d9e1f413 wsd: test: use chrono types
Change-Id: Iec7f64a122126ae82af3bf16719081ea4ee645f3
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-28 12:04:53 -04:00
Ashod Nakashian
9bbd273e91 wsd: test: leverage the log system in TST_LOG
This moves the test log macros into a new home,
test/testlog.hpp, to avoid cycling dependencies.

Change-Id: Iacb80e813a64ff830fa18f63ec4de2535ee702b7
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-28 12:04:53 -04:00
Ashod Nakashian
f6082661d6 gitignore: .clangd and .cache
Change-Id: Iecb5e83bdb6dc5a54600b8bcc91254a33487a07e
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-28 12:04:53 -04:00
Pranam Lashkari
a3e59d1d21 leaflet: allow document scrolling when mouse is over annotations
Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: I9bb092a053b61f9cdd13c020b1349ae753d2289a
2020-12-28 11:57:35 -04:00
Tamás Zolnai
e8961e5123 Revert "downgrad wait-on: 5.2.0 -> 3.3.0"
This reverts commit a409b221f8.

Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Change-Id: I5662bfbf7b1209c0919eca2b8debefae9c82450d
2020-12-28 15:11:06 +01:00
Tamás Zolnai
8db4b19469 cypress: move includes of 3rd-party packages to support file.
Now we handle support file better for parallel test run too:
a13b1a93bc

Signed-off-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Change-Id: I4a88f815ddb1c4d79042134cc07e0c418d4ea10f
2020-12-28 15:11:06 +01:00
mert
6fec533398 Fix browsing parts visibility with PageDown/PageUp
Now the scrolling works as expected with the
parts that are invisible

Change-Id: I8fd41624befaea49978d43cf4e88249c47dc7534
Signed-off-by: mert <mert.tumer@collabora.com>
2020-12-28 16:13:22 +03:00
mert
067381f0b2 Pre-fetching next or previous slide tiles
Fetch the tiles of the part that is in the direction
of travel. This way we will avoid the tear effect
while browsing the tiles sequentially.

Change-Id: Ie47d1174f986253e4b43aa0c3276f05e7ddd0c81
Signed-off-by: mert <mert.tumer@collabora.com>
2020-12-28 16:13:11 +03:00
Henry Castro
5985ed252f jsdialog: only update the incoming control changes
It will update the control that has changed the model,
in the current visible dialog instead to recreate the
dialog again.

Change-Id: Ibad681df32952f380d63ccd82b01d83c488d95b4
Signed-off-by: Henry Castro <hcastro@collabora.com>
2020-12-28 08:36:17 -04:00
mert
c9cc7e840f Save Watermark bitmaps per user for re-use
Although we already save it for 256x256 regular
tiles, we use smaller tiles for preview requests
everytime there is a preview request the pixmap has to
recreated. Used unordered_map instead to keep different
resolutions saved for re-use

Change-Id: I3ced6b08b6e5f8096195b253abba8bb5afdffa3c
Signed-off-by: mert <mert.tumer@collabora.com>
2020-12-28 14:51:02 +03:00
mert
20476e147b Fix different size thumbnail rendering problem
We dont send broadcasts anymore for thumbnails
therefore no need to use higher dpi in case
we have highdpi views. This causes glitching on the thumbnail
especially when a watermark is applied. It gets smaller and bigger
back and forth and also this mean x2 more rendering for single preview.

Change-Id: I80ba8c70bcd9d5d3c00c2ddffadae11a6b0b2e61
Signed-off-by: mert <mert.tumer@collabora.com>
2020-12-28 14:50:54 +03:00
mert
92741efba3 More clean-ups wrt slide sorter
Fix preview placeholder does not load
Slowed down slide sorter scroll speed
Fix undefined function error

Change-Id: Ie19ec84bc43fbbdc2eb70fec183b895ef1409a96
Signed-off-by: mert <mert.tumer@collabora.com>
2020-12-28 14:50:37 +03:00
mert
9ef68cf19b Cancel preview requests that are not visible
Change-Id: I43db0d9d3068d38b98d449c3bba31050a1e288cd
Signed-off-by: mert <mert.tumer@collabora.com>
2020-12-28 14:50:37 +03:00
mert
fa7c5f572a Throttle preview requests on Impress
We should limit the on-fly preview requests to stop trashing
the server with countless preview requests
depending on the slide size and ask for more when we have them
rendered.

This patch adds the preview tile requests to a queue to be sent to server
as 3 requests at a time until they are rendered and received by the client
Also adding them to the queue allows us to check whether we already have
the same tile in the queue waiting to be sent which we can avoid sending
twice.

Change-Id: I03684dc807a7aef6c996a91efba100a9dca9686d
Signed-off-by: mert <mert.tumer@collabora.com>
2020-12-28 14:50:37 +03:00
Pranam Lashkari
1b27129309 leaflet: prevent text editing in master view
Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: I95ed79cf557b53b6a6695e98eda7684f70a4dd24
2020-12-28 09:39:17 +01:00
Andreas-Kainz
e6cc492e90 NB Impress home tab align bullet commands
Signed-off-by: Andreas-Kainz <andreas_k@abwesend.de>
Change-Id: I57a86ad8188bbbe2dd7d6acb1cc51ef1bfea6fb4
2020-12-28 08:43:49 +01:00
Andreas-Kainz
7692247d63 NB Calc home tab align character commands
Signed-off-by: Andreas-Kainz <andreas_k@abwesend.de>
Change-Id: I3ce35f06991d889efbbc2a5017bb61a16d07bd48
2020-12-28 08:43:49 +01:00
Andreas-Kainz
0396307eaf NB Writer home tab align bullet commands
Signed-off-by: Andreas-Kainz <andreas_k@abwesend.de>
Change-Id: I591f14db39261c7d319d179d98af122c06b028c9
2020-12-28 08:43:49 +01:00
Andreas-Kainz
87aff35664 NB update Format Tab
Signed-off-by: Andreas-Kainz <andreas_k@abwesend.de>
Change-Id: I36ede47c5bf917d5620a3dddeaa1e8133cc638a4
2020-12-27 20:16:24 +01:00
andreas kainz
cb27d2cda6 NB: vertical-align content
Signed-off-by: andreas kainz <kainz.a@gmail.com>
Change-Id: I08c0ca3a33f50b046b51705b0933e5623b203b48
2020-12-23 22:55:59 +01:00
andreas kainz
d9cadd1259 NB: Update writer and impress file tab according to calc #1080
Signed-off-by: andreas kainz <kainz.a@gmail.com>
Change-Id: I09e41341321b2cf03903d39533aba722abe5d2e4
2020-12-23 18:11:43 +01:00
andreas kainz
6cceee7e43 NB update: calc file tab: bottom align labels
Signed-off-by: andreas kainz <kainz.a@gmail.com>
Change-Id: I86e4eec764dcbe3771d0d381e078bbbb57665c3f
2020-12-23 11:20:36 +01:00
andreas kainz
952b5c0219 NB writer: add context-graphic tab
Signed-off-by: andreas kainz <kainz.a@gmail.com>
Change-Id: Iea802e4bd662ed9003f61665b771e49f6ea6e4c4
2020-12-23 11:20:22 +01:00
Jan Holesovsky
08f0e99bca Remove unused functions.
Signed-off-by: Jan Holesovsky <kendy@collabora.com>
Change-Id: I79d9a5028a64e30b68b6a9aeb3389dfb7d083bc9
2020-12-22 17:55:00 +01:00
Rash419
2a87c77ee3 leaflet:add and remove kebab,sub-menu-arrow when necessary
Signed-off-by: Rash419 <rasheshpadia419@gmail.com>
Change-Id: I5360922453f962a45e1d4cf7c418f2bbfa3a31ed
2020-12-22 21:54:41 +05:30
Ashod Nakashian
693a2e19e3 wsd: SocketPoll::poll accepts chrono duration
Cleans up some of the conversions and implicity
unit in integral types.

Change-Id: I79f35b92f8f631894e55bdb39851b050870fce96
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-22 11:24:13 -05:00
Ashod Nakashian
13d7d23cbe wsd: use chrono for readability and conversion safety
Change-Id: If5d478605fef0199b331d91310673a460e70d48e
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-22 11:24:13 -05:00
Ashod Nakashian
693ac2fa52 wsd: logs and const
Change-Id: Id7e4f81ab9709b62eddfa747479ab593a5ad45a2
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2020-12-22 11:24:13 -05:00
Jan Holesovsky
e77da33d43 canvas layer: _animatingZoom is no more needed too.
Signed-off-by: Jan Holesovsky <kendy@collabora.com>
Change-Id: If7e38c591e6b4b52fa16a47f4cc3f1c015ee0901
2020-12-21 22:19:18 +01:00
andreas kainz
51ba40862a Notebookbar Insert Tab: update writer insert tab
Signed-off-by: andreas kainz <kainz.a@gmail.com>
Change-Id: I255116b6bb16e84d2b465f8fb862145924552f68
2020-12-21 21:25:31 +01:00
andreas kainz
a596e3292c Notebookbar Insert Tab: update calc insert tab
Signed-off-by: andreas kainz <kainz.a@gmail.com>
Change-Id: I0d829aaa2e9869de87cddc997b8758fe8d20823c
2020-12-21 21:25:15 +01:00