Commit graph

20315 commits

Author SHA1 Message Date
Gökay Şatır
e5d86f0b3c We can use foreach when there is indexed assinments.
I replaced the hack with foreach.

Also added one more foreach for distinguishing the click events from keyboard events.

Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: Ibc1d955636ea4dde214c24b911c17c7b0de5f9e0
2023-03-21 20:42:22 +03:00
Szymon Kłos
2958316032 Zotero: execute commmands with opened dialog
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I07b28af9283f995009d372cd8257bdd76c558f5b
2023-03-21 15:51:59 +01:00
Gökay Şatır
ee4c9e5fb6 Turn tab buttons into button elements from span elements.
Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: If418a3d50da2d66e17277e64adc462b9a111816c
2023-03-21 17:22:19 +03:00
Szymon Kłos
adebee022e jsdialog: keep correct structure with hidden elements in grid
Don't show scrollbars for hidden content.
Affecting data -> Sort and data -> validity dialogs in calc

Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I3124d921ef7819f274e9f583a605e63b66722388
2023-03-21 19:32:06 +05:30
Szymon Kłos
e6a70e21f4 jsdialog: keep focus in drawingarea when typing
When drawingarea is used as edit filed it is updated
on every kep press or mouse click. We need to setup unique
id for img also so focus later will be set for the same element
after we get update message. (focus is set based on previously focused
id)

Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I89021839177ab78fd0f2346cca2c58fac257af6b
2023-03-21 19:32:06 +05:30
Gökay Şatır
707630a007 Update Cypress tests.
Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: Iba3da8f540d353298941145bd59cd7d1ef3cc03d
2023-03-21 14:24:41 +03:00
Szymon Kłos
0b1de0908d Don't modify overlay callback manually
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Ia1f2592bf8a1fefc4a1f417d069a8add9cd33794
2023-03-21 14:24:41 +03:00
Szymon Kłos
0b5a6a9847 Create modal already with textview
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Ic303dcbf70ed517965aab165a772682a44287665
2023-03-21 14:24:41 +03:00
Gökay Şatır
03e6cc491f Remove vex from comments.
Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: I3ebb052bdac91e3e2fd084dca06d8f221d82083e
2023-03-21 14:24:41 +03:00
Szymon Kłos
1216a769dc jsdialog: non-user-managed scrolled window
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Ic49898cd7e663c7db270dec7310a94b9bd9b5943
2023-03-21 09:17:34 +01:00
Szymon Kłos
8fc3ef40f1 jsdialog: vertically center listbox
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Icd0d2ed89f09021c1d30b3e71cf7b8b24cca3766
2023-03-21 09:17:34 +01:00
Szymon Kłos
89eb98a7ea jsdialog: scrolledwindow should reserve space for scrollbar
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Ia4ce53676aad8ccefd20504a33348cb7a0a617ab
2023-03-21 09:17:34 +01:00
Szymon Kłos
f9ad2ea3c3 jsdialog: vertically center radiobuttons
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I1c200f2208b4f762d01dc6dd85459dbedce7b03e
2023-03-21 09:17:34 +01:00
Szymon Kłos
3225aa5b57 mobile: don't steal focus from save-as dialog
When integrator shows dialog eg. for save as with the
input fields, keyboard appears resizing our frame.
We shouldn't then steal focus from input.

Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Ifda6e7049b1b329fb051966e38fa854c93c05065
2023-03-21 08:29:44 +01:00
Szymon Kłos
a7fd4ee0f5 zotero: show buttons when integrator supports it
Empty api key string indicates that integrator supports
Zotero. When any functionality is accessed by the user
we show notification to integration so it will show a
popup for user with instructions.

Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Id7289097f245cd3c537ccf78cf818c1aa0d57231
2023-03-21 08:29:30 +01:00
Szymon Kłos
47cd213b10 export as pdf: we need to decode path
When using Nextcloud with source file with spaces in the name
eg. "file name.docx" and we tried to export as PDF
then error appeared.

In the logs we had "SaveAs produced no output in '<...>file%20name.docx', producing blank url.

We need to decode file name similar to convert-to case.

Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Ic60cefefc4e20b53feee28b86443090c147bb66e
2023-03-21 07:39:15 +01:00
Gökay Şatır
0d0f056f71 Skip delete chart test for now.
Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: I57ed634cb821be2cfdae9b4d8d1ab587c65635d6
2023-03-20 20:10:49 +03:00
Gökay Şatır
63964d8fcb copy-paste-field behaviour is changed for some reason.
Probably due to core side changes. I needed to comment out the property checks.

Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: I26683265b827447e676a6463b19b5cb84a0040fc
2023-03-20 20:10:49 +03:00
Rash419
2d3b93feed cypress: updated tests for co-23.05
Signed-off-by: Rash419 <rashesh.padia@collabora.com>
Change-Id: I08d82284f88beea96fa931c691a9208c64d4a940
2023-03-20 20:10:49 +03:00
Andras Timar
0cd7ec4449 CI check
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: Ibc2c700a5c5f89ada067125ad995fd57c1274159
2023-03-20 20:10:49 +03:00
Andras Timar
9dd0b6b059 docker: updated readme
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I8a14cb16bea4f4f530b135fc9343ba5b4ec6e9f0
2023-03-19 12:55:23 +01:00
Rash419
a5dbe0a430 cypress: updated the test for core co-23-05
Signed-off-by: Rash419 <rashesh.padia@collabora.com>
Change-Id: If4c2b252ca53ecfe4e3db6722d2bb7cb5069a242
2023-03-17 21:27:01 +01:00
Paris Oplopoios
7b61201b1b Make dark mode button send an uno command to change the core theme
Signed-off-by: Paris Oplopoios <paris.oplopoios@collabora.com>
Change-Id: I8ec47a5dee32ff1470715c6a8e9fc396753a81f6
2023-03-17 17:34:05 +00:00
hanswang123456
75deb4bf13 Update lc_toggledarktheme.svg
Signed-off-by: hanswang123456 <50556568+hanswang123456@users.noreply.github.com>
2023-03-17 17:34:05 +00:00
Rizal Muttaqin
0b5717cefa Revise dark variants
Signed-off-by: Rizal Muttaqin <riz_17_oke@yahoo.co.id>
Change-Id: I28d6825d785fd08b79b3be4a6b94a82c98b728c1
2023-03-17 17:34:05 +00:00
ChrisGlad
2f24fc35bf Fix UI Selection bug
Signed-off-by: ChrisGlad <chris.gladman2004@gmail.com>

This code fixes the problem that elements in the Notebookbar will
not be correctly displayed as "selected" after changing the UI
mode.

Change-Id: I4f889f8593029c375a06e17dbf1062bb9b9f5efc
2023-03-17 17:34:05 +00:00
Christopher Gladman
11bb035634 Add a dark mode toggle
This adds a dark mode toggle to both user interface views (compact and tabbed view).
In addition, this code fixes the problem that the initial theme did not load properly
based on settings. Equally, the Toggle in Notebookbar will now appear
"selected" when pressed.

Signed-off-by: ChrisGlad <chris.gladman2004@gmail.com>
Change-Id: I0e0c282cec24d9bb7fbfc4131ba3875976cea5fd
2023-03-17 17:34:05 +00:00
Pedro Pinto Silva
585a438944 Revert "Revert "Add color-scheme-dark.css support""
This reverts commit a864d41c09.
Because we can now work in this WIP feature in its dedicated
feature branch.

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
2023-03-17 17:34:05 +00:00
Paris Oplopoios
8ade29f112 Handle LOK_CALLBACK_VIEW_RENDER_STATE in the Kit
Signed-off-by: Paris Oplopoios <paris.oplopoios@collabora.com>
Change-Id: Ie4d03a3600cb9ebdf9b76ee4779d62da30ad3eb6
2023-03-17 17:34:05 +00:00
Paris Oplopoios
ab176b13a8 Move canonicalId creation to the Kit
Signed-off-by: Paris Oplopoios <paris.oplopoios@collabora.com>
Change-Id: I943bfa0436487e517b25d3fce19157ebd576604f
2023-03-17 17:34:05 +00:00
Paris Oplopoios
d26c425dae Move _canonicalViewId out of Session
Signed-off-by: Paris Oplopoios <paris.oplopoios@collabora.com>
Change-Id: I9c06440ed47eb217e973d2f530f2c3646d55d85b
2023-03-17 17:34:05 +00:00
Rash419
5dba72a341 fix: mention cannot be inserted
- forcefully send unocommand when jsdialog popup is still open
- fix navigation using ArrowKeys in treeview
- fix console error ev.data is null

Signed-off-by: Rash419 <rashesh.padia@collabora.com>
Change-Id: I6dd75b8b576754513574749e1bd9675581caeabf
2023-03-17 19:13:02 +05:30
Bayram Çiçek
1a269be3ac use getrandom() instead of /dev/[u]random
- instead of using /dev/[u]random devices, use
getrandom() and/or getentropy() to make direct
system calls if sys/random.h is available.

- if getrandom() fails, we need to fall back
to "/dev/[u]random" approach.

Signed-off-by: Bayram Çiçek <bayram.cicek@libreoffice.org>
Change-Id: Ied37d72feabf005725b615b02854912809236bbc
2023-03-17 08:38:21 -04:00
Patrick Luby
0edea869a7 Fix GitHub issue #5839 and never disable Paste toolbar button
Behave the same as Contol.Menubar and never disable Paste toolbar
button. Native clients that run LibreOffice locally may send a
"statechanged: .uno:Paste=disabled" message when opening a document
if the system clipboard is empty, So, we ignore such messages or else
the current document's Paste toolbar button will never be enabled.

Signed-off-by: Patrick Luby <patrick.luby@collabora.com>
Change-Id: Ied2aaa49f1a9defe30541af49f4becda35df568b
2023-03-16 10:26:19 +01:00
Szymon Kłos
c3fb54505b jsdialog: add class to all menubuttons
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I35008b79b25dbc071f68778611988d77c517bccc
2023-03-16 09:25:06 +01:00
Szymon Kłos
ea191a1120 jsdialog: menubutton imports menu
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Ifd37af977c9831ec81860bb8092c2e29d0e910f5
2023-03-16 09:25:06 +01:00
Szymon Kłos
0e385ef2ec jsdialog: move menubutton to separate file
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Ifd314f884e7a96b76a74dcc19922746938e885b5
2023-03-16 09:25:06 +01:00
Szymon Kłos
d6f513ae1d jsdialog: handle key events in drawing area
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I9ecd4b734dfb3c3bb7698bf019836b142e57f8ae
2023-03-16 09:25:06 +01:00
Szymon Kłos
4139e46756 jsdialog: don't scroll arrows inside scrolledwindow
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I157f92f094e11368922400ac92bfb86e791f2a6a
2023-03-16 09:25:06 +01:00
Szymon Kłos
28ad836c3e jsdialog: keep correct structure in grid
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Ie94831827c3829d202013864980e31e181722a7c
2023-03-16 09:25:06 +01:00
Szymon Kłos
6e2ef04e78 jsdialog: build menubuttons with only image
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I6754545dac87a0860f07b4d47796bdb2eb25994e
2023-03-16 09:25:06 +01:00
Szymon Kłos
207d07cb1a jsdialog: double click for drawing area
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I89d12d9524636e2af3798871f3a140223604f83d
2023-03-16 09:25:06 +01:00
Szymon Kłos
dae1f7438a jsdialog: move Drawing Area to separate file
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Id659d7e2fc9b50d43d66fb48d78c1f1dede4b23f
2023-03-16 09:25:06 +01:00
Gökay Şatır
c718a8f042 remove lonely "close all" calls for vex.
Replace closeAll calls with uimanager.closeAll. It works for also mobile view.

Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: Ieaf11fc8f68390f789c18a29813a171d51c13a88
2023-03-15 18:34:36 +03:00
Szymon Kłos
ad86b08c93 jsdialog: handle scrolled window properties
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Id278ff25bb5a87b26ff4e45fca8d972140d16c38
2023-03-15 10:46:44 +01:00
Patrick Luby
7dd1e505e6 Fix issue #5841 welcome, feedback, and buy product URLs are empty on mobile
Mobile apps don't substitute these values so set them to zero length
strings.

Also, the iOS app sets the base text direction via the "dir" parameter
so add handling of that parameter in cool.html. TODO: check if the
Android and GTK apps need to implement the "dir" parameter to handle
RTL layout.

Signed-off-by: Patrick Luby <patrick.luby@collabora.com>
Change-Id: Ied8268ec256011281961ef610d53baeee0efe9cd
2023-03-15 09:29:56 +01:00
Patrick Luby
17f739ca77 Fix issue #5887 by assuming that documents are writable on iOS
The iOS app saves directly to local disk so, other than for
"view file extension" document types or other cases that
I am missing, we can assume the document is writable until
a write failure occurs.

Signed-off-by: Patrick Luby <patrick.luby@collabora.com>
Change-Id: Iacb1589eded18f0cb21a5dd8e4d91d295ae697fe
2023-03-15 09:29:56 +01:00
Andras Timar
48a1101970 add common/LangUtil.hpp to distribution
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: Ic7ad5f7a75cab91d7f34d1455737a8838564c502
2023-03-14 23:37:19 +01:00
Patrick Luby
54ad0f173b Another fix for issue #5843
Limit escaping of non-ASCII text and splitting on the first newline to
only certain message types on iOS.

Also, fix mangled UTF-8 text on iOS in jsdialogs when using languages
like Greek and Japanese by only setting the image bytes for only the
same set of message types.

Signed-off-by: Patrick Luby <patrick.luby@collabora.com>
Change-Id: I9cd088509ba9724108da3c9457cd3d098b45723f
2023-03-14 21:55:12 +01:00
Andras Timar
98ae6ac269 disable fragile TileCacheTests::testTileProcessed()
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I791b24b59a22f87006a334332e7b8661615ac21d
2023-03-14 21:17:13 +01:00