Commit graph

152 commits

Author SHA1 Message Date
Pedro Pinto Silva
a002f5ee86 * Change menu item text so it fits in the sidepane
* Fix diretorias to diretotios

Change-Id: I11152a1c0a3deb536930260007682e444ace74f9
Reviewed-on: https://gerrit.libreoffice.org/85058
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-12 15:21:37 +01:00
Andras Timar
859c75037e Revert "android: add pot file for localization"
We'll use Weblate and it handles strings.xml directly

This reverts commit d6e55afc4b.

Change-Id: I44ced10d7da37feffdd222a9a63a33545362b306
2019-12-12 12:49:54 +01:00
Jan Holesovsky
c2385112ac android: Make all the .uno: commands work again.
Was a problem introduced by c6f36965cf.

Change-Id: I8fbc722ed73af19a6462c87242d431eea118f1a2
Reviewed-on: https://gerrit.libreoffice.org/85020
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-12 10:17:16 +01:00
Michael Meeks
a72392cc57 android: improve debugging readme.
Change-Id: I4d1933e38c7cb0fd4d28b4384e11f35f2c9e8626
2019-12-11 22:53:14 +00:00
Jan Holesovsky
8002f9f38a android: Removed unused resources.
Change-Id: If6175b4703db3d476acc781b9d02c84ca79f7c12
Reviewed-on: https://gerrit.libreoffice.org/84984
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-11 20:45:14 +01:00
Jan Holesovsky
b648eceecb android: Turkish shell translations copied over from core.git.
Change-Id: If74644bdf2460f2fd2a8346b84333340d4acc7c9
Reviewed-on: https://gerrit.libreoffice.org/84983
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-11 20:44:22 +01:00
Pedro Pinto Silva
1a6ab5ae28 android: Brazil Portuguese translations of the lib.
Change-Id: I587a69518d23c7f2a7580918610619bd78821754
Reviewed-on: https://gerrit.libreoffice.org/84982
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-11 20:43:57 +01:00
Eloy Crespo
166a0f2c02 android: Spanish translations of the lib.
Change-Id: I8fc84c9d406a2cd7be840ec2f6e09a9869e8e157
Reviewed-on: https://gerrit.libreoffice.org/84981
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-11 20:43:31 +01:00
Jan Holesovsky
1cb4cfe2b1 android: Honor the languge setting from the system.
Makes no sense to have an own language switching mechanism in the app...

Change-Id: Ic19bf36e35d1d011a1cd96c17b713e41577c512e
Reviewed-on: https://gerrit.libreoffice.org/84980
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-11 20:42:53 +01:00
Jan Holesovsky
b9df7da0ff android: Fix build after the recent Nextcloud's android-library update.
Thanks Tobi for the hint!

Change-Id: I00b7ef4aaef7ced1d26d3d5636189e239897ecea
Reviewed-on: https://gerrit.libreoffice.org/84979
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-11 20:41:46 +01:00
Pedro Pinto Silva
7e1a6bdbec android: Brazilian Portuguese translations of the shell.
Change-Id: Ib71ccb7281e3e27c3184d3487b56253c61f2bc2a
Reviewed-on: https://gerrit.libreoffice.org/84978
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-11 20:40:03 +01:00
Eloy Crespo
7bb78ae23f android: Spanish translations of the shell.
Change-Id: I5c0d0034085f6b03f7541f259048ab0774f92081
Reviewed-on: https://gerrit.libreoffice.org/84977
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-11 20:39:42 +01:00
Michael Meeks
e12de33ecf android: encode SCHEME_FILE paths as URIs not paths.
Fixes encoding problems particularly with eg.
SCHEME_FILE: getPath(): /storage/emulated/0/Android/media/com.nextcloud.client/nextcloud/user@demoserver.com%2Fnextcloud/test.docx

Change-Id: I0f2a84ff29fffd87ef059727bfb530bb54ab2ab9
Reviewed-on: https://gerrit.libreoffice.org/84936
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-12-11 13:22:49 +01:00
Andras Timar
d6e55afc4b android: add pot file for localization 2019-12-11 11:24:03 +00:00
Jan Holesovsky
0cd43ead59 android: Make the localization work for the JS pieces.
To have the menu translated.

Change-Id: I8d4d90d260aa3fcd80a8eb68515b22c58c9b3e18
Reviewed-on: https://gerrit.libreoffice.org/84931
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-11 11:49:37 +01:00
Jan Holesovsky
e628f26e87 android: Unregister the receiver from the right place.
Change-Id: Ifef497deb362ca23e16fb9ccd88c14b87770d963
Reviewed-on: https://gerrit.libreoffice.org/84930
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-11 11:48:47 +01:00
Jan Holesovsky
0b90f8cece android: Fix crash when starting a slideshow.
Change-Id: Iff5e4feaf4d1c496713a6401f6f03a17ae326ec5
Reviewed-on: https://gerrit.libreoffice.org/84905
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-10 23:05:12 +01:00
Jan Holesovsky
437074a853 android: Iterate according to the provider names again.
After commit 3dce52c307, this is the right
thing to do again.

Change-Id: I3c34ee258677af59bfc7a55abcb09c4b7f3611a2
Reviewed-on: https://gerrit.libreoffice.org/84903
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-10 22:20:49 +01:00
Jan Holesovsky
86350c62fe android: Cosmetics.
Change-Id: I9bdb97b6620dcecc5fb55a07c30309ceab6a4cc2
Reviewed-on: https://gerrit.libreoffice.org/84875
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-10 17:26:45 +01:00
Jan Holesovsky
2a1d62c6a7 android: Ultimately we want to have this working for both.
Currently it can open files both from the ownCloud and Nextcloud
storage, but so far it seems that it cannot save back to ownCloud.

Unfortunately both the libraries have the same namespace, so to have
both the ownCloud's and Nextcloud's library in the same .apk, we'll need
to use some additional tricks.

Change-Id: I7fd647a42d3bd90b6268017ae392d61f67f548c0
Reviewed-on: https://gerrit.libreoffice.org/84874
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-10 17:25:27 +01:00
Jan Holesovsky
3dce52c307 android: Completely hide the External SD and OTG.
Many reports said it was broken, so let's disable before anybody
actually tests it & fixes.

Change-Id: I179de3774c0fb4be018e59cd629936a9d565dc15
Reviewed-on: https://gerrit.libreoffice.org/84873
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-10 17:14:43 +01:00
Jan Holesovsky
07c3a7bdbb android: Implement uploading back to the cloud storage.
All these cases should be covered:

* user's explicit save via File -> Save
* autosave
* autosave on exit

Implemented via IntentFilter magic, we can call back from one activity
to the other to perform the actual saving in the shell.

Change-Id: I97d6e94028a9600a71f030af7146ee01163d09b8
Reviewed-on: https://gerrit.libreoffice.org/84872
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-10 17:14:03 +01:00
Jan Holesovsky
c6f36965cf android: Framework to be able to broadcast to another activity.
Change-Id: I24634c5e06223bd1c5cdb8da511159b03ce35719
Reviewed-on: https://gerrit.libreoffice.org/84871
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-10 17:10:29 +01:00
Jan Holesovsky
38b4af6eb5 android: Enable the Remote server again.
Change-Id: I321a7d7fa03eeb498acd4cf33ceba601f9ad0426
Reviewed-on: https://gerrit.libreoffice.org/84870
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-10 17:09:31 +01:00
Jan Holesovsky
9a6c6f767d android: Update the library for remote files to nextcloud/android-library.
The library bundled in the LibreOffice sources didn't work for me
neither with ownCloud nor with Nextcloud.

Change-Id: I88ee06bdffeed3229643575ffb274432582eaab8
Reviewed-on: https://gerrit.libreoffice.org/84869
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-10 17:08:56 +01:00
Jan Holesovsky
3ecc73d37f android: Set only English as the supported language for now.
Change-Id: I55a66b8e8f83252267fb9959cf563bc584fe682d
Reviewed-on: https://gerrit.libreoffice.org/84645
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
2019-12-06 23:35:55 +01:00
Jan Holesovsky
4ca81d1b2c android: Change the sort icon to distinguish it from the other.
Recommended by Pedro - thank you!

Change-Id: Ic4e0f42566a8d565d14c359cd479edf5ddc62525
Reviewed-on: https://gerrit.libreoffice.org/84643
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
2019-12-06 23:35:49 +01:00
Jan Holesovsky
6f49366f3c android: Disable OTG and Remote server for the moment, it's totally untested.
Change-Id: I64b7a5ded00fc9dd481972a13a4c3b169802498a
Reviewed-on: https://gerrit.libreoffice.org/84640
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-06 15:49:38 +01:00
Jan Holesovsky
1c8a31b33e android: Brand also the shell's About dialog.
Change-Id: I63b668ad92c688ec69818c058a787dbd94b5cc8b
Reviewed-on: https://gerrit.libreoffice.org/84630
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
2019-12-06 15:46:04 +01:00
Jan Holesovsky
799cb25c06 android: When I want to quit, I mean it.
I hate when apps make it hard to exit them.

Change-Id: I31c73a70fff6a87512debc95cbd31ef0ba8c1f62
Reviewed-on: https://gerrit.libreoffice.org/84354
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-03 14:53:35 +01:00
Jan Holesovsky
d7fb42008c android: Don't crash in the shell's About dialog.
Change-Id: I12a7fcc789299f9b4efa035bb665afc6c89c04cc
Reviewed-on: https://gerrit.libreoffice.org/84353
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-03 14:52:49 +01:00
Jan Holesovsky
d87f06adef android: Add possibility to brand the launcher icon.
Change-Id: I6cd531aab698236287eb7c20146caa61e34e8450
Reviewed-on: https://gerrit.libreoffice.org/84328
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-03 14:34:47 +01:00
Jan Holesovsky
5f9e088fe6 android: Replace the value in fonts with real name instead of 'null'.
Change-Id: Iefb5737662eb5463429951c815e5bb0891abd875
Reviewed-on: https://gerrit.libreoffice.org/84313
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-03 14:33:20 +01:00
Jan Holesovsky
888a9e56ab android: Back to using POCO.
It turns out that the std::filesystem is still not part of the NDK:
https://github.com/android/ndk/issues/609

The NDK has the header - but not the c++fs library yet :-(

Change-Id: Ic7003f71cd4730b2f34138adea3b09fe92fdbb4a
Reviewed-on: https://gerrit.libreoffice.org/82336
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-11-09 00:33:25 +01:00
Jan Holesovsky
13df611403 android: Allow specifying the versionCode from ./configure.
Change-Id: If3f618bd836d236e76bd4698321ec7314ebac1a4
Reviewed-on: https://gerrit.libreoffice.org/82177
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-11-07 09:39:48 +01:00
Jan Holesovsky
9830000feb android: Copy stuff from assets/unpack with every git commit change.
I've just spent many hours debugging why a type is not known to the
cppuhelper and is throwing a "cannot get type description for type ...".
It turned out it was just a stale .rdb on the device that avoided being
updated.

So this change will help developers (much lower risk of stale rdb
files), while not a problem for the releases (each version bump has to
update the rdb's anyway).

Change-Id: Ie73245cfc78da8faf97f08ef52e6358a8e71218d
Reviewed-on: https://gerrit.libreoffice.org/81707
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-10-29 20:51:08 +01:00
Jan Holesovsky
1813c272f2 android: Add hint about using pretty-printers.
Change-Id: Iffb53d4c4c8b78042840b99d54b28ce2b29c27ed
Reviewed-on: https://gerrit.libreoffice.org/81706
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-10-29 20:50:17 +01:00
Jan Holesovsky
473e52d27b android: Fix a linking problem.
This is needed after core.git's
f68a36b62ed327eb67efdfea0ac46645b4d90877, without it the native code
crashes:

E/AndroidRuntime: FATAL EXCEPTION: main

    Process: com.collabora.libreoffice.debug, PID: 25358
    java.lang.UnsatisfiedLinkError: dlopen failed: library "libc++_shared.so" not found
        at java.lang.Runtime.loadLibrary0(Runtime.java:1071)
        at java.lang.Runtime.loadLibrary0(Runtime.java:1007)
        at java.lang.System.loadLibrary(System.java:1667)
        at org.libreoffice.androidlib.LOActivity.<clinit>(LOActivity.java:467)
        at java.lang.Class.newInstance(Native Method)
        at android.app.AppComponentFactory.instantiateActivity(AppComponentFactory.java:95)
	...

Change-Id: If0d0f3ade3d2a5a8692dcc3d79edbfb51cd7e2ed
Reviewed-on: https://gerrit.libreoffice.org/81499
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-10-25 14:31:26 +02:00
Andras Timar
d1ae1b36c2 typo fixes in comments and code
Change-Id: Idd98516d30d98dea18eda9bbec8ac9777063b553
2019-10-08 11:49:45 +02:00
kaishu-sahu
0f9492268e android: add support for screen dimming from JS.
Change-Id: Icd766c7dcc9c2d62ec90945ec88fa46f88a4711d
Reviewed-on: https://gerrit.libreoffice.org/76489
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-09-06 11:23:29 +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
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
Jan Holesovsky
fd4d896a7f android: Rename the .xml files to avoid potential conflicts.
Change-Id: I6209309c038f16aff150494adf14953aa6f31541
2019-07-15 19:41:44 +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
Jan Holesovsky
b75adb8629 android: Corrected the .odp template.
Change-Id: Iaea2e4f47dd2252ee1d736bd8d49ed1bffe37381
2019-07-11 08:34:03 +02:00