Commit Graph

2024 Commits

Author SHA1 Message Date
Sunik Kupfer
ea5fc54003
Validate email before starting google oauth flow (#535)
* Validate email before starting auth flow (see #525, fixes #534)

* Simplify expression (minor change)

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2024-01-18 13:11:08 +01:00
Arnau Mora
0c834a5c42
Tasks intro page: "I don't need tasks" checkbox not visible in landscape mode (#530)
* Added optional modifier

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Fixed model argument name

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added bottom padding for bottom bar

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2024-01-16 23:11:39 +01:00
Arnau Mora
2ac81b6342
Darkened colors of accounts screen background image for dark mode (#529)
* Moved all colors to resources

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Darkened colors for night mode

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2024-01-15 09:45:46 +01:00
Arnau Mora
b8f4b9af30
Migrate DebugInfoActivity to Compose (#509)
* Gave more flexibility

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Migrated to Compose

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Adjusted paddings

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added missing observer

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* CardWithImagE: add another preview with subtitle, icon and content

* Made buttons uppercase

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Adjusted spacings

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Changed snackbar host state

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Changed nullable expression

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Using shareFile for zip

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Minor changes (comments/formatting)

* Switched to view instead of sharing files

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Adapted image height for landscape

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* CardView: allow to pass image alignment; use card_theme_max_height

* DebugInfoActivity: paddings, images

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2024-01-11 17:31:08 +01:00
Ricki Hirner
3c4601f7a1 WebDAV memory cache: store values using SoftReference (bitfireAT/davx5#515)
so that the values can be free if there's not enough memory
2024-01-11 13:48:18 +01:00
Ricki Hirner
357cf09be7
WebDAV: refactor paging and caches (bitfireAT/davx5#502)
* WebDAV: don't try to load 0-byte segments

* Extracted segmentation logic to SegmentedReader for testability

* Reorganize and simplify caches

* Refactor thumbnail cache

* Use coroutines with Dispatchers.IO instead of custom Executor

* Remove obsolete classes

* Fix tests, simplify DiskCache

* Paging reader: cache current page

* PagingReader tests

* Thumbnails: timeout for generation and not only for waiting

* openDocumentThumbnail: actually cancel HTTP request when method is cancelled

* Better KDoc

* Add further tests
2024-01-10 14:59:57 +01:00
darealdemayo
6ce0d35e6d
Add purelymail.com (#521) 2024-01-10 14:28:52 +01:00
Sunik Kupfer
24401cc990 Fix ProGuard issue with javax.xml.namespace.QName; update AGP (bitfireAT/davx5#512)
* Update to AGP 8.2.1
* Add keep rule for javax.xml.namespace.QName

See #511
Closes bitfireAT/davx5#499
2024-01-08 15:00:19 +01:00
Ricki Hirner
cf0c3040fc
Run uploadDirty() regardless of processLocallyDeleted() result (bitfireAT/davx5#510)
Run uploadDirty() regardless of whether processLocallyDeleted() did something or not
2024-01-05 11:16:50 +01:00
Arnau Mora
6b660c2be6
Rename LoginCredentialsFragmentFactory to LoginFragmentFactory (bitfireAT/davx5#507)
* Renamed LoginCredentialsFragmentFactory to LoginFragmentFactory

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Fixed fragment name

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Rename LoginInitFragment (managed) to ManagedLoginInitFragment

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2024-01-05 11:16:47 +01:00
Sunik Kupfer
20652b9325
NextcloudLoginFlowFragment: minor changes (sync bitfireAT/davx5#501)
---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2024-01-03 11:25:32 +01:00
Ricki Hirner
e5c73bead5
Downgrade AGP to 8.1.4 (fixes bitfireAT/davx5-ose#511) 2023-12-25 15:51:25 +01:00
Ricki Hirner
581622272c
Bump version to 4.3.12.1 2023-12-25 15:51:18 +01:00
Arnau Mora
09253a2454
Upgrade Compose Compiler to 1.5.7 (#510)
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2023-12-25 11:48:09 +01:00
Ricki Hirner
895f0a1541
Fetch translations from Transifex 2023-12-23 12:40:16 +01:00
Ricki Hirner
05360e818a
Version bump to 4.3.12 2023-12-23 12:34:06 +01:00
Ricki Hirner
5d7dea0ebf
Nextcloud Login flow: provide default DAV_PATH (/remote.php/dav) (#497) 2023-12-23 12:34:00 +01:00
Ricki Hirner
88238a2406
ConcurrentUtilsTest: fix testRunSingle_SameKey_Parallel (bitfireAT/davx5#494)
ConcurrentUtilsTest: changed testRunSingle_SameKey_Parallel to testRunSingle_SameKey_Nested
2023-12-20 14:34:53 +01:00
Ricki Hirner
357275fe83
Version bump to 4.3.12-rc.1 2023-12-20 14:02:08 +01:00
Ricki Hirner
e2ac368dbc
Update dependencies 2023-12-20 14:02:08 +01:00
Sunik Kupfer
532a143cc8
Add PasswordTextField Composable (taken from bitfireAT/davx5#437)
---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-12-20 13:55:13 +01:00
Arnau Mora
c087834452
Rewrite TasksFragment to Compose (#481)
* Added `CardWithImage`

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added `RadioWithSwitch`

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Migrating to Compose

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added observers

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Fixed functions signature

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added kdoc

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Removed layout

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Color for disabled

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added "don't show" behaviour

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added all tasks providers

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Moved checkbox to correct location

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Fixed don't need behaviour

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added theme

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added todo

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added support for link annotations

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added support for annotated strings and urls

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added tests for HTML annotation

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Extracted `linkStyle`

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Removed observers for requested

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Removed more observers

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added multiple links test

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Moved `installApp` to `TasksCard`

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Moved all model calls to composable

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Removed preview since not usable

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Got rid of TasksFragment

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Fixed import

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Switched link color to orange

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added missing copyright information

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Use HtmlCompat and existing Spanned.toAnnotatedString

* Added default content

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Renamed image content description

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Got rid of empty content

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Made summary of RadioWithSwitch composable

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Added missing entry point annotation

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Added click handling for tasks org

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Got rid of the preview provider

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Minor changes

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-12-15 13:09:42 +01:00
Ricki Hirner
da5b765b3a
WebdavMountsActivity: use ShareCompat.IntentBuilder (bitfireAT/davx5#490)
WebdavMountsActivity: use ShareCompat.IntentBuilder to create sharing intent
2023-12-15 12:23:00 +01:00
Ricki Hirner
c56461ea9e
WebDAV: allow other MIME types for (Ranged) GET, use coroutines for streaming (#503)
* StreamingFileDescriptor: use coroutines instead of threading

* WebDAV GET: accept any MIME type, but prefer known one
2023-12-12 14:39:43 +01:00
Arnau Mora
8a0e1151ec
Rewrite ExceptionInfoFragment into Compose (#485)
* Migrated dialog to Compose

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added extended compose icons

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2023-12-09 12:24:36 +01:00
Ricki Hirner
f2f40049b8 Update Kotlin, dependencies, Gradle 2023-12-09 11:56:00 +01:00
Ricki Hirner
7a259383be
Update dependencies, GoogleLoginFragment: use clickableText instead of legacy TextView 2023-12-06 13:14:32 +01:00
Sunik Kupfer
c3e980cabf
Sync add-account button code with bitfireAT/davx5#481
---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-12-05 16:07:01 +01:00
Ricki Hirner
d6861db8a6
Comment out testRefreshCollections_enqueuesWorker (bitfireAT/davx5#487) 2023-12-05 16:03:53 +01:00
Ricki Hirner
1854822757
RefreshCollectionsWorkerTest: wait for completion of enqueue (bitfireAT/davx5#486)
* RefreshCollectionsWorkerTest: wait for completion of enqueue

* Work may have finished already
2023-12-04 18:19:21 +01:00
Sunik Kupfer
787e1a687f
Set METHOD_ALERT on default event reminders (#493) 2023-12-03 21:12:56 +01:00
Ricki Hirner
fb7658cfaa
AboutLibraries: explicitly export library definitions at release (#485)
Export library definitions for release
2023-12-03 16:20:35 +01:00
Ricki Hirner
3eb8eba70c
Update AGP and dependencies 2023-12-03 16:15:57 +01:00
Ricki Hirner
fca6b5b890
Fetch translations from Transifex 2023-11-20 14:30:05 +01:00
Ricki Hirner
93cad92876
Version bump to 4.3.11 2023-11-20 14:29:15 +01:00
Ricki Hirner
8ddd3d66f0
Version bump to 4.3.11-alpha.2, CI: hopefully speed up release workflow 2023-11-20 14:28:41 +01:00
Ricki Hirner
ee637e4f6d
ForegroundService: don't use stopSelf or stopForeground (bitfireAT/davx5#462)
May fix #342
2023-11-16 13:21:34 +01:00
Michael Biebl
769825b402
AboutActivity: Add back no warranty disclaimer (#477)
This was dropped during the Compose rewrite.
Also align the copyright information as it looks better.
2023-11-15 17:39:41 +01:00
Ricki Hirner
a792d4db98 Version bump to 4.3.10 2023-11-14 13:11:48 +01:00
Ricki Hirner
ef723aa555 Fetch translations from Transifex 2023-11-14 13:11:36 +01:00
Ricki Hirner
f7fc82b801
Don't allow app name translation 2023-11-14 11:59:44 +01:00
Arnau Mora
59dc681fe4
AccountsActivity: disable sync button when there are no accounts (#473)
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2023-11-14 10:49:02 +01:00
Ricki Hirner
d22da0d230
Fetch translations from Transifex 2023-11-13 16:32:45 +01:00
Ricki Hirner
6829b3259f
Bump version to 4.3.10-rc.1 2023-11-13 16:31:01 +01:00
Ricki Hirner
2f761facc9
AccountSettings: don't throw IllegalArgumentException when reading/writing sync interval (bitfireAT/davx5#456) 2023-11-13 15:07:51 +01:00
Ricki Hirner
eeffbdcf6d
Go back to dnsjava 2.1.9 to avoid crashes on Android 7 (bitfireAT/davx5#454) 2023-11-13 14:32:34 +01:00
Ricki Hirner
2a9c27d4f7
AboutActivity: remove pager padding 2023-11-13 14:32:32 +01:00
Ricki Hirner
72f0579f41
Update dependencies 2023-11-13 14:32:29 +01:00
Ricki Hirner
449e886d49
AccountsActivity: center background image (fixes bitfireAT/davx5#434) 2023-11-13 10:30:46 +01:00
Arnau Mora
6055749e42
Fixed horizontal scroll (bitfireAT/davx5#447)
* Fixed sizing

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Small changes

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-11-12 11:34:50 +01:00
Ricki Hirner
0c1e4fd3cb
Version bump to 4.3.10-beta.1 2023-11-09 17:02:32 +01:00
Ricki Hirner
61c1ef8831
HTTP Workers: use runInterruptible instead of interrupting manually (bitfireAT/davx5#444)
* RefreshCollectionsWorker: use runInterruptible instead of interrupting manually

* SyncWorker: use CoroutineWorker + runInterruptible

* Use global SyncWorkDispatcher that guarantees classLoader to be set

* Set SyncWorkDispatcher for whole SyncWorker's doWork

* Remove obsolete test

* SyncManager: add structured concurrency again

* Use up to <number of processors> threads for synchronization

---------

Co-authored-by: Sunik Kupfer <kupfer@bitfire.at>
2023-11-09 17:02:27 +01:00
Ricki Hirner
42bd1e8449
Don't cancel service detection when DetectConfigurationFragment's view model is cleared (bitfireAT/davx5#442)
- Rewrite DetectConfigurationFragment to Compose
- Use coroutines and runInterruptible instead of Thread
- Only cancel service detection when back is pressed
2023-11-09 17:02:14 +01:00
Ricki Hirner
46615a8337
Version bump to 4.3.10-alpha.1 2023-11-09 17:02:12 +01:00
Ricki Hirner
518e5147fe
Rewrite AccountsActivity to Compose (bitfireAT/davx5#431)
---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Sunik Kupfer <kupfer@bitfire.at>
2023-11-07 17:22:44 +01:00
Ricki Hirner
9d739dd087
Clean up Hilt modules 2023-11-07 15:03:07 +01:00
Ricki Hirner
4a200dfbb7
Rewrite About activity to Compose (bitfireAT/davx5#432) 2023-11-07 14:52:42 +01:00
Ricki Hirner
cf9340107f
RandomAccessCallback.Wrapper: support multiple state machine instances at same time (bitfireAT/davx5#428)
* RandomAccessCallback.Wrapper: support multiple state machine instances at same time

- support multiple state machine instances at same time
- provide explicit Exception/error code when the remote server doesn't support ranged requests

* Only use RandomAccessCallback when server explicitly advertises range requests

---------

Co-authored-by: Arnau Mora <arnyminerz@proton.me>
2023-11-07 14:11:22 +01:00
Sunik Kupfer
fbe0c4451b
Add UiUtils method to render Spannables (from HtmlCompat) with Compose (bitfireAT/davx5#430)
* Add Spanned.toAnnotatedString, minor changes

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-11-01 12:00:14 +01:00
Arnau Mora
ca26155eed
jtxBoard collections: honor "Manage calendar colors" account setting (bitfireAT/davx5#427)
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2023-10-31 16:11:55 +01:00
Ricki Hirner
1a36ee2d60
Fetch translations from Transifex 2023-10-26 13:15:04 +02:00
Ricki Hirner
046bacff3f
Version bump to 4.3.9 2023-10-26 12:26:17 +02:00
Ricki Hirner
73475640f7
Google Login: minor UI improvements (bitfireAT/davx5#416)
- automatically append @gmail.com
- show Go IME action for login and client ID
2023-10-26 12:26:13 +02:00
Sunik Kupfer
1e6a457a0d
Fix related google calendars not being found (bitfireAT/davx5#409)
* Minor changes
- update kdoc
- rename method and variables

* Add proxy parents to related resource detection

* Rename argument, query ResourceType

* Remove unnecessary utility method

* Change parentOf to extension function; Always return URL with trailing slash

* Use calendar-proxy-read/write ResourceType from new dav4jvm

* Use max. two levels of recursion to detect shared Google calendars

* Revise test and adapt method

* Simplify HttpUrl.parent()

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-10-26 12:26:09 +02:00
Ricki Hirner
0215e98326
Version bump to 4.3.9-beta.2 2023-10-24 21:22:26 +02:00
Ricki Hirner
9dd8290004
Debug info: show periodicity and next run of sync workers (bitfireAT/davx5#415) 2023-10-24 21:22:22 +02:00
Ricki Hirner
8263b5fcf8
WorkManager: add stop reason to debug info and sync logs (bitfireAT/davx5#413) 2023-10-23 16:58:52 +02:00
Arnau Mora
fe679da03b
Refactor HiltViewModels ApplicationContext (#446)
* Simplified ViewModels

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Fixed injection

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Fixed settings injection

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added missing import

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Fixed application

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Fixed constructors and got rid of utils

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Optimized imports

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added missing annotation

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2023-10-19 17:36:11 +02:00
Ricki Hirner
f8330e8f52
dnsjava: fix R8 rules 2023-10-18 15:31:01 +02:00
Ricki Hirner
c451c3fd70
Version bump to 4.3.9-beta.1 2023-10-18 15:20:35 +02:00
Ricki Hirner
e41ac428c9
WebcalFragment: remove unused menu item code 2023-10-18 15:19:23 +02:00
Ricki Hirner
b26ae345cd
Nextcloud: pre-select contact group method (CATEGORIES) (bitfireAT/davx5#410)
* LoginActivity: refactor menu to MenuProvider; LoginModel: add contact group type

* Take LoginModel group method into account when creating the account; Nextcloud login: set preferred contact group type
2023-10-18 15:18:46 +02:00
Ricki Hirner
52747e632f
LoginActivity: add Nextcloud Login Flow (bitfireAT/davx5#403)
* Replace onActivityResult by contract

* Add Nextcloud option to default login screen

* Decouple NextcloudLoginFlowComposable from model

* UI and model changes

* Single-line URL field

* Add progress indicator and other secondary UI
2023-10-18 15:17:53 +02:00
Ricki Hirner
58d4a9f663
Make all IntroFragments appear at first start (#452)
* IntroFragments: use (factory,order) List instead of (order,factory) Map to store them

* Adapt OpenSourceFragment order
2023-10-17 18:50:42 +02:00
Ricki Hirner
8ffed42eb9
PermissionsIntroFragment: take jtx Board and tasks.org permissions into account (#450) 2023-10-17 10:17:17 +02:00
Arnau Mora
5ae70cb5d0
BatteryOptimizationIntroFragment: use contract instead of onActivityResult (#444)
* Using result launcher

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Minor re-ordering

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-10-16 15:31:17 +02:00
Arnau Mora
599c905610
Replace deprecated menu overrides (#443)
* Migrated to menu provider

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Removed override

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Cleanup

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Fixed menus

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Minor changes

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-10-16 15:30:26 +02:00
Ricki Hirner
c8cd6d780c
[WebDAV] Add timeout for RandomAccessCallback notification (bitfireAT/davx5#408)
* [WIP] Add timeout for RandomAccessCallback

* Use state machine to handle timeout

* Use sealed class for states, guard callback access with correct states
2023-10-16 11:10:46 +02:00
Arnau Mora
4ce6fcbf44
Replaced all onBackPressed usages (bitfireAT/davx5#406)
* Replaced all `onBackPressed` usages

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added missing finish

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added more finish statements

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2023-10-10 18:43:44 +02:00
Sunik Kupfer
3da48ab3a2
362 increase minimum api level to android 7 (bitfireAT/davx5#363)
* Increase minSdkVersion to 24 (Android 7.0)

* Remove obsolete api level checks

* Use latest dnsjava

* Use latest apache commons

* Minor formatting

* Unify getSystemService() calls

* Remove further unnecessary calls

* Remove noinspection GradleDependency for Apache Commons libs

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-10-10 18:43:24 +02:00
Arnau Mora
0ba00d7bb0
Migrated startActivityForResult (bitfireAT/davx5#407)
Migrated activity result

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2023-10-10 18:42:20 +02:00
Sunik Kupfer
6d30ef42e4
Foreground service: startForeground() within 5 seconds to avoid exception (bitfireAT/davx5#405)
* Call startForeground in onCreate

* Add stopSelf() and comments

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-10-10 10:18:22 +02:00
Ricki Hirner
088136ded7
Version bump to 4.3.8 2023-10-09 12:58:09 +02:00
Ricki Hirner
caf04c4c45
Fetch translations from Transifex 2023-10-09 12:40:35 +02:00
Sunik Kupfer
81fbe2b7a6
Use worker names as work tags (bitfireAT/davx5#404) 2023-10-09 12:38:43 +02:00
Ricki Hirner
437fb30a94
Rename java sources directories to kotlin 2023-10-07 10:22:08 +02:00
Ricki Hirner
e85727e869
Update dependencies 2023-10-07 10:18:53 +02:00
Ricki Hirner
f57cd77ced
Update dependencies, bump version to 4.3.8-alpha.1 2023-10-06 12:58:46 +02:00
Sunik Kupfer
6bbdcb332f
Include address book account syncs, when querying sync status (bitfireAT/davx5#378)
* Use tags instead of uniqueWorkNames for work queries.

* Also include address book accounts, when querying sync status.

Give address book account sync workers their parent (main account) sync workers tag too, such that they will be included at the query for sync status of their parent account.

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-10-06 12:52:42 +02:00
Ricki Hirner
fd4872adb5
Minor connectivity/VPN UI adaptions (bitfireAT/davx5#391)
* Low storage: don't show notification anymore, adapt info message

- The impact of low storage is not as critical anymore that a notification is required.
- Info message adapted

* Update "account settings: ignore VPN" strings

* Update "No internet" string
2023-09-27 13:54:48 +02:00
Ricki Hirner
ba310762f9
Repair beta feedback (bitfireAT/davx5#394)
- use Google Play In-App Review API for private feedback on -gplay (fall back to email)
- start email intent again when "beta feedback" is selected in navigation drawer
2023-09-27 13:54:41 +02:00
Ricki Hirner
02c401b4d5
AccountActivity: animate progress bar becoming invisible (bitfireAT/davx5#366)
* [WIP] Animate invisibility

* Reordered for cleaner look

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Fixed animation

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Reduced animation time for going to visible to 0

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Remove logging

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Arnau Mora <arnyminerz@proton.me>
2023-09-22 17:38:27 +02:00
Arnau Mora
48327e44f5
AccountActivity: make content underneath FABs accessible (bitfireAT/davx5#390)
* Doubled bottom padding

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Account activity: increase margin for two FABs even more

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-09-22 17:38:21 +02:00
Ricki Hirner
4faecc653f
Fetch translations from Transifex 2023-09-22 15:57:01 +02:00
Ricki Hirner
7be6e0636b
Bump version to 4.3.7 2023-09-22 15:53:00 +02:00
Ricki Hirner
b8e4ba62f5 Update dependencies, bump version to 4.3.7-rc.1 2023-09-21 18:53:36 +02:00
Arnau Mora
651ab9c53c
Fixed empty translators.json (#401)
* Update translators.json

* Added JSON parsing try-catch

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Log complete exception

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-09-12 13:03:46 +02:00
Sunik Kupfer
464ba7d76e
Tests for ConnectionUtils (bitfireAT/davx5#372)
* Add tests for internetAvailable()

* Add tests for wifiAvailable()

* Add TODO for test case

* Add tests for internetAvailable() covering multiple network connections

* Minor KDoc

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-09-11 11:41:41 +02:00
Angus Gratton
52e26e34d5
DavDocumentsProvider: Log a warning for responses of type OTHER. (#400)
If a WebDAV server is misconfigured (for example, behind an HTTP proxy that
strips a URL prefix and doesn't correctly forward this to the WebDAV server)
then PROPFIND can return resources whose URLs don't match the request URL. These
are resolved by dav4jvm as HrefRelation.OTHER.

Currently this situation produces no output at all in DAVx5 (logs or app) and
the WebDAV share appears accessible but empty. It is possible to create files in
the share, but not to see them again afterwards!

Of course a misconfigured server isn't the WebDAV client's responsibility to
resolve, but adding a warning in the log provides an extra clue for anyone
trying to debug it.
2023-09-08 13:48:39 +02:00
Ricki Hirner
0c991288d5 Bump version to 4.3.6.1 2023-09-07 00:29:39 +02:00
Ricki Hirner
f1a1d0efd8 Fix bug where sync isn't possible as soon there's any connection without INTERNET (bitfireAT/davx5#370)
Fix bug where sync wasn't possible as soon there's any connection without INTERNET (bitfireAT/davx5#369)
2023-09-07 00:29:23 +02:00
Ricki Hirner
56deab70ee Version bump to 4.3.6 2023-09-06 16:50:09 +02:00
Sunik Kupfer
5640250359 Wait an appropriate delay before SyncWorker retries after soft errors (bitfireAT/davx5#337)
* Use appropriate delayUntil value for retrying syncs on 503s.

Crop server suggested retryAfter value to self defined min/max values and use a reasonable default value if non-existent.

* Add tests for getDelayUntil

* Wait appropriate delay, before retrying sync after a soft error happened

* Increase max and default sync delays after soft errors

* Increase initial backoff time for SyncWorker retries

* Minor getDelayUntil changes

* Minor changes

- store delayUntil in seconds
- pass duration instead of timestamp to Thread.sleep
- other minor changes

* Use Instant instead of Long timestamps

* Correct calculation of blocking duration

* Indicate soft error occurred on 503 server message

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-09-05 20:30:52 +02:00
Ricki Hirner
b670979f12 Fetch translations from Transifex 2023-09-05 20:30:30 +02:00
Ricki Hirner
251cf1b2e9
Update dependencies (including vcard4android), bump version to 4.3.6-rc.1 2023-09-05 10:42:33 +02:00
Ricki Hirner
4ad54cd28b
Update dependencies (including cert4android and vcard4android) (bitfireAT/davx5#360)
* Update dependencies (including cert4android and vcard4android)

* Migrated to new version of ical4android

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Increased compileSdk

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Upgraded browser

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Only use `appInForeground` for `customCertsUi`

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Removed unnecessary variable and fixed trust manager

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Cleaned up trust manager factory

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Update dependencies (including cert4android and vcard4android)

* Migrated to new version of ical4android

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Increased compileSdk

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Upgraded browser

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Only use `appInForeground` for `customCertsUi`

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Removed unnecessary variable and fixed trust manager

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Cleaned up trust manager factory

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Minor changes

* Fixed build for SDK 34

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Migrated certificate trusting

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* NetworkConfigProvider: handle invalid trusted certificate

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Arnau Mora <arnyminerz@proton.me>
2023-09-05 10:41:54 +02:00
Sunik Kupfer
1c419cd75c
Add setting to ignore VPNs at connection detection (bitfireAT/davx5#356)
* Add setting to ignore VPNs at connection detection

* Minor changes

- move methods to ConnectionUtils to keep SyncWorker class compact
- always use "ignore VPNs" as Boolean
- other minor changes

* Show ignore VPNs setting only below api lvl 23

* Change strings

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-09-05 10:38:38 +02:00
Arnau Mora
795ae49da4
SyncWorker "soft error (max retries reached)" notification confusing for users (bitfireAT/davx5#353)
* Sync error notification dismiss

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* FIXME

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added click intent

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Delayed error info

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added tag for max retries

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Reduced priority

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Removed max retries tag

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Using account name as tag

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added authority to notification tag

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added account type to notification tag

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Changed priority to min

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2023-09-05 10:37:08 +02:00
Arnau Mora
bd7b2714d2
Upgrade AGP to 8.1.1 (bitfireAT/davx5#355)
* Upgrade AGP to 8.1.1

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Upgrade Kotlin and dependencies

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Downgrade browser

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2023-09-05 10:37:00 +02:00
Ricki Hirner
273deecbe4 Update dependencies 2023-08-16 22:59:20 +02:00
Arnau Mora
a375a16edf Added tooltip to sync collections FAB (bitfireAT/davx5#340)
* Added tooltip to sync collections fab

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Greyscale tint for collections sync FAB

* Always use TooltipCompat for FAB tooltips

Closes bitfireAT/davx5#339

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Sunik Kupfer <kupfer@bitfire.at>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-08-15 18:23:27 +02:00
Sunik Kupfer
4ce33e949b Use AccountManager.setAndVerifyUserData extension method, instead of setUserData (bitfireAT/davx5#344)
Hopefully fixes bitfireAT/davx5#308

* Add new setAndVerifyUserData extension function to AccountManager
* Use new setAndVerifyUserData extension function instead of insecure setUserData
* Update KDoc [skip CI]

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-08-15 18:23:00 +02:00
Ricki Hirner
fcb9d7f560 Fetch translations from Transifex 2023-08-07 20:45:55 +02:00
Ricki Hirner
3709c2ab32 Version bump to 4.3.5.2 2023-08-07 20:44:00 +02:00
Ricki Hirner
8aeb2d5064 Fix onPerformSync crash on InterruptedException (bitfireAT/davx5#343)
- use Kotlin and CompletableDeferred instead of Java synchronization
- signal cancellation by completing CompletableDeferred instead of Thread.currentThread.interrupt()
2023-08-07 20:43:51 +02:00
Arnau Mora
f806122b00 Upgrade AGP to 8.1 and configure per app language (bitfireAT/davx5#338)
* Upgraded AGP

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Enabled automatic locale config generation

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added fallback language

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added legacy service

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added `Accept-Language` header to custom tabs

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Nextcloud Login Flow/Google OAuth: also send language tag for default locale

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-07-28 10:53:57 +02:00
Ricki Hirner
4f192c253d Use KSP for Room (bitfireAT/davx5#333) 2023-07-27 18:20:44 +02:00
Ricki Hirner
7038bbf70a
Google OAuth: fix manifest merging so that intent-filter for OAuth callback is included again (#367) 2023-07-27 18:13:57 +02:00
Ricki Hirner
b7e00fac40 Fetch translations from Transifex 2023-07-22 12:23:44 +02:00
Ricki Hirner
13d9ce089b Bump version to 4.3.5.1 2023-07-22 12:22:28 +02:00
Ricki Hirner
d74e8da5c1 Update dependencies 2023-07-22 12:22:26 +02:00
Arnau Mora
a2b633edc0 Updated Google login button (bitfireAT/davx5#332)
* Updated Google login button

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Moved Google G logo file

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Changed background color

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Amend warning sign [skip CI]

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-07-22 12:22:22 +02:00
Ricki Hirner
162c9effe0 Update to latest dav4jvm (uses Java 8 Time API) (bitfireAT/davx5#329)
Fixes WebDAV file timestamps always being null (see bitfireAT/dav4jvm#22)
2023-07-14 23:11:44 +02:00
Arnau Mora
c62874a34b Make "Refresh collection list" more visible (bitfireAT/davx5#266)
* Added refresh collections fab

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Added listener for clicks on refresh collections fab

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Adjusted sizing

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Updated tooltip and description for collections sync

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Removed Snackbar

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added warning for null serviceId

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Changed refresh collections service id fetching method

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Tooltip updates on refresh collections list

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Migrate to ViewPager2; show "Refresh collections" for WebCal, too

* Added refresh collections fab

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Added listener for clicks on refresh collections fab

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Adjusted sizing

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Updated tooltip and description for collections sync

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Removed Snackbar

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Added warning for null serviceId

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Changed refresh collections service id fetching method

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Tooltip updates on refresh collections list

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Migrate to ViewPager2; show "Refresh collections" for WebCal, too

* Changed collections refresh action update method

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Use lambda syntax for observers

---------

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
Co-authored-by: Sunik Kupfer <kupfer@bitfire.at>
2023-07-14 23:11:32 +02:00
Ricki Hirner
36e377001f
Clean up unused resources
- also fixes some wrong resources
2023-07-11 11:47:16 +02:00
Ricki Hirner
400d46fce2
Amend comments for repository identity 2023-07-10 15:22:24 +02:00
Ricki Hirner
ec34da1ace
Google Login: add Limited Use policy (bitfireAT/davx5#327) 2023-07-10 15:14:21 +02:00
Ricki Hirner
bb6ed7ec64
Fetch translations from Transifex 2023-07-10 15:13:23 +02:00
Ricki Hirner
042b2371fb
Version bump to 4.3.5 2023-07-10 15:12:04 +02:00
Ricki Hirner
5272943a05
Google: use new API base URL (bitfireAT/davx5#324)
Google: use new API base URL (finds secondary calendars and homesets)
2023-07-07 11:30:22 +02:00
Sunik Kupfer
318939e970
Ensure internet connection before syncing (bitfireAT/davx5#305)
* Comment out failing test

* Check internet connection before syncing for API 23+

* [Skip CI] Amend comments

* Comment out whole test class

* Comment out whole test class

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-07-06 23:45:08 +02:00
Ricki Hirner
1478306e54
Comment out failing test 2023-07-06 23:45:06 +02:00
Sunik Kupfer
c7ff42c03f
[Google OAuth] fix Re-authentication crash (bitfireAT/davx5#319)
* Hide/Show auth settings instead of removing them prevents NPE

* Provide original OAuth login email as default value for GoogleLoginFragment started from account settings

* Account settings: explicitly trim empty user name to null

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-07-06 23:45:01 +02:00
Ricki Hirner
17ccb305f9
Configuration detection: allow null Credentials (anonymous login) (bitfireAT/davx5#323) 2023-07-06 23:44:11 +02:00
Sunik Kupfer
37a7ebb9c0
Fix test again (bitfireAT/davx5#321) 2023-07-06 23:44:08 +02:00
Sunik Kupfer
1c403d171c
Fix test (bitfireAT/davx5#320) 2023-07-06 23:44:00 +02:00
Arnau Mora
81273f028e
Added known base urls (bitfireAT/davx5#315)
* Added known base urls

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Change order

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-07-03 12:07:57 +02:00
Sunik Kupfer
fac68680ee
Block sync adapter's onPerformSync until SyncWorker finishes (bitfireAT/davx5#278)
* Block sync framework until SyncWorker finishes

* Bump version code for 4.3.3 (previous version code was never released publicly)

* Fetch translations from Transifex

* Release internal version automatically [skip ci]

* Update periodic sync workers when "Sync only on WiFi" flag is changed (#282)

* Update periodic sync workers when "sync only on WiFi" flag is changed
* Remove BootCompletedReceiver which was only needed to repair sync intervals (not required with WorkManager anymore)

* Bump version code to 403030006 (stays 4.3.3)

* Use unique worker name, Java notify/wait and observeForever

* Remove observer when sync finished

* Catch and ignore, but log interruption exceptions

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-07-03 12:07:39 +02:00
Ricki Hirner
46488f1618
Version bump to 4.3.5-alpha.1; update Compose; move GoogleLoginFragment to fix build 2023-06-30 13:51:09 +02:00
Sunik Kupfer
0f92b0fb05
291 clean up oauth mess (bitfireAT/davx5#307)
* Move GoogleOAuth members into GoogleLoginFragment

* Require login flow capable browser and notify user if missing

* Receive AppAuth redirects only in standard and gplay flavor

* Set davx5 as user-agent for AppAuth connection builder

* Re-authentication in Account settings

* Catch unauthorized exceptions at collection refresh and notify user to re-authenticate

* Suggest email address on account creation

* Set contact groups default setting as per-contact categories for oauth logins

* Add authentication to debug info, minor other changes

* Better error handling; don't pre-set group type

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-06-30 12:53:16 +02:00
Ricki Hirner
6a2c366358
Update dependencies; CI: don't checkout submodules 2023-06-28 22:42:24 +02:00
Arnau Mora
4ba50b969a
Migrated to ical4android library (bitfireAT/davx5#302)
* Migrated to ical4android library

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Manually excluded Groovy

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Updated ical4android

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Update dependencies

* Added more exclusions

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Also update Room [skip CI]

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-06-28 22:30:53 +02:00
Arnau Mora
11c8866614
Security: check/fix DebugInfoActivity: Uncontrolled data used in path expression (bitfireAT/davx5#267)
* Passing file name to `EXTRA_LOG_FILE` instead of path. Replaces illegal chars

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Removed log file extra

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Removed log file extra

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Added more error logging

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Update KDoc, remove strings

* Moved ViewModel initialization to Factory

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Changed ViewModel factory

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Updated annotations

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Handle EXTRA_LOGS correctly

---------

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-06-28 12:52:57 +02:00
Arnau Mora
3ba463dbd4
Removed Twitter from navigation drawer (bitfireAT/davx5#312)
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2023-06-26 08:53:19 +02:00
Arnau Mora
f820e92d15 Integrate vcard4android as an android library (bitfireAT/davx5#300)
* Migrated to external dependency for vcard4android

Signed-off-by: Arnau Mora <arnyminerz@proton.me>

* Removed vcard4android submodule

* Update vcard4android version, remove from settings.gradle

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-06-14 14:21:10 +02:00
Ricki Hirner
1b521e3c17 Bump version code 2023-06-13 21:01:10 +02:00
Ricki Hirner
50cb223bb6 DavResourceFinder: make input arguments explicit (bitfireAT/davx5#298) 2023-06-13 21:00:56 +02:00
Ricki Hirner
764c382af3 Fetch translations from Transifex 2023-06-13 18:47:08 +02:00
Ricki Hirner
aed721409f Bump version to 4.3.4.1 2023-06-13 18:43:06 +02:00
Ricki Hirner
24a3954d75 Google OAuth: fix endless loop in Fragment (bitfireAT/davx5#295)
Fix endless loop
2023-06-13 18:40:49 +02:00
Sunik Kupfer
ba36d01e11 [Google OAuth] Support custom Client IDs (bitfireAT/davx5#294)
* Support custom Client IDs

* Refactoring

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-06-13 18:39:40 +02:00
Ricki Hirner
ff4af11bcf
Minor HttpClient change 2023-06-11 14:30:48 +02:00
Ricki Hirner
66c93414c0
Fetch translations from Transifex 2023-06-11 14:30:24 +02:00
Ricki Hirner
278171dbac
Bump version to 4.3.4 2023-06-11 14:29:28 +02:00
Ricki Hirner
5b38943205
Support OAuth for Google (bitfireAT/davx5#289)
* Proof of concept (without auth state storage)
* Implement Bearer authentication, create network package
* Properly create/dispose AuthService
* Use proper ActivityResultContract
* Integrate into default login activity
* Change client ID to davx5integration@gmail.com
* Google Login: adapt login view
* Fix tests
* Don't allow empty Google account
* Move strings to resources
2023-06-11 14:17:50 +02:00
Sunik Kupfer
1b3fde0854 280 fix problematic toasts (bitfireAT/davx5#283)
* When renaming show a toast when account with new name exists already

* Replace toasts with snackbars

* Apply code styling hints

* Move lambdas out of parentheses

* Inject application instead of context

* Replace Toast with Snackbar

* Shorten messages shown in snackbars

* Show Toast in UI instead of model; use AndroidViewModel

* Move account name check out of lock; don't close activity if not successful

* Duplicate account name check: only check for our account type

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-06-09 17:26:11 +02:00
Sunik Kupfer
caf7be5e11
New setting to preselect only personal collections (bitfireAT/davx5#276)
* Add new preselect_collections option and deprecate sync_all_collections option

* Optimize imports

* At refresh, decide on whether a collection should be preselected

* Add preselect_collections_blacklist setting and restriction

* Adhere to preselect_collections_blacklist setting

* Add preselect_collections values

* Also check for empty regex string and use new setting values

* Add unit tests

* Remove sync_all_collections setting and restriction

* Blacklist nextclouds recently contacted addressbook in restriction and setting by default

* Improve kdoc

* KDoc, changed setting names, minor code optimizations

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-06-06 21:03:50 +02:00
Ricki Hirner
3b2246e74b
Bump version code to 403030006 (stays 4.3.3) 2023-06-01 19:12:47 +02:00
Ricki Hirner
12902a051f
Update periodic sync workers when "Sync only on WiFi" flag is changed (bitfireAT/davx5#282)
* Update periodic sync workers when "sync only on WiFi" flag is changed
* Remove BootCompletedReceiver which was only needed to repair sync intervals (not required with WorkManager anymore)
2023-06-01 19:12:41 +02:00
Ricki Hirner
bed762ab7d
Fetch translations from Transifex 2023-06-01 12:31:23 +02:00
Ricki Hirner
b56dd96fd8
Bump version code for 4.3.3 (previous version code was never released publicly) 2023-06-01 12:30:11 +02:00
jgirardet
cb5f722a87
Add mailo.com to known base urls (#329)
* Add mailo.com to known base urls

* fix order
2023-05-31 09:51:04 +02:00
Arnau Mora
17718a7ed8
Integrate cert4android as an android library (bitfireAT/davx5#274)
* Removed `cert4android` submodule

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Added cert4android dependency

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Update dependencies, fix invalid style

---------

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-05-30 11:10:06 +02:00
Arnau Mora
6d278b7e04
Made collection url selectable (bitfireAT/davx5#275)
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
2023-05-23 17:02:33 +02:00
Sunik Kupfer
ae303e3e8d
Refactor queryHomeSets method for clarity (bitfireAT/davx5#270)
* Make it clear that the first call of recursive method queryHomeSets is for the current-user-principal home set

* Update whitespace in kdoc

* Update kdoc
2023-05-23 17:02:26 +02:00
Ricki Hirner
38cfd200b1
Fetch translations from Transifex 2023-05-22 08:27:33 +02:00
Ricki Hirner
968db83366
Version bump to 4.3.3 2023-05-22 08:26:46 +02:00
Ricki Hirner
5fee2375a5 Update dependencies, bump version to 4.3.3-rc.1 2023-05-17 18:13:27 +02:00
Sunik Kupfer
a072cf0404 Add last synced time to collection properties (bitfireAT/davx5#260)
* Add last synced time to collection properties

* Show last synced time for every to the collection relevant authority

* Try finding the application name for given package name

* Resolve authority to package name before finding application label

* Use AndroidViewModel instead of ViewModel; change model LiveData to val

* Rewrite to Compose, use relative time description

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-05-17 18:13:27 +02:00
Ricki Hirner
2f1757bb78 Version bump to 4.3.3-beta.2
- minor workflow changes
2023-05-17 18:13:27 +02:00
Ricki Hirner
55ee89529f Update dependencies, including cert4android and vcard4android 2023-05-17 18:07:17 +02:00
Ricki Hirner
b543dc9332 Fetch translations from Transifex 2023-05-12 10:50:46 +02:00
Ricki Hirner
28466ace46 Version bump to 4.3.3-beta.1 2023-05-12 10:49:38 +02:00
Sunik Kupfer
63f51c4b42 Account settings migration 13 to 14 (bitfireAT/davx5#262)
* AccountSettings: prevent redundant calls, move migrations to separate class

* Don't create AccountSettings while migrating

* Double thread sleep time to wait for sync framework to get disabled, and update logging

* Remove manual testing helper

* Fix tests

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-05-12 10:23:47 +02:00
Arnau Mora
9748b75671 Fixed toast threading (bitfireAT/davx5#256)
* Fixed toast threading

* Added `AndroidViewModel.context`

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Moved to `AndroidViewModel`

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Changed error invocation

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Added back constructor inject

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>

* Save Application with val instead of util method

* Use LiveData for error message

---------

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-05-11 18:41:07 +02:00
Sunik Kupfer
2ebb40b152 Implement proper network check before manual sync (bitfireAT/davx5#259)
* Implement proper network check before manual sync

Do a proper connectivity check, to show a message to the user, about the sync being scheduled for when connectivity is available, before enqueueing the SyncWorker.

* Update the sync status in accounts adapter to include pending syncs

This is relevant for when a manual sync is triggered without connectivity.

* Replace Toast by Snackbar

* Replace ViewModel by AndroidViewModel

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-05-11 18:40:29 +02:00
Ricki Hirner
2ff4b35bdb Use configuration cache to improve build speed (closes bitfireAT/davx5#248) (bitfireAT/davx5#255)
- disable per-app language preference for now (will be enabled again with bitfireAT/davx5#245)
- disable Jetifier (doesn't seem to be explicitly required for in-app rating API anymore)
- remove Locator dependency
- update ical4android
2023-05-10 13:20:57 +02:00
Ricki Hirner
7b2ffeb98e Update dependencies 2023-05-09 12:36:45 +02:00
Ricki Hirner
9917f7131a Comment out AccountSettingsTest for now because they cause strange failures 2023-05-07 08:03:21 +02:00
Ricki Hirner
1c474df606 Version bump to 4.3.3-alpha.1 2023-05-07 08:03:21 +02:00
Ricki Hirner
c3cd970581 Use Jetpack Compose for AboutLibraries (bitfireAT/davx5#246)
- add JetPack Compose dependencies
- use existing XML theme as Compose MdcTheme
- update AboutLibraries to newest version (uses Compose)
- embed AboutLibraries Compose into existing Fragment layout
2023-05-07 08:03:21 +02:00
Ricki Hirner
0bed00c05a Handle InvalidAccountException in SyncAdapterService 2023-05-07 08:03:21 +02:00
Sunik Kupfer
f9d6bb153c Workmanager scheduled sync (bitfireAT/davx5#216)
Closes bitfireAT/davx5#14

* extract WorkManager util functions and kdoc
* add PeriodicSyncWorker
* refactor and some kdoc
* use PeriodicSyncWorker and add todos
* allow SyncAdapter arguments to be passed to SyncWorker and have re-synchronization use SyncWorker
* handle sync cancellation in AccountSetting migration
* handle sync cancellation when account is renamed
* remove sync frameworks global sync setting and sync state awareness for the GUI
* Observe sync worker status in AccountListFragment
* Create setup for stepwise refactor of the sync adapters. This should keep the app from failing to build.
* Create new abstract BaseSyncer class for generic sync code. Adapt consumers and tests to use the new class.
* Move calender sync code to new CalenderSyncer class which is independent from the sync framework
* In CalendarSyncAdapterService pass sync requests from Sync Adapter Framework to SyncWorker
* Use CalenderSyncer in SyncWorker
* Move contacts sync code to new ContactsSyncer class.
* Move address book sync code to new AddressBookSyncer class
* Move jtx sync code to new JtxSyncer class
* Move tasks sync code to new TaskSyncer class
* Remove duplicate code in inherited sync adapters.
* Remove refactoring helper interface, duplicate generic sync code and some linting.
* Adapt tests for new Syncer class and move to the new package
* Remove remaining duplicate code in SyncAdapterService, add todos and edit kdoc.
* Move all the single line sync adapter services into one file.
* Remove concurrent sync runner code and its test, as we now use WorkManagers one time work requests.
* Remove SAF manual sync flag usage where unnecessary.
* Drop ability to prioritise collections for sync, as not used and hindering removal of sync adapter arguments.
* Pass simple string array to SyncWorker instead of bundle to simplify code.
* Restructure work query code.
* Get debug info from account settings and WorkManager.
* Write tests for PeriodicSyncWorker
* Test account creation will set a default sync interval for CardDAV and CalDAV
* Throw an exception if accountManager returns null for sync interval value
* Do proper interval check and add tests for AccountSettings
* Use work manager query to determine whether work is in a specific state
* [WIP] Add test to check that task provider is configured correctly on account creation
* Edit test checking that task sync is configured correctly on account creation with/without installed task app(s), by mocking TaskUtil
* Edit test such that it does not require a flaky flag
* Remove periodic sync when tasks app is uninstalled
* Bring back content triggered syncs
* Rename enqueueSyncWorker method to enqueue only for clarity
* Enable SyncAdapterFramework to cancel running SyncWorker
* Add test ensuring that SyncWorker.onStopped() interrupts the running sync thread
* Add retry policy sync on soft errors
* Check users sync conditions before enqueueing SyncWorker
* Add test for whether user sync conditions are treated correctly and kdoc
* Rename ambiguous shorthand "SAF" to "SyncFramework", as SAF usually means StorageAccessFramework
* Migration: Disable sync framework periodic syncs when interval is changed for specified authority
* Add Workers info to debug info
* Use WorkInfo.runAttemptCount to fail work after 20 soft errors
* Notify user if retry limit for soft errors has been reached
* Remove left over concurrency sync run tests prevention
* Migration: Continue to remove periodic sync framework syncs until user migration to PeriodicSyncWorker syncs is complete
* Kdoc and small changes
* Migration: Change to hard migration strategy
* Drop repairSyncIntervals method in favor of hard migration strategy
* Improve debug info of workers
* Remove sync framework periodic syncs, created by enabling content triggered syncs
* Change minimum sync interval to 15 min; minor other changes
* Fix tests
* Implement requested changes and update kdoc
* Add network connectivity restrictions to PeriodicSyncWorker
* Minor changes
* Move back sync classes to syncadapter package for now (can be separated later)
* Add KDoc
* Changes from review
* Rename test methods
* Add back global sync status warning

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-05-07 08:03:21 +02:00
Ricki Hirner
299fb27af4
Fetch translations from Transifex 2023-05-02 14:06:43 +02:00
Ricki Hirner
9c51dadce8
Version bump to 4.3.2 2023-05-02 13:57:31 +02:00
Ricki Hirner
ae3f5c8bab
Fix ProGuard rules for R8 (AGP 8.0) 2023-05-01 11:00:37 +02:00
Ricki Hirner
aa063adaba
Upgrade gradle, AGP, dependencies 2023-04-29 22:50:18 +02:00
Sunik Kupfer
c5b02d2bde
Log warning if principal URL does not provide CalDAV/CardDAV service (bitfireAT/davx5#242)
* Log warning if principal URL does not provide CalDAV/CardDAV service

* Unified log messages for identical cases

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-04-20 14:01:30 +02:00
Arnau Mora
61b6cd5e2e
Disabled GPS feature requirement (bitfireAT/davx5#241)
* Disabled GPS feature requirement

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Updated GPS feature comment

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

---------

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>
2023-04-18 11:11:04 +02:00
Ricki Hirner
aecabb9845
Update dependencies 2023-04-13 11:25:51 +02:00
Michael Biebl
16573e9ea6
Sync interval failure (#235)
* Fix log message

* Log a warning if repairing the sync interval failed
2023-04-12 11:41:24 +02:00
Ricki Hirner
e2bfda71bc
Use large runners for CI Android tests (#306) 2023-04-12 11:39:32 +02:00
Sunik Kupfer
874ad7b1c6
Handle error responses when querying principals for display names (closes bitfireAT/#237) (bitfireAT/#238)
* Add test with inaccessible principal

* Catch and log exceptions where server resource is inaccessible

* Catch and log every HttpException
2023-03-31 13:29:20 +02:00
Sunik Kupfer
fc17d0ed69
SettingsActivity resync now uses SyncWorker (bitfireAT/davx5#226)
* Alter the SyncWorker sync request to allow passing sync arguments along

* Request sync in SettingsActivity via SyncWorker instead of ContentResolver

* Don't use catch-all arguments as worker arguments

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-03-28 16:59:36 +02:00
Ricki Hirner
2f8340a646
SyncManager: fix logging string that always talked about address data even for events/tasks 2023-03-24 11:52:19 +01:00
Ricki Hirner
6050396a45
Update Transformations to new syntax (androidx.lifecycle:lifecycle-viewmodel-ktx:2.6) 2023-03-24 10:46:42 +01:00
Ricki Hirner
2503d92dca
Update dependencies, including ical4android (now ignores invalid properties)
Closes bitfireAT/davx5#165
2023-03-23 17:09:37 +01:00
Ricki Hirner
880abf024c
Fetch translations from Transifex 2023-03-20 13:10:34 +01:00
Ricki Hirner
83936b97ea
Bump version to 4.3.1.1 2023-03-20 12:58:10 +01:00
Ricki Hirner
50dbd66d3a
Version bump to 4.3.1 2023-03-13 18:01:20 +01:00
Arnau Mora
17fb1168cc
Generate locales with Locator (bitfireAT/davx5#218)
* Added locator plugin

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Removed old generator

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Updated source sets

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Added locator submodule

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Removed locator submodule

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Moving scripts

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Update dependencies

* Added `LocatorPlugin`

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Fixed locales generation

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Removed buildSrc

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Using plugin from Jitpack

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Using plugin from Gradle

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Removed comment

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Remove jitpack

---------

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-03-13 18:01:13 +01:00
Ricki Hirner
89a698e7b2
Bump version to 4.3.1-beta.1 2023-03-02 13:11:09 +01:00
Ricki Hirner
6dd0af2d7a
Update Kotlin and gradle plugin 2023-03-02 13:11:08 +01:00
Patrick Lang
29a97c85ff
Fixed language selector icon for night mode (bitfireAT/davx5#223)
Update ic_language.xml

Replaced tint by  android:tint="?attr/colorControlNormal">
2023-03-02 13:11:01 +01:00
Sunik Kupfer
9fee782968
Check sync workers properly (closes bitfireAT/davx5#217) (bitfireAT/davx5#220)
* check sync workers properly

* Move utils around

* Merge live data, instead of observing in view, to recalculate account list.

* Update LiveData with same value

* Remove unused context property.

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-02-28 10:28:52 +01:00
Sunik Kupfer
fe7a928064
Provide owner url in jtx collection (bitfireAT/davx5#221)
* provide owner url in jtx collection

* Updated contract, added owner displayname to collections sync

* Update ical4android

---------

Co-authored-by: Patrick Lang <72232737+patrickunterwegs@users.noreply.github.com>
2023-02-28 10:28:46 +01:00
Arnau Mora
fffb029362
Fixed missing languages and wrong display (bitfireAT/davx5#214)
* Displaying language with `displayName` instead of `displayLanguage`

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Added languages from `davdroid`

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Fixed wrong locale tags

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Using Map instead of list for language loading

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Typo

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Changed language loading logic

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Improved docs

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Moved method from `LangUtils`

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Using regex

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Added test for `resourceQualifierToLanguageTag`

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

---------

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>
2023-02-28 10:28:19 +01:00
Sunik Kupfer
b83d116f40
show real name of davowner (bitfireAT/davx5#208)
* add principal table with dao

* add principal table with dao

* collection saves ownerId instead of owner URL

* save and refresh principals

* show display name of collection owner in GUI

* show only the owner name (preferably) or respective url

* remove principals which do not own any collections

* Don't mock AppDatabase

* ensure we are really dealing with a principal and save it even without its display name

* ensure owner label is hidden when neither owner-displayname nor  owner-url are available

* save principal urls without trailing slash

* use a custom query to find principals without collections

* Some changes

- insertOrUpdateByUrl
- don't explicitly set id=0 when not necessary,
- make it work when there are already entries with trailing slahes
- added TODOs

* Small changes
- Update principal only if display name changed
- Rename methods
- Kdoc
- Tests

* stop using simple methods with vague names

* rename method insertOrUpdateOrGet to insertOrUpdate and leave existing kdoc for explanation

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-02-20 13:29:56 +01:00
Ricki Hirner
26961d9749
Update dependencies 2023-02-20 13:29:52 +01:00
Patrick Lang
7b34f8148f
jtx-board-2-3-new-recur-handling (bitfireAT/davx5#196)
* adapted JtxSyncManager, added new method in LocalJtxCollection

* minor code improvement

* inserting recurring entry as well, as the series might not have been processed yet

* version bump (preliminarily)

* version bump (preliminarily)
2023-02-20 13:29:44 +01:00
Ricki Hirner
f13164af41
Fetch translations from Transifex, tx config changes 2023-02-08 12:39:40 +01:00
Ricki Hirner
43b6b8b3db
Version bump to 4.3 2023-02-08 12:33:16 +01:00
Arnau Mora
6990479d18
Enabled automatic popup of the custom certificate dialog (bitfireAT/davx5#207)
* Enabled automatic popup of the custom certificate dialog

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Use chaining instead of .let

---------

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-02-08 12:32:29 +01:00
Ricki Hirner
1dd93ae43a
Collections fragment: cache paging data (bitfireAT/davx5#206)
Closes bitfireAT/davx5#205
2023-02-07 17:14:21 +01:00
Michael Biebl
179602df46
Drop duplicated .ForegroundService (#266)
Was added by mistake in cfee0f3461.
2023-02-07 17:13:04 +01:00
Ricki Hirner
412acbcc7d
Version bump to 4.3-rc.2 2023-02-03 21:08:24 +01:00
Ricki Hirner
dc207682a5
CollectionsFragment: Replace Kotlin flow by LiveData (closes bitfireAT/davx5#201) (bitfireAT/davx5#204) 2023-02-03 21:08:14 +01:00
Ricki Hirner
00235e12a4
Fetch translations from Transifex 2023-02-01 14:02:59 +01:00
Ricki Hirner
e283f5f34b
Version bump to 4.3-rc.1 2023-02-01 13:27:56 +01:00
Ricki Hirner
2349468b0b
Update dependencies, including ical4android 2023-02-01 13:27:55 +01:00
Sunik Kupfer
cf4b7891e3
fix collections vanishing and remove useless home set reference (bitfireAT/davx5#199) 2023-02-01 13:10:35 +01:00
Sunik Kupfer
ca62efa2aa
remove DaoTools (for syncing) (bitfireAT/davx5#190)
* add test fixtures

* Use direct DB access instead of DaoTools

* minor changes and kdoc

* minor changes and kdoc

* remove obsolete DaoTools, SyncableDao and IdEntity classes

* KDoc

* use hashmap instead of list and added kdoc

* always load from database

* add a test and make test structur more flexible for future tests

* minor KDoc

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-01-31 13:40:39 +01:00
Ricki Hirner
2661dbba34
Use Worker for account cleanup (bitfireAT/davx5#197)
* [WIP] Use Worker for account cleanup

* Remove AccountsUpdatedListener Hilt module

* Use 15 seconds, provide Hilt module for App creation
2023-01-28 21:09:58 +01:00
Ricki Hirner
954f4dcaa3
Debug info: count jtx Board tasks correctly (bitfireAT/davx5#195)
* Reformat code

* Use sync-adapter URI to count jtx Board entries

* Debug info: restrict entry counts per withSyncAdapter URI and not over WHERE clause
2023-01-28 21:09:49 +01:00
Ricki Hirner
6c8976f6ff
Version bump to 4.3-beta.1 2023-01-20 11:12:33 +01:00
Ricki Hirner
29b2b2372f
Catch SecurityException of notifications 2023-01-20 11:12:32 +01:00
Ricki Hirner
5156ff1380
Update dependencies 2023-01-20 11:12:32 +01:00
Sunik Kupfer
62617a2889
168 refactor service detection part 2 (bitfireAT/davx5#174)
* [WIP] refactor

* [WIP] refactor

* save, update and delete homesets one by one

* save, update and delete collections one by one

* cleaner code

* prevent jumps in row ids

* [WIP] small changes and kdoc

* remove duplicate code and add kdoc

* improve kdoc

* remove redundancy based on service type in resource finder

* tests setup

* handle cancellation

* add tests

* Don't use IdEntity for service detection anymore

* HomeSetDao: getByUrl requires a service (there may be two accounts with the same homeset URLs, for instance with different credentials)

* Deprecate DaoTools

* Minor changes

* Add TODO

* use self explanatory variables instead of a pair

* update kdoc

* add unfinished tests

* add test for updating a collection

* add test for preserving collection flags

* mark collections as homeless if not rediscovered in its homeset

* proper implementation of update and delete of homeless collections with test

* minor changes and kdoc

* Tests: adapt mock server 404

* KDoc

* get collections by service and url, deprecate getByUrl()

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-01-19 23:32:15 +01:00
Patrick Lang
df2922f873
Added intent-filter for AccountActivity (bitfireAT/davx5#187)
* Added intent-filter for AccountActivity

* removed intent filter for account activity
2023-01-19 23:31:57 +01:00
Flo Edelmann
861bcf30b4
Add dav.mailbox.org to known base URLs (#251)
* Add dav.mailbox.org to known base URLs

* Replace mailbox.org by dav.mailbox.org

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-01-11 23:51:35 +01:00
Arnau Mora
bee7cf20ac
169 webdav handle weak etags correctly (bitfireAT/davx5#185)
* Added `GetETag.NAME` fetching when `PROPFIND`ing

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* `GetETag.eTag` is only taken if tag is not weak

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Using `GetETag` instead of `QuotedStringUtils` and ignoring weak eTags

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Updated `dav4jvm`

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Fixed checks

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Use new dav4jvm where weak can't be null

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-01-09 17:57:04 +01:00
Sunik Kupfer
5434291c6c
fixes data saver warning showing below android 7 (bitfireAT/davx5#180)
post false to live boolean dataSaverEnabled even if below api lvl 24
2023-01-09 17:56:56 +01:00
Arnau Mora
53bd4866c3
Added Mastodon link to navigation drawer (bitfireAT/davx5#179)
* Added mastodon icon

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Added mastodon link to drawer

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Added mastodon link action

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Mastodon icon tint

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Added Mastodon icon to main

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>
2023-01-01 23:26:54 +01:00
Michael Biebl
1f4398b21e
Use consistent margins between different permission switches 2022-12-22 21:25:12 +01:00
Ricki Hirner
4c71d21d7b
WorkManager address book sync: don't run calendar/tasks sync on address book accounts; vcard4android: set N:LastName for vCard3 groups 2022-12-22 21:22:56 +01:00
Patrick Lang
1f818ee3b4
Added language selection (bitfireAT/davx5#137)
* added language selection

* PermissionsFragment: Hide notification permission switch on Android < 13

* Retrieve locales with a function

* Added locales flavoring

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Moved locales functions to `locales.gradle`

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Added `locales_config.xml` generation

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Now gets generated automatically

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Added `android:localeConfig`

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Updated submodules

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

* Using `logger` instead of `println`

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
Co-authored-by: Arnau Mora <arnyminer.z@gmail.com>
2022-12-22 21:22:55 +01:00
Michael Biebl
0521f4bcf0
Trivial indentation fixes (#226) 2022-12-22 21:22:55 +01:00
Ricki Hirner
2730d14cb9
Version bump to 4.3-alpha.1 2022-12-22 21:22:55 +01:00
Sunik Kupfer
cfee0f3461
work manager manual sync (bitfireAT/davx5#109)
* rabase with dev branch

* added test for checking whether manual work-manager sync queues worker

* overwrite getForegroundInfo to show a "sync running" notification, to run expedited work on Android <12

* basic error state with sensible feedback from syncframework

* remove integer state flags and pass SyncResult as string

* Manual sync cancellation

* rabase with dev branch

* Minor changes

- add Jtx Board sync adapter to sync worker
- use new notification ID for sync worker

* status bar reflects sync of SyncWorker and sync framework correctly

* [WIP] custom hilt SyncComponent

* fix autoclose cast not available below api24

* SyncScope implementation using WeakReference

* Remove unnecessary logging call

* AddressBooksSyncAdapter.sync uses SyncWorker instead of ContentResolve to call requestSync

* add some code documentation

* move all utility objects into one package

* Also check SyncWorker state for accounts list sync status bar

* clean up imports

* Remove duplicate copyright notices

* Minor changes

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2022-12-15 16:04:39 +01:00
Michael Biebl
262592a3d9
Remove duplicate copyright header (#218) 2022-12-11 17:03:27 +01:00
Ricki Hirner
18a3c0e2fd
Fetch Translations from Transifex 2022-12-10 13:20:31 +01:00
Ricki Hirner
5374afb7ae
Version bump to 4.2.6 2022-12-10 13:17:59 +01:00
Álvaro Brey
9ceee1b6c0
LoginSetupActivity: allow http/https in intent filter (#211)
* LoginSetupActivity: allow http/https in intent filter

Initially introduced in 054f1ece61,
this `intent-filter` breaks login from the Nextcloud app, as we send the server URI as `http`/`https`.

Signed-off-by: Álvaro Brey <alvaro.brey@nextcloud.com>

* Update intent-filter for login flow on api lvl 33 (closes bitfireAT/davx5#172)

Signed-off-by: Álvaro Brey <alvaro.brey@nextcloud.com>
Co-authored-by: Sunik Kupfer <kupfer@bitfire.at>
2022-12-08 17:48:13 +01:00
Sunik Kupfer
e6ecc7a9b0
Remove forced wifi-only sync when Data Saver is active (bitfireAT/davx5#171)
* Remove forced wifi-only sync when Data Saver is active

* move data saver warning to AppWarningsManager

* Minor changes

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2022-12-08 11:56:47 +01:00
Sunik Kupfer
1b17124b80
move warning notification logic into a warning class (bitfireAT/davx5#170)
* move warning notification logic into a warning class

* Move Warnings to UI package

* Minor changes

* Move "global sync disabled" warning to AccountListFragment, too

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2022-12-08 11:52:56 +01:00
Sunik Kupfer
02885947da
Refactor DavService to WorkManager (bitfireAT/#164)
* SyncManager: remove retry intent
* refactor DavService to RefreshCollectionsWorker now using WorkManager
* move DavResourceFinder to new service detection package
* Optimize imports

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2022-12-08 11:52:38 +01:00
Sunik Kupfer
405ef4d0b8 Version bump to 4.2.5 2022-11-29 15:09:24 +01:00
Sunik Kupfer
5e099561c1 Fetch translations from Transifex 2022-11-29 15:07:22 +01:00
Ricki Hirner
dd9ac77705 Add referrer with utm_source to task app installation Intents 2022-11-29 15:04:34 +01:00
Ricki Hirner
369d5e49f1
Update dependencies, version bump to 4.2.5-rc.1 2022-11-24 18:14:26 +01:00