Compare commits

..

469 Commits

Author SHA1 Message Date
Arnau Mora Gras
a25c8d2aa4 Merge branch 'main-ose' into move-gplay-variant-to-ose
# Conflicts:
#	gradle/libs.versions.toml
2025-12-03 16:03:47 +01:00
Arnau Mora
7c98085770 Import the gplay tests 2025-10-25 14:28:53 +02:00
Arnau Mora
81f96025b2 Merge remote-tracking branch 'origin/move-gplay-variant-to-ose' into move-gplay-variant-to-ose 2025-10-25 14:16:56 +02:00
Arnau Mora
1fd30f46dc Import the davdroid folder 2025-10-25 14:16:06 +02:00
Arnau Mora
51735d336e Added standard module 2025-10-25 14:10:12 +02:00
Arnau Mora
7cb3c9ecb9 Merge remote-tracking branch 'origin/move-gplay-variant-to-ose' into move-gplay-variant-to-ose 2025-10-25 14:09:58 +02:00
Arnau Mora
4bb4906662 Import standard module 2025-10-25 14:08:57 +02:00
Arnau Mora
135b35d32b Added missing gplay dependencies 2025-10-25 14:01:45 +02:00
Arnau Mora
b43b65c0de Add gplay flavor to build.gradle.kts 2025-10-25 13:54:37 +02:00
Arnau Mora
5cab10bb1f Move gplay variant to ose 2025-10-25 13:42:27 +02:00
Arnau Mora
913999b565 Show confetti after purchasing (#697)
* Add confetti after purchasing

* Updated sizes and shapes

* Fix confetti depth
2025-10-14 11:38:23 +02:00
Sunik Kupfer
7b42fbc419 Update billing API to 8.0 (#687)
* Update the Play Billing Library dependency version

* Update the implementation of the onProductDetailsResponse method.

* Maintain same functionality of enablePendingPurchases

* Enable automatic service reconnection

* Query product details as well when model initializes

* Use activity directly as context

* Warn instead of throwing when unable to acknowledge all purchases

* Show error messages when billing client unavailable

* Fix typo

* Rename method

* Simplify billingResult response code handling

* Add error message on purchase failure

* Move methods around; improve log statements and kdoc

* Return early in onProductDetailsResponse and add comments

* Refactor acknowledge process to use coroutine and notify user on failure.  Return early in processPurchases and update log statements.

* Change deprecated URI parse to toUri

* Update kdoc

* Show success message on acknowledged purchase

* Query product details with kotlin extensions

* Minor changes

- rename method
- rearrange
- update comment and kdoc

* Update kdoc

* Use activity directly as context replacement

* Add only distinct new purchases

* Remove descriptive variable

* Use injected io dispatcher
2025-09-18 14:59:57 +02:00
Ricki Hirner
ce3b04c4fc Fetch translations from Transifex 2025-09-03 15:42:54 +02:00
Ricki Hirner
92a865d990 Move external URIs from Constants to ExternalUris object (bitfireAT/davx5-ose#1574)
* [WIP] Move external URIs from Constants to ExternalUris object

* Update external URIs to use class names or screen name for stat params
2025-07-10 16:26:32 +02:00
Ricki Hirner
af631ba3d4 Move external URIs from Constants to ExternalUris object (bitfireAT/davx5-ose#1574)
* [WIP] Move external URIs from Constants to ExternalUris object

* Update external URIs to use class names or screen name for stat params
2025-07-10 16:26:32 +02:00
Ricki Hirner
e9e0ee051a Support Fastmail OAuth (bitfireAT/davx5-ose#1509)
* Add Fastmail OAuth login implementation

* [CI] Run tests on API level 36, too

* Add Fastmail OAuth login support

* Remove logging and move companion object to bottom

* Remove FastmailLogin and GoogleLogin to OAuthLogin and OAuthGoogle

- Remove FastmailLogin class
- Refactor GoogleLogin class to OAuthGoogle object
- Update AndroidManifest.xml to use ${applicationId} for OAuth redirect URI
- Add OAuthFastmail object for Fastmail OAuth integration
- Update GoogleLoginModel and FastmailLoginModel to use OAuthGoogle and OAuthFastmail respectively
- Add OAuthIntegration object for shared OAuth functionality

* Update Fastmail authentication error message and add redirect URI documentation

* Add error handling for refresh token exception
2025-06-05 12:07:34 +02:00
Ricki Hirner
9666851d3d Support Fastmail OAuth (bitfireAT/davx5-ose#1509)
* Add Fastmail OAuth login implementation

* [CI] Run tests on API level 36, too

* Add Fastmail OAuth login support

* Remove logging and move companion object to bottom

* Remove FastmailLogin and GoogleLogin to OAuthLogin and OAuthGoogle

- Remove FastmailLogin class
- Refactor GoogleLogin class to OAuthGoogle object
- Update AndroidManifest.xml to use ${applicationId} for OAuth redirect URI
- Add OAuthFastmail object for Fastmail OAuth integration
- Update GoogleLoginModel and FastmailLoginModel to use OAuthGoogle and OAuthFastmail respectively
- Add OAuthIntegration object for shared OAuth functionality

* Update Fastmail authentication error message and add redirect URI documentation

* Add error handling for refresh token exception
2025-06-05 12:07:34 +02:00
Ricki Hirner
404324f42a Fetch translations from Transifex 2025-05-30 16:27:06 +02:00
Ricki Hirner
37362b3a10 Move Hilt modules to .di package (#665)
Move Hilt module definitions to di package
2025-04-26 23:15:11 +02:00
Ricki Hirner
ce4e581456 Move Hilt modules to .di package (#665)
Move Hilt module definitions to di package
2025-04-26 23:15:11 +02:00
Ricki Hirner
b53468b911 Move Hilt modules to .di package (#665)
Move Hilt module definitions to di package
2025-04-26 23:15:11 +02:00
Ricki Hirner
db6846e97e Fetch translations from Transifex 2025-04-17 12:56:52 +02:00
Sunik Kupfer
a2e66c672f Skip login type selection when logging in via intent (bitfireAT/davx5-ose#1267)
* Move companion object to the end of class

* Skip login type selection when logging in via intent

* Skip login type page if not default login type

* Add test for implicit email intent

* Fix test

* Update KDoc

* Refactor URI handling in LoginActivity and StandardLoginTypesProvider

* Skip login type page if intent is clear, but don't skip when using defaultLoginType

* Log unclear intents

* Use data class instead of pair

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2025-02-12 18:02:38 +01:00
Ricki Hirner
d63eb1ade8 Fetch translations from Transifex 2025-02-02 14:58:52 +01:00
Ricki Hirner
008ddf37f2 Further unmockk after tests (+ build variants) 2025-01-27 16:54:17 +01:00
Ricki Hirner
a908a0e407 Fetch translations from Transifex 2025-01-25 12:55:52 +01:00
Ricki Hirner
947e92a6a5 Update AUTHORS and copyright notices (bitfireAT/davx5-ose#1232)
* Update AUTHORS

* Add Android Studio copyright profiles

* Update copyright notices
2025-01-16 15:15:37 +01:00
Ricki Hirner
cd2fef7cbc Update AUTHORS and copyright notices (bitfireAT/davx5-ose#1232)
* Update AUTHORS

* Add Android Studio copyright profiles

* Update copyright notices
2025-01-16 15:15:37 +01:00
Ricki Hirner
38571962ee Update AUTHORS and copyright notices (bitfireAT/davx5-ose#1232)
* Update AUTHORS

* Add Android Studio copyright profiles

* Update copyright notices
2025-01-16 15:15:37 +01:00
Ricki Hirner
45f938e22b Fetch translations from Transifex 2024-12-23 14:16:59 +01:00
Arnau Mora
a2e5141f78 Link to Managed DAVx5 in navigation drawer (#633)
Added managed drawer entry
2024-12-16 14:13:30 +01:00
Ricki Hirner
5b097ed910 Move icons to gplay 2024-11-29 16:20:47 +01:00
Ricki Hirner
b5e8bdcf92 Move icons to gplay 2024-11-29 16:20:47 +01:00
Arnau Mora
eeb582e7a9 Migrated XML drawables to ImageVector (#628)
* Migrated badges from XML to ImageVector

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

* Got rid of unused resources

* Migrated Mastodon icon to ImageVector

* Moved file to managed

* Rollback

---------

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
2024-11-29 11:40:31 +01:00
Arnau Mora
5601451e0e Migrated XML drawables to ImageVector (#628)
* Migrated badges from XML to ImageVector

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

* Got rid of unused resources

* Migrated Mastodon icon to ImageVector

* Moved file to managed

* Rollback

---------

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
2024-11-29 11:40:31 +01:00
Ricki Hirner
b4625bd95a Fetch translations from Transifex 2024-11-22 17:18:24 +01:00
Sunik Kupfer
96ea1df52e Refactor and adapt earn badges activity for dark mode (#618)
* Handle deprecation

* Handle deprecation

* Use flows instead of live data

* Remove hardcoded colors

* Fix bought badges display

* Use lazy vertical grid
2024-10-30 12:04:35 +01:00
Sunik Kupfer
96c5502d19 Add badges of 2024 (#616)
* Add badges

* Add remaining colors of two badges

* Fix color assignment
2024-10-28 13:30:45 +01:00
Ricki Hirner
d57829b2eb Fetch translations from Transifex 2024-10-17 16:14:58 +02:00
Arnau Mora
92b5245409 Fixed surface container color in dark theme (bitfireAT/davx5-ose#1069)
* Fixed surface color in dark theme

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

* Account screen: higher contrast for collection cards

* Account screen: use normal instead of elevated cards

* Adapt colors of card lists

---------

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2024-10-14 17:49:06 +02:00
Ricki Hirner
bfac9c627f Fetch translations from Transifex 2024-10-10 18:26:48 +02:00
Ricki Hirner
93d77d61cb Fix AppLinkUrl lint error in gplay, too (#610)
* Fix lint in gplay, too

- Add duplication notice (unfortunately we can't put it to davdroid/AndroidManifest.xml because multiple manifests per build variant are not supported by AGP)

* Add tools NS
2024-10-07 13:51:17 +02:00
Ricki Hirner
52e8edc769 Fix AppLinkUrl lint error in gplay, too (#610)
* Fix lint in gplay, too

- Add duplication notice (unfortunately we can't put it to davdroid/AndroidManifest.xml because multiple manifests per build variant are not supported by AGP)

* Add tools NS
2024-10-07 13:51:17 +02:00
Sunik Kupfer
375e1e9264 Ignore lint AppLinkUrlError (bitfireAT/davx5-ose#1053) 2024-10-03 18:04:05 +02:00
Arnau Mora
bfcea46458 ClickableText for URLs has been deprecated (bitfireAT/davx5-ose#1024)
* Got rid of `UrlAnnotation`

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

* Deprecated and suggested a ReplaceWith

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

* Optimized imports

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

* Replaced usages of `ClickableTextWithLink`

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

* Removed `ClickableTextWithLink`

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

* Migrated `ClickableTextWithLink`

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

* Remove experimental text api annotations

---------

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
Co-authored-by: Sunik Kupfer <kupfer@bitfire.at>
2024-09-16 15:06:57 +02:00
Ricki Hirner
d06511e7dc Reword login text (bitfireAT/davx5-ose#1026)
- Change empty accounts text
- Add privacy note to Login screen
- Changed last button text
2024-09-16 14:58:25 +02:00
Ricki Hirner
bbcaeed791 Fetch translations from Transifex 2024-08-05 17:43:09 +02:00
Ricki Hirner
07f79e2428 Remove obsolete Logger object (bitfireAT/davx5-ose#930) 2024-07-22 00:01:11 +02:00
Ricki Hirner
f7ca788045 Refactor SettingsManager/SettingsProvider to use DI properly (#599)
* Refactor SettingsManager/SettingsProvider to use DI

* Fix tests

* Remove BaseDefaultsProvider

* Fix gplay tests
2024-07-20 21:23:48 +02:00
Ricki Hirner
dac18ac0e6 Install uncaught exception handler in a separate startup plugin (#597) 2024-07-18 09:03:13 +02:00
Ricki Hirner
032711cfb3 Fetch translations from Transifex 2024-07-02 17:08:48 +02:00
Sunik Kupfer
eaff085abb Mock settings directly in EarnBadgesActivityTest (#582)
Mock settings for EarnBadgesActivityTest
2024-05-29 16:59:39 +02:00
Ricki Hirner
b5f8f50fc5 Update dark themes 2024-05-28 23:37:40 +02:00
Ricki Hirner
f6c42db2e8 Last M3 Tweaks (standard/gplay) (bitfireAT/davx5-ose#817)
* [WIP] Colors

* Update navigation drawer

* Update colors

* [WIP] PermissionSwitchRow night mode

* Fix PermissionSwitchRow icon in night mode

* Use more intense colors for FABs
2024-05-28 21:08:37 +02:00
Ricki Hirner
4e9888cb7f Update theme and style again to make it look like it used to look 2024-05-17 18:06:14 +02:00
Ricki Hirner
c33aa8a505 Fix translations from Transifex (again) 2024-05-17 15:22:09 +02:00
Ricki Hirner
1322654a42 Fetch translations from Transifex 2024-05-17 14:38:17 +02:00
Sunik Kupfer
fea09011f3 Fix setup through nextcloud app (intent) not working (bitfireAT/davx5-ose#782)
* Select nextcloud login type on nextcloud setup intent

* Fix linting error

* Add documentation

* Move model creation to compose LoginScreen

* Minor changes
- Use boolean to decide on skipping startPage
- Move login type selection logic to login types provider

* Minor changes

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2024-05-17 14:29:47 +02:00
Ricki Hirner
97791811bb [gplay] Fix tests 2024-05-17 13:38:22 +02:00
Ricki Hirner
c1cc52e1b8 Try different M3 theme 2024-05-17 13:11:14 +02:00
Ricki Hirner
8de85b74b6 Remove unnecessary resources 2024-05-16 18:27:40 +02:00
Ricki Hirner
ac09074811 Drop M2 (everything is M3 now) (bitfireAT/davx5-ose#797)
Drop M2
2024-05-16 17:56:54 +02:00
Ricki Hirner
3f16b606b4 Rewrite EarnBadgesActivity to M3 (without refactoring) 2024-05-16 16:56:01 +02:00
Ricki Hirner
827dbb641d Intro pages: use Hilt for dependency injection (bitfireAT/davx5-ose#779)
* Accounts: move syncAll to model; better Hilt usage

* Move calculation of whether IntroActivity is shown into AccountsModel

* Intro pages: inject dependencies with Hilt

* Fix preview
2024-05-04 20:18:16 +02:00
Ricki Hirner
aa6fea5914 Rewrite AccountsActivity to M3 (bitfireAT/davx5-ose#749 + flavor adaptions)
* [WIP] Rewrite AccountsActivity to M3

* [WIP] AccountsScreen: FAB, previews

* [WIP] Warning cards

* Adapt FABs
2024-04-26 13:55:34 +02:00
Ricki Hirner
ba5ddd6335 Rewrite AccountsActivity to M3 (bitfireAT/davx5-ose#749 + flavor adaptions)
* [WIP] Rewrite AccountsActivity to M3

* [WIP] AccountsScreen: FAB, previews

* [WIP] Warning cards

* Adapt FABs
2024-04-26 13:55:34 +02:00
Ricki Hirner
678eb6d8bb Rewrite Managed configuration screen to M3 (#576) 2024-04-24 10:30:56 +02:00
Ricki Hirner
f6c8c7242b Rewrite login to M3 and with better UI states (#567)
* [WIP] Rewrite login to M3 and better UI states

* Use AccountRepository to create account

* LoginModel is SSOT for page navigation

* Support forced group method

* Show progress bar when account is being created

* Make account name suggestions work again

* Use M3 text field supportText for errors

* Refactor: login by URL, login by email, advanced login

* Refactor Nextcloud login, move login flow logic to separate class

* Refactor Google login, move OAuth logic to separate class

* Fix errors when navigating back after successful resource detection

* Make PasswordTextField M3

* ManagedLogin: M3, UiState

* Updated theme; managed login functionality

* Improve back navigation
2024-04-21 16:20:08 +02:00
Ricki Hirner
4086103456 Add M3 theme and apply to AboutActivity (bitfireAT/davx5-ose#731)
* Rename AppTheme to M2Theme, add M3 theme

* Rewrite AboutActivity to M3

* Apply M3 theme; minor optimizations

* Use M3 version of AboutLibraries

* Use material3 instead of material3-android dependency

* Use reversed theme
2024-04-20 00:37:32 +02:00
Ricki Hirner
3b53c64f1a Add M3 theme and apply to AboutActivity (bitfireAT/davx5-ose#731)
* Rename AppTheme to M2Theme, add M3 theme

* Rewrite AboutActivity to M3

* Apply M3 theme; minor optimizations

* Use M3 version of AboutLibraries

* Use material3 instead of material3-android dependency

* Use reversed theme
2024-04-20 00:37:32 +02:00
Ricki Hirner
0733715ac3 Fetch translations from Transifex 2024-04-13 21:25:05 +02:00
Ricki Hirner
c3ba6d0826 Update copyright; upgrade dependencies (bitfireAT/davx5-ose#687) 2024-03-27 17:44:32 +01:00
Ricki Hirner
43f4ef5179 Login screen: increase padding of login options minimally 2024-03-27 17:43:51 +01:00
Arnau Mora
d9fe3b8632 Create a native Material theme and get rid of XML styles (bitfireAT/davx5-ose#675)
* Added custom Compose theme

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

* Got rid of accompanist theme adapter

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

* Removed unused import

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

* Added actionbar to the activities that didn't have one

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

* Theme now always hides actionbar

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

* Added back string

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

* Got rid of all color definitions

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

* Moved color definition to drawable

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

* Using Compose colors

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

* Using AppCompat theme

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

* Removed XML theme

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

* Moved color definition

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

* Added bars coloring in Compose

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

* Added dark theme

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

* Added custom Compose theme

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

* Got rid of accompanist theme adapter

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

* Removed unused import

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

* Added actionbar to the activities that didn't have one

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

* Theme now always hides actionbar

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

* Added back string

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

* Got rid of all color definitions

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

* Moved color definition to drawable

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

* Using Compose colors

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

* Using AppCompat theme

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

* Removed XML theme

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

* Moved color definition

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

* Added bars coloring in Compose

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

* Added dark theme

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

* Changed content description

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

* Using `onSupportNavigateUp`

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

* Changed color on top of primary green

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

* Added up navigation

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

* Made `onSupportNavigateUp` optional

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

* Typo

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

* Got rid of edge-to-edge

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

* Added back some XML styles

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

* Simplify TasksCard calling

* Move theme colors to flavor-specific ThemeColors file

* Remove global AppTheme paddings for now

* Optimize imports

---------

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2024-03-27 17:43:39 +01:00
Arnau Mora
c3078e85cc Create a native Material theme and get rid of XML styles (bitfireAT/davx5-ose#675)
* Added custom Compose theme

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

* Got rid of accompanist theme adapter

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

* Removed unused import

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

* Added actionbar to the activities that didn't have one

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

* Theme now always hides actionbar

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

* Added back string

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

* Got rid of all color definitions

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

* Moved color definition to drawable

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

* Using Compose colors

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

* Using AppCompat theme

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

* Removed XML theme

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

* Moved color definition

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

* Added bars coloring in Compose

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

* Added dark theme

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

* Added custom Compose theme

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

* Got rid of accompanist theme adapter

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

* Removed unused import

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

* Added actionbar to the activities that didn't have one

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

* Theme now always hides actionbar

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

* Added back string

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

* Got rid of all color definitions

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

* Moved color definition to drawable

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

* Using Compose colors

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

* Using AppCompat theme

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

* Removed XML theme

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

* Moved color definition

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

* Added bars coloring in Compose

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

* Added dark theme

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

* Changed content description

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

* Using `onSupportNavigateUp`

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

* Changed color on top of primary green

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

* Added up navigation

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

* Made `onSupportNavigateUp` optional

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

* Typo

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

* Got rid of edge-to-edge

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

* Added back some XML styles

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

* Simplify TasksCard calling

* Move theme colors to flavor-specific ThemeColors file

* Remove global AppTheme paddings for now

* Optimize imports

---------

Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2024-03-27 17:43:39 +01:00
Ricki Hirner
d2ea4c1a84 Rewrite login activity to Compose (bitfireAT/davx5-ose#672)
* Remove unnecessary layout files

* [WIP] Rewrite LoginActivity to Compose

* [WIP] Login type

* [WIP] Login by URL, Google, Nextcloud

* Remove unnecessary files and kapt

* More renaming and removing of unnecessary files

* Login with email, URL

* Login type: Advanced

* Drop "known base URLs"

* "Detect resources" and "Create account" page

* Introduce LoginTypesProvider interface

* Managed adaptions
2024-03-24 21:10:37 +01:00
Arnau Mora
95ef141c55 Replaced icons with auto-mirrored version when possible (bitfireAT/davx5-ose#666)
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
2024-03-21 11:42:53 +01:00
Sunik Kupfer
5980d7e92a [gplay] Rewrite EarnBadgesActivity to Compose (#547)
* Remove adapters

* Remove xml

* Add top bar

* Add text

* Add available badges list

* Add bought badges list

* Add bought badges list

* Drop animations

* Show snackbar on errors

* Optimize imports

* Update uri handler to compose

* Suppress unused warning

* Update indenting
2024-03-21 11:42:13 +01:00
Ricki Hirner
e0d5f8de17 [gplay/managed] Fix strings and imports (#549) 2024-03-20 17:06:19 +01:00
Ricki Hirner
f831a4fbb6 Add stats parameters for Web site calls, rename AccountActivity2 back to AccountActivity 2024-03-12 13:03:54 +01:00
Ricki Hirner
b2637de513 Move "Community" to "Support the project", remove obsolete code 2024-03-12 12:58:09 +01:00
Ricki Hirner
b3359f69c4 Move "Community" to "Support the project", remove obsolete code 2024-03-12 12:58:09 +01:00
Ricki Hirner
10a4578c8b Rewrite navigation drawer to Compose (all build flavors) (#545)
* [WIP] Rewrite navigation drawer to Compose (only standard build variant)

* Rewrite other navigation drawer of all build flavors to Compose

* Shorten StandardAccountsDrawerHandler

* Add previews
2024-03-12 12:43:19 +01:00
Ricki Hirner
03b70e6ec7 Rewrite navigation drawer to Compose (all build flavors) (#545)
* [WIP] Rewrite navigation drawer to Compose (only standard build variant)

* Rewrite other navigation drawer of all build flavors to Compose

* Shorten StandardAccountsDrawerHandler

* Add previews
2024-03-12 12:43:19 +01:00
Ricki Hirner
78ba2f31e8 Improve homepage URL launching (bitfireAT/davx5-ose#632)
* Move homepage and other Web URLs to Constants; minor refactoring

* Use AppTheme with built-in safe LocalUriHandler instead of MdcTheme; minor refactoring

* Account settings: add TODO for Compose rewrite

* Use UriHandler instead of UiUtils.launch when possible
2024-03-10 21:05:42 +01:00
Ricki Hirner
e67f617f52 Improve homepage URL launching (bitfireAT/davx5-ose#632)
* Move homepage and other Web URLs to Constants; minor refactoring

* Use AppTheme with built-in safe LocalUriHandler instead of MdcTheme; minor refactoring

* Account settings: add TODO for Compose rewrite

* Use UriHandler instead of UiUtils.launch when possible
2024-03-10 21:05:42 +01:00
Ricki Hirner
3c77facab5 Rewrite intro pages to Compose (dropping all Fragments) (bitfireAT/davx5-ose#626) 2024-03-09 14:47:25 +01:00
Ricki Hirner
fae5afbf89 Fetch translations from Transifex 2024-02-22 12:16:28 +01:00
Ricki Hirner
1ee23af370 [CI] Run lint and tests for standard, gplay and managed flavor (#529)
* [CI] Run lint and tests for standard, gplay and managed flavor

* Fix requireViewById minimum SDK problem

* Specify exported for .ui.setup.LoginActivity in Manifest
2024-02-13 09:49:35 +01:00
Arnau Mora
00c855a9cc Rename LoginCredentialsFragmentFactory to LoginFragmentFactory (#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 10:55:47 +01:00
Sunik Kupfer
02809da6ba Nextcloud login flow for managed (#501)
* Add login_type choice restriction

* Move NextcloudLoginFlowFragment from davdroid to main

* Start NextcloudLoginFlowFragment when set as login_type

* Remove unused default login type

* Prefill NextcloudLoginFlowFragment with base URL from config

* Update imports

* Make String comparison case-insensitive

* Create fragment with extra instead of constructor argument

* Minor reordering

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2024-01-03 11:23:42 +01:00
Ricki Hirner
d71d4c2c1e Fetch translations from Transifex 2023-12-23 12:38:55 +01:00
Ricki Hirner
bdec7e8931 Nextcloud Login flow: provide default DAV_PATH (/remote.php/dav) (#497) 2023-12-21 17:04:54 +01:00
Ricki Hirner
028517874e Fetch translations from Transifex 2023-11-13 16:30:17 +01:00
Sunik Kupfer
91bbe803f3 Move all common locales to main and adjust transifex config (#458)
* Move all common locales to main and adjust transifex config

* Rename gplay and managed string resource files

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-11-13 16:16:18 +01:00
Sunik Kupfer
fa14117d87 Move all common locales to main and adjust transifex config (#458)
* Move all common locales to main and adjust transifex config

* Rename gplay and managed string resource files

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-11-13 16:16:18 +01:00
Ricki Hirner
2d6bc27482 Clean up hilt modules 2023-11-07 15:05:34 +01:00
Ricki Hirner
66efc905c9 Clean up hilt modules 2023-11-07 15:05:34 +01:00
Ricki Hirner
c78986e3e7 Clean up hilt modules 2023-11-07 15:05:34 +01:00
Ricki Hirner
870cdc8f6a Rewrite About activity to Compose (#432)
* Rewrite AboutActivity to Compose (still keeping the tab fragments)

* Replace Translations and Libraries fragments

* [WIP] Rewrite AboutApp

* [WIP] App license info as Composable

* [WIP] Hilt viewModel/Compose

* Fill ManagedAppLicenseInfoProvider with real data

* Simplify setContent, use LazyColumn for translations

* Minor changes
2023-11-07 14:12:49 +01:00
Ricki Hirner
3e51051edd Rewrite About activity to Compose (#432)
* Rewrite AboutActivity to Compose (still keeping the tab fragments)

* Replace Translations and Libraries fragments

* [WIP] Rewrite AboutApp

* [WIP] App license info as Composable

* [WIP] Hilt viewModel/Compose

* Fill ManagedAppLicenseInfoProvider with real data

* Simplify setContent, use LazyColumn for translations

* Minor changes
2023-11-07 14:12:49 +01:00
Ricki Hirner
d7ecc0dd8a Rewrite About activity to Compose (#432)
* Rewrite AboutActivity to Compose (still keeping the tab fragments)

* Replace Translations and Libraries fragments

* [WIP] Rewrite AboutApp

* [WIP] App license info as Composable

* [WIP] Hilt viewModel/Compose

* Fill ManagedAppLicenseInfoProvider with real data

* Simplify setContent, use LazyColumn for translations

* Minor changes
2023-11-07 14:12:49 +01:00
Ricki Hirner
edd4def8f6 Fetch translations from Transifex 2023-10-26 12:25:29 +02:00
Ricki Hirner
3204cb7c0f Fetch translations from Transifex 2023-10-26 12:25:29 +02:00
Ricki Hirner
96da9a02d9 Nextcloud: pre-select contact group method (CATEGORIES) (#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:08:43 +02:00
Ricki Hirner
96cc70a472 LoginActivity: add Nextcloud Login Flow (#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 14:44:16 +02:00
Ricki Hirner
1714ec0d8c Fetch translations from Transifex 2023-10-09 12:37:46 +02:00
Ricki Hirner
ba5976840f Fetch translations from Transifex 2023-10-09 12:37:46 +02:00
Ricki Hirner
1e59b834e8 Beta feedback (gplay flavor): provide alternative to in-app reviews (#401) 2023-10-07 11:53:23 +02:00
Ricki Hirner
f77a5a6314 Rename java sources directories to kotlin 2023-10-07 10:08:32 +02:00
Ricki Hirner
8177eedb71 Rename java sources directories to kotlin 2023-10-07 10:08:32 +02:00
Ricki Hirner
291d9c680b Rename java sources directories to kotlin 2023-10-07 10:08:32 +02:00
Ricki Hirner
3b233e7abf Rename java sources directories to kotlin 2023-10-07 10:08:32 +02:00
Ricki Hirner
e3117442de Repair beta feedback (#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 10:09:30 +02:00
Ricki Hirner
d564dc4d10 Fetch translations from Transifex 2023-09-22 15:52:15 +02:00
Ricki Hirner
8f6b569882 Fetch translations from Transifex 2023-09-22 15:52:15 +02:00
Arnau Mora
e651b4f84f App name strings are the same for DAVx5 and Managed DAVx5 (#376)
* Moved translations to davdroid module

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

* Removed `trans.de`

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

---------

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2023-09-10 13:43:21 +02:00
Ricki Hirner
dfa368b412 Fetch translations from Transifex 2023-09-05 10:44:00 +02:00
Ricki Hirner
d27fa97be6 Fetch translations from Transifex 2023-08-07 20:35:30 +02:00
Arnau Mora
8b901703ca Upgrade AGP to 8.1 and configure per app language (#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-27 19:38:09 +02:00
Ricki Hirner
6032d549fb Google OAuth: fix manifest merging so that intent-filter for OAuth callback is included again (bitfireAT/davx5-ose#367) 2023-07-27 18:19:53 +02:00
Sunik Kupfer
936e3bff7a Add "10 years DAVx5" badges (#336)
Add some badges
2023-07-27 14:27:32 +02:00
Ricki Hirner
711008d20b Fetch translations from Transifex 2023-07-21 22:04:31 +02:00
Ricki Hirner
abdad6fe1d Fetch translations from Transifex 2023-07-21 22:04:31 +02:00
Ricki Hirner
11592abb9e Google Login: add Limited Use policy (#327) 2023-07-10 15:05:15 +02:00
Ricki Hirner
6a6617bfc7 Fetch translations from Transifex 2023-07-10 13:38:07 +02:00
Ricki Hirner
1ddda87efc Fetch translations from Transifex 2023-07-10 13:38:07 +02:00
Ricki Hirner
ed06fad6aa Version bump to 4.3.5-alpha.1; update Compose; move GoogleLoginFragment to fix build 2023-06-30 13:16:31 +02:00
Sunik Kupfer
e2b898f1a3 291 clean up oauth mess (#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:42:37 +02:00
Sunik Kupfer
4e5a937240 291 clean up oauth mess (#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:42:37 +02:00
Sunik Kupfer
4c9e75d17e 291 clean up oauth mess (#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:42:37 +02:00
Arnau Mora
c3dec982bd Removed Twitter from navigation drawer (#312)
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2023-06-25 10:58:19 +02:00
Arnau Mora
a1ca245792 Removed Twitter from navigation drawer (#312)
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
2023-06-25 10:58:19 +02:00
Ricki Hirner
bee6342550 Fetch translations from Transifex 2023-06-13 18:42:39 +02:00
Ricki Hirner
19e2181fff Google OAuth: fix endless loop in Fragment (#295)
Fix endless loop
2023-06-13 18:32:46 +02:00
Sunik Kupfer
e4a4726a3a [Google OAuth] Support custom Client IDs (#294)
* Support custom Client IDs

* Refactoring

---------

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2023-06-13 18:01:35 +02:00
Ricki Hirner
75f4e5b67b Fetch translations from Transifex 2023-06-11 13:21:13 +02:00
Ricki Hirner
1dcbe584c8 Support OAuth for Google (#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 13:18:06 +02:00
Sunik Kupfer
304a572a2a 280 fix problematic toasts (#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 13:41:15 +02:00
Ricki Hirner
b476902cfd Fetch translations from Transifex 2023-06-01 12:29:42 +02:00
Ricki Hirner
8366965c2b Fetch translations from Transifex 2023-06-01 12:29:42 +02:00
Ricki Hirner
93799ef875 Fetch translations from Transifex 2023-05-22 08:25:52 +02:00
Ricki Hirner
1016915ca0 Fetch translations from Transifex 2023-05-12 10:44:05 +02:00
Ricki Hirner
dc075e8128 Fix translations 2023-05-02 13:09:31 +02:00
Ricki Hirner
8a20b3f071 Fetch translations from Transifex 2023-05-02 11:40:41 +02:00
Ricki Hirner
555c72618f Fetch translations from Transifex 2023-05-02 11:40:41 +02:00
Ricki Hirner
c7db2a3d0a Upgrade gradle, AGP, dependencies 2023-04-29 22:41:08 +02:00
Arnau Mora
9c466b8f64 Added missing monochrome icon (#233)
Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>
2023-03-22 11:23:20 +01:00
Ricki Hirner
0c2d9a7a6f Fetch translations from Transifex 2023-03-20 12:37:05 +01:00
Ricki Hirner
3fd13021bf Fetch translations from Transifex 2023-03-20 12:37:05 +01:00
Ricki Hirner
4b4a73e523 Fetch translations from Transifex, tx config changes 2023-02-08 11:42:16 +01:00
Ricki Hirner
b85801efe2 Fetch translations from Transifex 2023-02-01 13:32:02 +01:00
Ricki Hirner
a50fef6e1f Fetch translations from Transifex 2023-02-01 13:32:02 +01:00
Arnau Mora
6cc4ed72de Added Mastodon link to navigation drawer (#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:25:30 +01:00
Arnau Mora
738c5105a0 Added Mastodon link to navigation drawer (#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:25:30 +01:00
Ricki Hirner
5eb1662686 Fetch translations from Transifex 2022-12-10 13:19:31 +01:00
Ricki Hirner
e97b3ddbab Fetch translations from Transifex 2022-12-10 13:19:31 +01:00
Sunik Kupfer
929bf0c16d Refactor DavService to WorkManager (#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-03 14:00:38 +01:00
Sunik Kupfer
90a0892e33 Fetch translations from Transifex 2022-11-29 14:39:13 +01:00
Sunik Kupfer
019574d84a Fetch translations from Transifex 2022-11-29 14:39:13 +01:00
Sunik Kupfer
b9b570bf51 Fetch translations from Transifex 2022-10-25 11:02:34 +02:00
Sunik Kupfer
9b14f79570 add new anniversary badge (closes bitfireAT/davx5#147) (#152)
* add new anniversary badge
* change back to cake icon in lachsrosa
2022-10-24 20:34:36 +02:00
Ricki Hirner
3b2d4078c3 Fetch translations from Transifex 2022-10-21 13:09:52 +02:00
Ricki Hirner
dc274ef689 Fetch translations from Transifex 2022-10-21 13:09:52 +02:00
Ricki Hirner
d84e71750f Fetch translations from Transifex (including new translations) 2022-10-14 22:59:53 +02:00
Ricki Hirner
07fd7d9377 Update Manual URL 2022-10-08 18:57:44 +02:00
Ricki Hirner
ea3dfa9cbe Fetch translations from Transifex 2022-09-19 16:33:25 +02:00
Ricki Hirner
bed6feede1 Fetch translations from Transifex 2022-09-08 21:59:42 +02:00
Sunik Kupfer
448b6ae4c5 Migrate to gpblv5 (closes bitfireAT/davx5#116) (#123)
* migrate to gplay billing library v5
* alter handling of purchase state
* complete migration to gpblv5
* fix demo notification showing by using kotlin version of billing lib to block thread
* fix
2022-09-07 14:40:03 +02:00
Ricki Hirner
7dcfb10d15 Fetch translations from Transifex 2022-08-28 21:58:48 +02:00
Sunik Kupfer
53077f30d9 move badge colors to gplay res (#114) 2022-08-10 17:10:28 +02:00
Sunik Kupfer
0a42a34fc7 Fetch translations from Transifex 2022-06-21 11:44:12 +02:00
Ricki Hirner
61e86b32d3 Fix standard/gplay flavor intro fragments 2022-05-28 10:47:21 +02:00
Ricki Hirner
02811aa71a Fix standard/gplay flavor intro fragments 2022-05-28 10:47:21 +02:00
Ricki Hirner
0c3395102c Use Hilt instead of Koin (#93)
* [WIP] Use Hilt for DI
* Use Hilt instead of ServiceLoader for intro fragments
* Rewrite from Koin to Hilt
* Tests
* Flavors
* Use more Hilt modules for service loading (account drawer, intro fragments)
* Lint
* WebDAV provider: don't listen to changes in onCreate (causes problems with Hilt and tests)
* Clean before building
* Modify test CI
* Update hilt to fix test error
* OpenSourceFragment may stay in main repo (it's not referenced in the Hilt flavor module definition)
* Test only standard flavor again (seems that testing multiple flavors at the same time causes tests to fail)
* Hilt for tests
* Use Hilt for settings providers
* Use Hilt for login credentials fragment
* Use Hilt for sync validator (was: sync plugin)
* Fix tests
2022-05-27 14:41:57 +02:00
Ricki Hirner
84f6103404 Use Hilt instead of Koin (#93)
* [WIP] Use Hilt for DI
* Use Hilt instead of ServiceLoader for intro fragments
* Rewrite from Koin to Hilt
* Tests
* Flavors
* Use more Hilt modules for service loading (account drawer, intro fragments)
* Lint
* WebDAV provider: don't listen to changes in onCreate (causes problems with Hilt and tests)
* Clean before building
* Modify test CI
* Update hilt to fix test error
* OpenSourceFragment may stay in main repo (it's not referenced in the Hilt flavor module definition)
* Test only standard flavor again (seems that testing multiple flavors at the same time causes tests to fail)
* Hilt for tests
* Use Hilt for settings providers
* Use Hilt for login credentials fragment
* Use Hilt for sync validator (was: sync plugin)
* Fix tests
2022-05-27 14:41:57 +02:00
Ricki Hirner
aac543b759 Use Hilt instead of Koin (#93)
* [WIP] Use Hilt for DI
* Use Hilt instead of ServiceLoader for intro fragments
* Rewrite from Koin to Hilt
* Tests
* Flavors
* Use more Hilt modules for service loading (account drawer, intro fragments)
* Lint
* WebDAV provider: don't listen to changes in onCreate (causes problems with Hilt and tests)
* Clean before building
* Modify test CI
* Update hilt to fix test error
* OpenSourceFragment may stay in main repo (it's not referenced in the Hilt flavor module definition)
* Test only standard flavor again (seems that testing multiple flavors at the same time causes tests to fail)
* Hilt for tests
* Use Hilt for settings providers
* Use Hilt for login credentials fragment
* Use Hilt for sync validator (was: sync plugin)
* Fix tests
2022-05-27 14:41:57 +02:00
Ricki Hirner
13179912b1 Use Hilt instead of Koin (#93)
* [WIP] Use Hilt for DI
* Use Hilt instead of ServiceLoader for intro fragments
* Rewrite from Koin to Hilt
* Tests
* Flavors
* Use more Hilt modules for service loading (account drawer, intro fragments)
* Lint
* WebDAV provider: don't listen to changes in onCreate (causes problems with Hilt and tests)
* Clean before building
* Modify test CI
* Update hilt to fix test error
* OpenSourceFragment may stay in main repo (it's not referenced in the Hilt flavor module definition)
* Test only standard flavor again (seems that testing multiple flavors at the same time causes tests to fail)
* Hilt for tests
* Use Hilt for settings providers
* Use Hilt for login credentials fragment
* Use Hilt for sync validator (was: sync plugin)
* Fix tests
2022-05-27 14:41:57 +02:00
Ricki Hirner
bc8d4cd25d Fetch translations from Transifex 2022-05-22 23:49:26 +02:00
Sunik Kupfer
168e9b56aa In app review api (closes bitfireAT/davx5#82) (#85)
* Notify user if billing unavailable or network issues arise

* offer to rate the app in earn badges activity, instead of navigation drawer and linting

* linting

* use in-app review API to trigger the review request after two weeks every two weeks

* remove obsolete testing bools

* [WIP] add mockk tests

* Adapt tests

* finish EarnBadgesActivity tests

* refactor for gplay flavor testing

* use junit assert statements, add comments and ensure gplay android tests are run on test server

* Use org.junit for Assert

* Tests

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2022-05-22 23:45:25 +02:00
Sunik Kupfer
4919bf0d8d In app review api (closes bitfireAT/davx5#82) (#85)
* Notify user if billing unavailable or network issues arise

* offer to rate the app in earn badges activity, instead of navigation drawer and linting

* linting

* use in-app review API to trigger the review request after two weeks every two weeks

* remove obsolete testing bools

* [WIP] add mockk tests

* Adapt tests

* finish EarnBadgesActivity tests

* refactor for gplay flavor testing

* use junit assert statements, add comments and ensure gplay android tests are run on test server

* Use org.junit for Assert

* Tests

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2022-05-22 23:45:25 +02:00
Ricki Hirner
dddbce93f7 Use Koin for all tests; CI: run tests for all flavors (#91)
Closes bitfireAT/davx5#89
2022-05-22 18:54:01 +02:00
Sunik Kupfer
235e24839f Dark theme for EearnBadgesActivity (closes bitfireAT/davx5#88) (#90)
* [WIP] dark mode support for earnbadgesactivity

* dark mode for earn badges activity
2022-05-19 13:22:33 +02:00
Sunik Kupfer
677ad8c37a correctly acknowledge purchases (closes bitfireAT/davx5#86) (#87)
* linting

* fix acknowledging purchases correctly
2022-05-16 13:35:32 +02:00
Ricki Hirner
6887e44910 Fetch translations from Transifex 2022-04-29 15:49:25 +02:00
Ricki Hirner
493644c24b Fix manifests (problem when merging) 2022-04-29 15:47:13 +02:00
Ricki Hirner
284094c105 Move EarnBadgesActivity strings to gplay 2022-04-25 15:07:06 +02:00
Ricki Hirner
e48ad8b796 Fetch translations from Transifex 2022-04-25 15:07:06 +02:00
Ricki Hirner
593ee0ae24 Move EarnBadgesActivity strings to gplay 2022-04-25 15:07:06 +02:00
Ricki Hirner
89dcad5abc Setup intent filter (#80)
* Add intent filter for caldav(s)://, carddav(s):// and davx5:// schemes
* Define intent-filter only for standard and gplay flavors
* Merge manifest; remove Espresso tests (further tests should be added)
* Lint

Closes bitfireAT/davx5#77
2022-04-25 15:07:06 +02:00
Ricki Hirner
84f73918e2 Rename at.bitfire.davdroid.model to at.bitfire.davdroid.db to make clear it contains database models (and not view models) 2022-04-25 15:07:06 +02:00
Ricki Hirner
53ca7f769b Move file, update gradle and plugin 2022-04-15 12:02:32 +02:00
Ricki Hirner
b80aaa41a2 Move file, update gradle and plugin 2022-04-15 12:02:32 +02:00
Sunik Kupfer
37a7685e7a In app purchases and rating (bitfireAT/davx5#15) (#61)
* [WIP] add earning badges activity layout

* [WIP] ratings test

* [WIP] add billingClient

* correct gplay file placements

* cleanup and start on loading badges from play console

* [WIP]

* [WIP]

* use constraint layout instead of linear layouts

* [WIP] implement caching

* implement caching

* [WIP] load, cache and display bought badges

* [WIP] load, cache and display bought badges

* refactor and fix adapter not updating

* [WIP] load, cache and display bought badges

* proper use of RecyclerView

* refactor

* hide recycler views if no badges available or not yet bought

* make badges buyable and display earned badges

* reflect correct amount of bought badges

* [WIP] refactor, extract billing operations

* move files to gplay flavor and add sailing badge

* Load skus from cache if possible

* Load and save bought skus from and to cache

* linting

* alter log messages

* fixes and stop caching bought badges

* acknowledge purchases and show bought skus also when cache is cleared

* consume coffees

* add notice

* dont clear bought badges on new buy

* calculate bought badges only when purchases and skudetails are loaded

* retry if BillingService gets disconnected

* [WIP] disable buy button for bought badges

* [WIP] disable buy button for bought badges

* disable buy button for bought badges

* fix missing theme exception

* display correct amount of bought badges

* add back button and activity title

* add back button and activity title, via manifest instead

* add color tinting and center year of badge

* reflect bought state correctly

* easter eggs

* fix concurrent modification exception

* refactor for different flavors

* refactor AccountsDrawerHandler for different flavors

* Remove FakeReviewManager dependency in non gplay flavor test

* add community changes gone missing with improper rebase

* move files add add drop in animation for badges

* start using BaseAccountsDrawerHandler and variations for flavors

* remove dead code

* AccountsDrawer: minor changes

* Minor changes; remove caching for SKUs (done by billing library according to docs)

* Minor changes

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2022-04-15 11:27:21 +02:00
Sunik Kupfer
5396353cb5 In app purchases and rating (bitfireAT/davx5#15) (#61)
* [WIP] add earning badges activity layout

* [WIP] ratings test

* [WIP] add billingClient

* correct gplay file placements

* cleanup and start on loading badges from play console

* [WIP]

* [WIP]

* use constraint layout instead of linear layouts

* [WIP] implement caching

* implement caching

* [WIP] load, cache and display bought badges

* [WIP] load, cache and display bought badges

* refactor and fix adapter not updating

* [WIP] load, cache and display bought badges

* proper use of RecyclerView

* refactor

* hide recycler views if no badges available or not yet bought

* make badges buyable and display earned badges

* reflect correct amount of bought badges

* [WIP] refactor, extract billing operations

* move files to gplay flavor and add sailing badge

* Load skus from cache if possible

* Load and save bought skus from and to cache

* linting

* alter log messages

* fixes and stop caching bought badges

* acknowledge purchases and show bought skus also when cache is cleared

* consume coffees

* add notice

* dont clear bought badges on new buy

* calculate bought badges only when purchases and skudetails are loaded

* retry if BillingService gets disconnected

* [WIP] disable buy button for bought badges

* [WIP] disable buy button for bought badges

* disable buy button for bought badges

* fix missing theme exception

* display correct amount of bought badges

* add back button and activity title

* add back button and activity title, via manifest instead

* add color tinting and center year of badge

* reflect bought state correctly

* easter eggs

* fix concurrent modification exception

* refactor for different flavors

* refactor AccountsDrawerHandler for different flavors

* Remove FakeReviewManager dependency in non gplay flavor test

* add community changes gone missing with improper rebase

* move files add add drop in animation for badges

* start using BaseAccountsDrawerHandler and variations for flavors

* remove dead code

* AccountsDrawer: minor changes

* Minor changes; remove caching for SKUs (done by billing library according to docs)

* Minor changes

Co-authored-by: Ricki Hirner <hirner@bitfire.at>
2022-04-15 11:27:21 +02:00
Ricki Hirner
593be72ed8 Fetch translations from Transifex 2022-03-23 18:02:05 +01:00
Ricki Hirner
b904394793 Fetch translations from Transifex 2022-03-22 12:33:30 +01:00
Ricki Hirner
036911f117 Navigation drawer: update Community 2022-03-20 20:14:51 +01:00
Ricki Hirner
04b695fa6f Navigation drawer: update Community 2022-03-20 20:14:51 +01:00
Ricki Hirner
92be889ce0 Fetch translations from Transifex 2022-03-20 20:11:12 +01:00
Ricki Hirner
779fa43e9e Fetch translations from Transifex 2022-03-18 10:34:58 +01:00
Ricki Hirner
20d9d76a9d Fetch translations from Transifex 2022-03-16 14:44:25 +01:00
Ricki Hirner
4d0d463819 DebugInfo: provide IntentBuilder that truncates large logs/local resource dumps (should fix bitfireAT/davx5#69) 2022-03-16 14:44:24 +01:00
Ricki Hirner
41efc41fd9 Fetch translations from Transifex 2022-01-28 17:06:52 +01:00
Ricki Hirner
5826d89919 Fetch translations from Transifex 2022-01-24 11:13:54 +01:00
Ricki Hirner
305fada5f9 Fetch translations from Transifex 2022-01-05 16:16:46 +01:00
Ricki Hirner
c2e0ed6ac6 Fetch translations from Transifex 2021-12-20 17:47:32 +01:00
Ricki Hirner
0830dab59b Fetch translations from Transifex 2021-12-16 13:35:58 +01:00
Ricki Hirner
cc62e5f014 Update copyright (resolves bitfireAT/davx5#26) 2021-12-15 17:47:12 +01:00
Ricki Hirner
f8989e75cd Version bump to 4.1-alpha.1 2021-10-21 15:27:57 +02:00
Ricki Hirner
61b50ad2cc Fetch translations from Transifex 2021-10-04 17:42:54 +02:00
Ricki Hirner
b602ace309 Improve WebDAV UI 2021-10-02 18:54:21 +02:00
Ricki Hirner
88771a16c2 Squashed commit of the following:
commit 56f5f5a6cbad595534148a160678972734ca6cf2
Author: Ricki Hirner <hirner@bitfire.at>
Date:   Wed Sep 29 10:59:23 2021 +0200

    Version bump to 4.0-beta1

commit 2a4d7501d9d6cd572269de21e82c204c5a2a57e8
Author: Ricki Hirner <hirner@bitfire.at>
Date:   Tue Sep 28 21:45:49 2021 +0200

    Fix UiUtils.launchUri once again

commit 293accaf8f26842d198e9d5c4fc9029cb6ac71cc
Author: Ricki Hirner <hirner@bitfire.at>
Date:   Tue Sep 28 13:47:06 2021 +0200

    Adjust gradle daemon heap size

commit 7763a51c9bbc7baee36ef71648889f7fb4fe965d
Author: Ricki Hirner <hirner@bitfire.at>
Date:   Tue Sep 28 12:21:37 2021 +0200

    Query and show quota

commit 95f4dbfd8ffadd930aab9fc36dc3865bfee54fb7
Author: Ricki Hirner <hirner@bitfire.at>
Date:   Mon Sep 27 22:16:48 2021 +0200

    Persist cookies over WebDAV sessions

commit 17c9327eb3ef3d9384b28b70aa9637718d34e8a2
Author: Ricki Hirner <hirner@bitfire.at>
Date:   Sun Sep 26 19:54:57 2021 +0200

    Add WebDAV caches

    * add random access page cache
    * add thumbnail cache
    * add HEAD response cache

commit 0e5237f8b178ab66099999f72e657c59c9302d71
Author: Ricki Hirner <hirner@bitfire.at>
Date:   Tue Aug 31 13:25:36 2021 +0200

    Add WebDAV Access over Storage Access Framework
2021-09-29 11:03:22 +02:00
Ricki Hirner
11a5e68093 Squashed commit of the following:
commit 56f5f5a6cbad595534148a160678972734ca6cf2
Author: Ricki Hirner <hirner@bitfire.at>
Date:   Wed Sep 29 10:59:23 2021 +0200

    Version bump to 4.0-beta1

commit 2a4d7501d9d6cd572269de21e82c204c5a2a57e8
Author: Ricki Hirner <hirner@bitfire.at>
Date:   Tue Sep 28 21:45:49 2021 +0200

    Fix UiUtils.launchUri once again

commit 293accaf8f26842d198e9d5c4fc9029cb6ac71cc
Author: Ricki Hirner <hirner@bitfire.at>
Date:   Tue Sep 28 13:47:06 2021 +0200

    Adjust gradle daemon heap size

commit 7763a51c9bbc7baee36ef71648889f7fb4fe965d
Author: Ricki Hirner <hirner@bitfire.at>
Date:   Tue Sep 28 12:21:37 2021 +0200

    Query and show quota

commit 95f4dbfd8ffadd930aab9fc36dc3865bfee54fb7
Author: Ricki Hirner <hirner@bitfire.at>
Date:   Mon Sep 27 22:16:48 2021 +0200

    Persist cookies over WebDAV sessions

commit 17c9327eb3ef3d9384b28b70aa9637718d34e8a2
Author: Ricki Hirner <hirner@bitfire.at>
Date:   Sun Sep 26 19:54:57 2021 +0200

    Add WebDAV caches

    * add random access page cache
    * add thumbnail cache
    * add HEAD response cache

commit 0e5237f8b178ab66099999f72e657c59c9302d71
Author: Ricki Hirner <hirner@bitfire.at>
Date:   Tue Aug 31 13:25:36 2021 +0200

    Add WebDAV Access over Storage Access Framework
2021-09-29 11:03:22 +02:00
Ricki Hirner
5238f0491f Fetch translations from Transifex 2021-09-09 19:30:37 +02:00
Ricki Hirner
8e555f7909 lint 2021-09-09 16:34:35 +02:00
Ricki Hirner
762ecc38b8 Fetch translations from Transifex 2021-08-31 13:46:25 +02:00
Ricki Hirner
0e5ad5cbd8 Fetch translations from Transifex 2021-08-22 20:43:43 +02:00
Ricki Hirner
4d99ceae0f Fetch translations from Transifex 2021-07-31 13:05:00 +02:00
Ricki Hirner
f033c20754 Transifex: use "tx pull" instead of scripts/fetch-translations.sh from now on 2021-07-20 12:57:52 +02:00
Ricki Hirner
3d70055c7d Improve AutoComplete fields, especially in AppCompatDelegate-set dark mode 2021-07-16 01:50:10 +02:00
Ricki Hirner
8e9d66593a Fetch translations from Transifex 2021-07-14 16:24:50 +02:00
Ricki Hirner
b5dcb97b92 Fetch translations from Transifex 2021-07-08 14:38:15 +02:00
Ricki Hirner
506f7a7958 Provide auto-completion for some common base URLs 2021-07-06 16:15:14 +02:00
Ricki Hirner
3d7121d564 Fetch translations from Transifex 2021-06-29 19:11:19 +02:00
Ricki Hirner
556cb9a7f9 Fetch translations from Transifex 2021-05-23 14:00:56 +02:00
Ricki Hirner
9873c7947d [WIP] Dark mode for flavors 2021-05-07 23:10:20 +02:00
Ricki Hirner
6080e7845f Merge branch 'dev-3.x_EspressoExperimental-ose' into 'dev-3.x-ose'
Dev 3.x espresso experimental ose

See merge request bitfireAT/davx5-ose!59
2021-05-04 19:22:21 +02:00
Ricki Hirner
b1e120e810 Merge branch 'dev-3.x_RTLSupportEnabled-ose' into dev-3.x-ose 2021-05-04 15:33:23 +02:00
Ricki Hirner
39613b418f Add Vietnamese translations (thanks!); fetch translations from Transifex 2021-04-19 18:51:09 +02:00
Ricki Hirner
5ea2bc7bd1 Fetch translations from Transifex 2021-04-12 22:56:32 +02:00
Ricki Hirner
a6d6168eb0 Fetch translations from Transifex 2021-02-09 10:59:45 +01:00
Ricki Hirner
8eebcaff7a Fix translation 2021-02-07 12:00:48 +01:00
Ricki Hirner
98e873ccf1 Fetch translations from Transifex 2021-02-07 12:00:48 +01:00
Ricki Hirner
029e97f019 Fetch translations from Transifex 2021-01-11 20:07:32 +01:00
Ricki Hirner
3d07608efc Fetch translations from Transifex 2021-01-02 15:25:59 +01:00
Ricki Hirner
ce1724b69f Fetch translations from Transifex 2020-11-27 21:44:11 +01:00
Ricki Hirner
c6a3625510 Fetch translations from Transifex 2020-11-23 11:47:00 +01:00
Ricki Hirner
fa80d1fc91 Nextcloud Login Flow: follow redirects 2020-11-20 15:59:48 +01:00
Patrick
6a1cb74ec5 Shows a toast when no certificate was found
Currently the certificate selection would popup und disappear immedeately. This quick fix would show a Toast for User Feedback
2020-11-16 09:29:00 +01:00
Ricki Hirner
dae5c01aac Fetch translations from Transifex 2020-11-05 12:05:16 +01:00
Ricki Hirner
f91a275768 Add login layout ID for pre-launch tests; version bump to 3.3.6-beta1 2020-10-30 18:24:15 +01:00
Ricki Hirner
05d1e95ed0 Fetch translations from Transifex 2020-10-24 14:01:03 +02:00
Ricki Hirner
1d518eaac8 Fetch translations from Transifex 2020-10-20 12:08:08 +02:00
Ricki Hirner
32ebcaf8bc Fetch translations from Transifex 2020-10-19 23:15:33 +02:00
Ricki Hirner
6789e1d41d Advanced login: small fixes 2020-10-18 12:32:46 +02:00
Patrick Lang
c6b5d5cba0 Login with advanced options
Adds a new radiobutton for login with advanced options
2020-10-17 20:58:51 +02:00
Ricki Hirner
7a278f5e48 Nextcloud Login Flow v2: better error handling 2020-10-16 13:01:25 +02:00
Ricki Hirner
6da21bf9e5 Fetch translations from Transifex 2020-10-14 13:24:54 +02:00
Ricki Hirner
2b39d9025f Nextcloud: use Login Flow v2 for better browsing experience and to support things like Webauthn 2020-10-05 15:45:20 +02:00
Ricki Hirner
5fec57acdf Fetch translations from Transifex 2020-10-03 14:19:53 +02:00
Ricki Hirner
af2c3cade7 Fetch translations from Transifex 2020-10-02 13:06:55 +02:00
Ricki Hirner
5fdb893bfe Fetch translations from Transifex 2020-09-27 16:46:53 +02:00
Ricki Hirner
64c18dfa30 Fetch translations from Transifex 2020-09-20 14:20:07 +02:00
Ricki Hirner
9b65837436 Fetch translations from Transifex 2020-09-18 16:51:37 +02:00
Ricki Hirner
8d710909e1 Move translation pt-rBR to pt 2020-09-13 18:08:18 +02:00
Ricki Hirner
c86d2a42ad Fetch translations from Transifex 2020-09-09 12:04:55 +02:00
Ricki Hirner
e1dcd3e9f5 Fetch translations from Transifex 2020-08-31 12:40:22 +02:00
Ricki Hirner
60c18493cd Fetch translations from Transifex 2020-08-22 13:20:07 +02:00
Ricki Hirner
02095a6520 Fetch translations from Transifex 2020-08-12 12:10:25 +02:00
Ricki Hirner
ea7c5ed336 Some lint 2020-08-07 12:23:33 +02:00
Ricki Hirner
bb959e63c8 MultiSync: fix Sync all drawable/shortcut 2020-08-07 11:43:07 +02:00
Ricki Hirner
f01aa70342 Provide "Sync all accounts" option
* show sync status in accounts overview
* add "sync all accounts" in accounts overview
* add "sync all accounts" shortcut
2020-08-02 17:19:00 +02:00
Ricki Hirner
3ffee462ef Fetch translations from Transifex 2020-07-25 11:54:28 +02:00
Ricki Hirner
060b18ed6d Nextcloud login flow: decode parameters in nc://login URL 2020-07-24 18:38:54 +02:00
Ricki Hirner
12319c1a40 Fetch translations from Transifex 2020-07-22 11:11:21 +02:00
Ricki Hirner
2c3472328b Fetch translations from Transifex 2020-07-09 14:56:53 +02:00
Ricki Hirner
94ea1c0fbf Fetch translations from Transifex 2020-07-07 15:56:53 +02:00
Ricki Hirner
f83670a92d Merge branch 'clear-more-error-fields' into 'dev-3.x-ose'
Clear url, username, and name errors

See merge request bitfireAT/davx5-ose!34
2020-07-05 15:23:45 +02:00
Ricki Hirner
d50709407c Fetch translations from Transifex 2020-06-29 23:02:13 +02:00
Ricki Hirner
50d32fe5ed ical4android update 2020-06-12 13:37:41 +02:00
Ricki Hirner
30fa7b157a Fetch translations from Transifex 2020-06-11 18:31:41 +02:00
Ricki Hirner
405b7e09cd Use fragment-ktx viewModels(); begin removing I- prefix from interface names 2020-06-11 18:20:58 +02:00
Ricki Hirner
3a050c38d9 Fetch translations from Transifex 2020-05-31 20:46:27 +02:00
Ricki Hirner
8318c3f8a4 Fetch translations from Transifex 2020-05-29 00:27:21 +02:00
Ricki Hirner
9225455b84 Fix some TextInputLayouts 2020-05-27 15:50:37 +02:00
Ricki Hirner
045a399cfd Nextcloud login fragment: always use fragment view for Snackbar 2020-05-27 15:50:37 +02:00
Ricki Hirner
74732c8dc0 Fetch translations from Transifex 2020-05-27 15:50:36 +02:00
Ricki Hirner
5b59830db9 Update copyright 2020-05-27 15:50:36 +02:00
Ricki Hirner
86b0cb14c8 Merge branch 'clear-errors' into 'dev-3.x-ose'
Clear all errors when a different login method is chosen

See merge request bitfireAT/davx5-ose!31
2020-05-27 15:50:36 +02:00
Ricki Hirner
0e765f8789 Fetch translations from Transifex 2020-05-27 15:50:36 +02:00
Ricki Hirner
fc5a33737d Fetch translations from Transifex 2020-05-27 15:50:36 +02:00
Ricki Hirner
8962a25731 Show Donate in Navigation drawer only in ose 2020-05-27 15:50:36 +02:00
Ricki Hirner
be01910deb Fetch translations from Transifex 2020-04-21 11:34:04 +02:00
Ricki Hirner
32d4ae066a Adapt WebView progress bar; don't use okhttp BOM 2020-04-21 11:14:54 +02:00
Ricki Hirner
67ffe3b2e4 Fix build; bump version to 3.0-beta2 2020-04-20 16:57:53 +02:00
Ricki Hirner
841939dd70 Nextcloud Login flow: show progress and errors (including TLS errors) 2020-04-20 15:38:14 +02:00
Ricki Hirner
703f54a5aa Adapt login styles 2020-04-17 14:23:52 +02:00
Ricki Hirner
7a46e1a1db Don't cancel notifications of other sync threads (lets important notifications disappear sometimes) 2020-04-14 12:55:14 +02:00
Ricki Hirner
5ea4d48785 Update okhttp to 4.5.0 and dav4jvm to 2.0 2020-04-13 12:31:58 +02:00
Ricki Hirner
560593f531 Minor code cleanup 2020-04-09 15:05:59 +02:00
Ricki Hirner
24e4b2fd0d MultiSync 2020-04-09 14:32:10 +02:00
Ricki Hirner
172fed2eeb Managed intro 2020-04-08 17:54:42 +02:00
Ricki Hirner
565414d7d9 Introduce IntroActivity instead of startup fragments 2020-04-05 20:17:22 +02:00
Ricki Hirner
6fb8ab3acf Introduce IntroActivity instead of startup fragments 2020-04-05 20:17:22 +02:00
Ricki Hirner
74e6a93c1a Merge branch 'abaker/davx5-ose-clear_password_error' into master-ose 2020-03-06 12:01:06 +01:00
Ricki Hirner
cccc95a5f9 Fetch translations from Transifex 2020-03-06 00:21:51 +01:00
Ricki Hirner
b7c631e5d9 Merge branch 'textlayout_errors' into 'master-ose'
Move errors from EditTexts to TextInputLayouts

See merge request bitfireAT/davx5-ose!28
2020-03-03 23:50:14 +01:00
Ricki Hirner
b188a29596 Update gradle version and Android plugin; dependencies 2020-02-26 16:51:56 +01:00
Ricki Hirner
6455ff51e2 Fetch translations from Transifex 2020-02-20 18:13:03 +01:00
Ricki Hirner
cb88e39891 Fetch translations from Transifex 2020-01-23 18:36:49 +01:00
Ricki Hirner
900a5e58a3 Fetch translations from Transifex 2020-01-06 13:42:59 +01:00
Ricki Hirner
ca4422f374 Flavors: add privacy policy link to navigation drawer 2019-12-30 18:58:09 +01:00
Ricki Hirner
a134ffc7d7 Fetch translations from Transifex 2019-12-30 17:17:51 +01:00
Ricki Hirner
17a65e907c UiUtils.launchUri: show toast if no browser is installed 2019-12-28 15:33:03 +01:00
Ricki Hirner
d82c285f18 Add link to Privacy policy to Accounts drawer 2019-12-28 15:15:38 +01:00
Ricki Hirner
68d225e7d6 Fetch translations from Transifex 2019-12-22 11:00:41 +01:00
Ricki Hirner
76ad2bd94d Improve usage of Material theme 2019-12-03 18:46:41 +01:00
Ricki Hirner
ff02d8908a use Material theme; update AboutLibraries dependency 2019-12-03 17:13:56 +01:00
Ricki Hirner
d4a6f82110 Fetch translations from Transifex 2019-11-22 18:02:01 +01:00
Ricki Hirner
1e4fa8d104 Fetch translations from Transifex 2019-11-15 23:47:05 +01:00
Ricki Hirner
6eb8886c96 Fetch translations from Transifex 2019-11-13 00:02:29 +01:00
Ricki Hirner
a9fedf2c17 Login with URL: assume https:// URI scheme if none given 2019-11-10 10:33:17 +01:00
Ricki Hirner
2529ccd42c Fetch translations from Transifex 2019-10-25 11:08:06 +02:00
Ricki Hirner
2cc089a1fc Login Flow: optimization 2019-10-24 11:21:10 +02:00
tobiasKaminsky
8c6d689997 correct concatenate url with davPath.
Previously a subfolder was omitted:
serverUrl: http://localhost/nc
davPath: /remote.php/dav
-->
wrong: http://localhost/remote.php/dav
correct: http://localhost/nc/remote.php/dav
2019-10-24 11:17:25 +02:00
tobiasKaminsky
15f66a970a username was retrieved from intent, but not used 2019-10-24 11:17:17 +02:00
Ricki Hirner
0f928877aa Fetch translations from Transifex 2019-10-07 11:42:48 +02:00
Ricki Hirner
4b74005025 Implement Nextcloud Login Flow 2019-10-06 20:47:41 +02:00
Ricki Hirner
2448ea7a18 Fetch translations from Transifex 2019-09-21 11:45:23 +02:00
Ricki Hirner
31fecb0dc5 Fetch translations from Transifex (thanks for Bulgarian and Silesian!) 2019-09-20 00:06:50 +02:00
Ricki Hirner
215347b69d lint 2019-09-19 14:27:16 +02:00
Ricki Hirner
b6a0455b4f Enable Autofill for login screen 2019-08-25 16:35:19 +02:00
Ricki Hirner
11fa98cdaf Fetch translations from Transifex 2019-08-25 15:27:42 +02:00
Ricki Hirner
9e6b1037ae Fetch translations from Transifex 2019-07-20 22:10:10 +02:00
Ricki Hirner
f5ade54605 Fetch translations from Transifex 2019-07-08 21:40:34 +02:00
Ricki Hirner
d79744ada8 Fetch translations from Transifex 2019-06-09 11:05:46 +02:00
Ricki Hirner
722323f287 Fetch translations from Transifex 2019-05-29 18:09:58 +02:00
Ricki Hirner
a1f7a8a061 Use android:hint in TextInputLayout instead of TextInputEditText (should fix Meizu crashes) 2019-05-29 18:03:36 +02:00
Ricki Hirner
cd2f4baea2 Fetch translations from Transifex; add Finnish 2019-05-15 11:42:31 +02:00
Ricki Hirner
ae29de21cf Fetch translations from Transifex 2019-05-13 20:19:29 +02:00
Ricki Hirner
723e2bac12 Fetch translations from Transifex; new translation: Slovak (thanks brango67!) 2019-05-10 16:45:15 +02:00
Ricki Hirner
1c55c78e71 Fetch translations from Transifex 2019-05-09 12:21:34 +02:00
Ricki Hirner
9d3cf74f86 Fetch translations from Transifex 2019-05-06 19:35:11 +02:00
Ricki Hirner
666c069290 Fix crash in account setup 2019-04-18 13:35:41 +02:00
Ricki Hirner
37dffe420f Fetch translations from Transifex 2019-04-02 23:56:42 +02:00
Ricki Hirner
f11ed56032 Fetch translations from Transifex 2019-03-29 15:07:02 +01:00
Ricki Hirner
0d9402ebee Fetch translations from Transifex 2019-03-26 22:01:59 +01:00
Ricki Hirner
d6dcf7e1e1 Unify sync_prefs.xml by using string resource for package ID 2019-03-23 21:18:03 +01:00
Ricki Hirner
94326886e3 Fetch translations from Transifex 2019-03-23 21:07:42 +01:00
Ricki Hirner
524e3dffb2 About: use vector icon 2019-03-20 22:19:01 +01:00
Ricki Hirner
721244f340 Update beta feedback email address, libraries 2019-03-17 16:30:51 +01:00
Ricki Hirner
87382e229f Login: couple user name and email address 2019-03-17 16:09:51 +01:00
Ricki Hirner
f1444d1d1a Use ViewModel and data binding for login process 2019-03-15 22:39:00 +01:00
Ricki Hirner
9b0c0a40b3 Fetch translations from Transifex 2019-02-13 23:16:32 +01:00
Ricki Hirner
1dffa1bc69 Fetch translations from Transifex 2019-02-08 18:08:43 +01:00
Ricki Hirner
88566ba4bf Translations: fix positional argument (thanks @mbiebl) 2019-02-06 17:30:21 +01:00
Ricki Hirner
5a8d431ae1 Fetch translations from Transifex 2019-02-06 16:46:14 +01:00
Ricki Hirner
00a32ae8b4 Network security config per flavor 2019-01-18 12:03:35 +01:00
Ricki Hirner
5a651ed446 update homepage links; version bump to 2.2.3 2019-01-18 11:30:04 +01:00
Ricki Hirner
67683505d6 Fetch translations from Transifex 2019-01-13 21:47:06 +01:00
Ricki Hirner
ea134d7698 Fetch translations from Transifex 2019-01-08 19:17:49 +01:00
Ricki Hirner
1e0beb4e81 Rename dav4android to dav4jvm; update gradle 2019-01-06 18:15:59 +01:00
Ricki Hirner
a6a150a2e5 Fix Twitter link in gplay flavor 2019-01-04 22:57:14 +01:00
Ricki Hirner
5b555b4b2a Fetch translations from Transifex 2019-01-04 22:31:11 +01:00
Ricki Hirner
df39717be8 Fetch translations from Transifex 2019-01-03 18:55:32 +01:00
Ricki Hirner
03dec3bd72 Further DAVdroid -> DAVx5 replacements 2018-12-30 16:52:29 +01:00
Ricki Hirner
716b256bd5 New launcher icons 2018-12-30 15:30:11 +01:00
Ricki Hirner
295bd3fe9e Fetch translations from Transifex 2018-12-30 12:07:50 +01:00
Ricki Hirner
e9e59576a5 Rename DAVdroid to DAVx⁵ 2018-12-30 12:05:12 +01:00
Ricki Hirner
c039aea200 Refactor Settings provider
* don't use a separate :sync process anymore, so that settings management doesn't need IPC
* remove Settings service and IPC, use singleton with application Context instead
* adapt default number of sync worker threads
* library updates
2018-12-26 13:01:59 +01:00
Ricki Hirner
8d3f8ebdd4 Fetch translations from Transifex 2018-12-22 11:44:51 +01:00
Ricki Hirner
58c86c2174 Minor changes (lint/remove warnings) 2018-11-30 13:41:03 +01:00
Ricki Hirner
dbfc800eff Switch to AndroidX 2018-11-29 23:00:43 +01:00
Ricki Hirner
68e05874d7 Fetch translations from Transifex 2018-11-04 18:17:38 +01:00
Ricki Hirner
cf7cedb313 Handle unresolvable ACTION_VIEW intents; update gradle, Kotlin 2018-11-04 18:11:43 +01:00
Ricki Hirner
299ea45faa Fetch translations from Transifex 2018-08-28 13:40:35 +02:00
Ricki Hirner
36ee3398a1 Fetch translations from Transifex 2018-08-10 21:26:00 +02:00
Ricki Hirner
5cc1f353bc Fetch translations from Transifex; always replace "..." by "…" 2018-08-05 10:59:01 +02:00
Ricki Hirner
2bc542e120 Fetch translations from Transifex 2018-07-28 14:34:09 +02:00
Ricki Hirner
942082b3e7 Fetch translations from Transifex 2018-07-27 16:52:57 +02:00
Ricki Hirner
42269ff83f Fetch translations from Transifex 2018-07-22 11:18:50 +02:00
Ricki Hirner
d6a14fadd4 Fetch translations from Transifex 2018-07-13 15:06:59 +02:00
Ricki Hirner
2e92b38b8f New About activity
* new About activity using AboutLibraries library
* include DAVdroid version and other non-personal information in URL when DAVdroid homepage is opened
  (so that we know what DAVdroid versions are used out there and maybe can provide version-specific help)
2018-07-13 14:57:14 +02:00
Ricki Hirner
b48d6dfe0e move lambda expressions out of parentheses; use CREATOR-named companion objects for Parcelable 2018-06-17 16:34:45 +02:00
Ricki Hirner
7b15da2cd5 Fetch translations from Transifex 2018-06-08 11:50:39 +02:00
Ricki Hirner
24e2092f1b Update copyright 2018-05-28 12:04:43 +02:00
Ricki Hirner
902305cc5e Fetch translations from Transifex 2018-05-28 10:47:49 +02:00
Ricki Hirner
5524785c6b Fetch translations from Transifex 2018-05-15 14:21:37 +02:00
Ricki Hirner
b082cd9880 Code cleanup (lint) 2018-04-28 21:21:46 +02:00
Ricki Hirner
9fd4676d8b Fetch translations from Transifex 2018-04-26 10:54:20 +02:00
Ricki Hirner
c730a7814d Fetch translations from Transifex 2018-04-13 10:24:52 +02:00
Ricki Hirner
c6a06c3453 Fetch translations from Transifex 2018-03-26 09:37:41 +02:00
Ricki Hirner
9eee586c0a Minor fixes 2018-03-15 18:13:53 +01:00
Ricki Hirner
1c603ffc84 Themeing, minor refactoring 2018-03-15 12:09:27 +01:00
Ricki Hirner
b1e85a5295 Themeing, minor refactoring 2018-03-15 12:09:27 +01:00
Ricki Hirner
ae672648f4 Sync logic fix, theming, ProGuard 2018-03-07 23:24:49 +01:00
Ricki Hirner
ddcff6ca66 Update to support library 27.1.0 and use it wherever possible
* Fragment transactions can now be done in onLoadFinished().
2018-03-06 13:58:43 +01:00
Ricki Hirner
ff73b49560 Fetch translations from Transifex 2018-01-20 15:23:58 +01:00
Ricki Hirner
18166926fa Fetch translations from Transifex 2018-01-18 16:13:52 +01:00
Ricki Hirner
ab10a27575 Login activity: add padding; sync: re-throw Interrupted(IO)Exception 2018-01-15 21:32:21 +01:00
Ricki Hirner
5bfb875019 Fetch translations from Transifex 2018-01-15 20:52:33 +01:00
Ricki Hirner
2e72fb4c7b Login activity
* use TextInputLayout for input fields
* use support library instead of custom EditPassword widget
* improve client certificate UI
2018-01-15 13:58:21 +01:00
Ricki Hirner
38c6486610 Login with client certificates
* setup UI: login with URL and client certificate
* account settings UI: show either username/password or client certificate alias
* AccountSettings: serve credentials in generalized Credentials objects
* HttpClient: use Credentials (instead of username/password) for authentication
* HttpClient: always use CustomTlsSocketFactory
* CustomTlsSocketFactory: support client certificates
2018-01-13 22:56:33 +01:00
Ricki Hirner
ec9ac3a8cb Fetch translations from Transifex 2018-01-02 19:42:27 +01:00
Ricki Hirner
4d9b5c1ef7 Fetch translations from Transifex 2017-12-26 13:07:17 +01:00
Ricki Hirner
ca2344ea2c Fetch translations from Transifex 2017-12-16 22:02:05 +01:00
Ricki Hirner
d1644ab92b Fetch translations from Transifex 2017-12-16 19:08:49 +01:00
Ricki Hirner
4c97d501ce Navigation drawer: add link to manual 2017-12-16 19:08:45 +01:00
Ricki Hirner
599ed4d9a3 Navigation drawer: add link to manual 2017-12-16 19:08:45 +01:00
Ricki Hirner
633c3f6ae3 Use email instead of forum for beta feedback 2017-12-03 15:47:27 +01:00
Ricki Hirner
6822a0e5bc Fetch translations from Transifex 2017-12-03 15:23:31 +01:00
Ricki Hirner
91776fe0ae Fetch translations from Transifex 2017-11-25 18:49:52 +01:00
Ricki Hirner
1dfc34ace4 Fetch translations from Transifex 2017-11-11 21:26:02 +01:00
Ricki Hirner
59306a4c28 Fetch translations from Transifex 2017-10-31 09:20:12 +01:00
Ricki Hirner
3671a80ecb Fetch translations from Transifex 2017-10-25 20:38:05 +02:00
Ricki Hirner
5c8da1a4ec Fetch translations from Transifex 2017-10-15 17:44:48 +02:00
Ricki Hirner
e3349af73b Accounts drawer: beta feedback 2017-10-13 20:53:59 +02:00
Ricki Hirner
574576fbf8 Accounts drawer: beta feedback 2017-10-13 20:53:59 +02:00
Ricki Hirner
d2b6cba230 Fetch translations from Transifex 2017-10-13 20:45:13 +02:00
Ricki Hirner
19d81033ba Minor bug fixes, move beta feedback to navigation drawer 2017-10-13 13:30:01 +02:00
Ricki Hirner
996aa87b8e Managed DAVdroid, settings framework, theming, launcher icons, lib update 2017-10-13 12:24:35 +02:00
Ricki Hirner
47cc2c5515 Fetch translations from Transifex 2017-09-25 12:07:34 +02:00
Ricki Hirner
6e96c745a5 Fetch translations from Transifex 2017-09-23 21:23:37 +02:00
Ricki Hirner
3055e67310 Fetch translations from Transifex 2017-09-20 22:15:41 +02:00
Ricki Hirner
4f9892ee1b Fetch translations from Transifex 2017-09-15 13:29:22 +02:00
Ricki Hirner
e8a46171fd Fetch translations from Transifex 2017-09-10 20:17:31 +02:00
Ricki Hirner
92486d93e5 Fetch translations from Transifex 2017-09-01 15:12:35 +02:00
Ricki Hirner
4604afe63d Fetch translations from Transifex 2017-08-30 21:09:42 +02:00
Ricki Hirner
a41155cacf Fetch translations from Transifex 2017-08-22 15:17:20 +02:00
Ricki Hirner
362cbd7f12 Fetch translations from Transifex 2017-08-15 15:52:46 +02:00
Ricki Hirner
02a8ee2864 Fetch translations from Transifex 2017-08-05 13:13:49 +02:00
Ricki Hirner
e11c3c3e35 Fix device rotate crash bug, cert4android race condition 2017-08-03 20:46:32 +02:00
Ricki Hirner
70cfefb2bc Rewrite last UI classes to Kotlin; allow cancellation of resource detection 2017-08-02 16:23:51 +02:00
Ricki Hirner
99ed6aa159 Rewrite to Kotlin
* rewrite some UI classes
* move logic from App to CustomCertificates and Logger singletons
2017-07-31 15:30:11 +02:00
Ricki Hirner
db141fa826 Fetch translations from Transifex 2017-07-27 16:49:48 +02:00
Ricki Hirner
b69b72de19 Update copyright 2017-07-19 19:30:57 +02:00
Ricki Hirner
7f59874da7 Remove gplay license check 2017-07-19 19:29:42 +02:00
Ricki Hirner
9f53b62b42 Fetch translations from Transifex 2017-07-06 12:10:30 +02:00
Ricki Hirner
c164f4cf9c GPlay: fix NPE in LicenseCheckSyncPlugin 2017-07-03 19:41:30 +02:00
Ricki Hirner
0623ebcec8 Fetch translations from Transifex 2017-07-03 18:54:35 +02:00
Ricki Hirner
19734f16b7 License check for GPlay version 2017-06-20 11:50:39 +02:00
Ricki Hirner
c81dc3c0ad Fetch translations from Transifex 2017-06-09 16:34:03 +02:00
Ricki Hirner
d0cd8b17da Fetch translations from Transifex 2017-06-03 19:28:11 +02:00
Ricki Hirner
816d5e4e29 Fetch translations from Transifex 2017-05-14 12:19:11 +02:00
Ricki Hirner
e339ac71ef Fetch translations from Transifex 2017-04-25 14:12:11 +02:00
Ricki Hirner
6f2929ca18 Use untranslated User-Agent string
* refactoring: don't use global string variables
2017-04-24 22:52:52 +02:00
Ricki Hirner
dfacb65e15 Fetch translations from Transifex 2017-04-16 15:49:22 +02:00
Ricki Hirner
5e3f7e93b2 Branding strings
* HTTP client: use app name as User-Agent
* use string resources for homepage URLs
* MultiSync: add FAQ
2017-04-11 16:23:38 +02:00
Ricki Hirner
89a6d173e6 Fetch translations from Transifex 2017-03-26 19:31:00 +02:00
Ricki Hirner
2f35b32850 Unify action bar icon colors 2017-03-12 13:24:33 +01:00
Ricki Hirner
55dbefded5 Update translations from Transifex 2017-03-03 12:53:30 +01:00
Ricki Hirner
608439081e Fetch translations from Transifex 2017-03-02 23:43:46 +01:00
Ricki Hirner
cbe1360973 Soldupe/MultiSync branding 2017-02-28 14:21:04 +01:00
Ricki Hirner
eddac368be Fetch translations from Transifex 2017-02-17 13:55:36 +01:00
Ricki Hirner
994577242c Fetch translations from Transifex (fixes crash in Spanish version) 2017-01-29 19:22:47 +01:00
Ricki Hirner
a00a92e01a Fetch translations from Transifex 2017-01-01 12:26:43 +01:00
Ricki Hirner
ac008ae379 Fetch translations from Transifex 2016-12-23 15:55:50 +01:00
Ricki Hirner
6779155812 Fetch translations from Transifex 2016-11-14 18:41:24 +01:00
Ricki Hirner
8acf18ef7a Fetch translations from Transifex 2016-11-13 20:34:28 +01:00
Ricki Hirner
3f5de489b1 Fetch translations from Transifex
ical4android: fix for events without dtend/duration
2016-11-06 17:36:39 +01:00
Ricki Hirner
9c98a4abd8 Fetch translations from Transifex 2016-10-21 20:10:18 +02:00
Ricki Hirner
c71d29bac3 Fetch translations from Transifex 2016-10-14 21:19:56 +02:00
Ricki Hirner
c97bd2b3e6 Android 4.0/4.1 fixes
* require API level 15 for TransactionTooLargeException
* use SQLite WAL only on API level 16+
* various database access, provider access and UI fixes
2016-10-04 16:12:44 +02:00
Ricki Hirner
ce4395d0fe Fetch translations from Transifex 2016-10-03 20:43:33 +02:00
Ricki Hirner
13268bf79f Import strings from Transifex 2016-09-18 16:51:05 +02:00
Ricki Hirner
08b0ca3ce5 Fetch translations from Transifex 2016-09-02 12:15:17 +02:00
Ricki Hirner
442ec8ceb6 gplay version: remove donation link
Fix icons again
2016-09-02 00:56:00 +02:00
Ricki Hirner
b58b603f92 New launcher logo
* new launcher logo (contributed by Christoph Scheidl)
2016-09-01 22:48:12 +02:00
Ricki Hirner
fddacd4687 iCloud: UI and strings 2016-08-14 20:57:31 +02:00
Ricki Hirner
9c113bbcff White icons for Apple® iCloud®, hallelujah™ 2016-08-14 13:18:45 +02:00
Ricki Hirner
708e85b782 Accept intent extras for LoginActivity 2016-08-13 23:06:28 +02:00
Ricki Hirner
3cf0a04597 Fetch translations from Transifex 2016-08-06 00:11:40 +02:00
Ricki Hirner
d2b29e9986 Improve HTTP authentication
* use preemptive Basic auth automatically for HTTPS connections
* cache auth parameters (Basic/Digest)
2016-08-05 23:17:32 +02:00
Ricki Hirner
c238769b23 Fetch translations from Transifex 2016-08-02 19:27:14 +02:00
Ricki Hirner
ffc25ab3e8 Clean up launcher icon
* clean up launcher icon
* update dependencies
2016-08-01 21:03:21 +02:00
Ricki Hirner
79c9a8aa51 Basic subscription management
* SDK version 24
* Subscription management and GUI
2016-08-01 20:24:32 +02:00
Ricki Hirner
d40fe519be Initial iCloud version
* new gradle configField: useMTM
* new gradle source dir: davdroid (for DAVdroid OSE + DAVdroid variants)
* move strings and default login fragment to davdroid source dir
* iCloud AndroidManifest: add billing permission and SubscriptionActivity
* add sync plugins
* iCloud flavor + sync plugin: in-app billing
* iCloud flavor: login credentials fragment + font
* iCloud flavor: new strings
* use account type from string assets instead of hardcoded constant
2016-07-29 14:27:05 +02:00
Ricki Hirner
9d88fceb8b Add standard and gplay product flavor 2016-06-24 00:06:43 +02:00
652 changed files with 8646 additions and 6853 deletions

8
.github/CODEOWNERS vendored
View File

@@ -1,8 +1,4 @@
# See https://docs.github.com/de/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners
# For combination with "Require review from code owners" for main-ose branch.
# Dependabot
gradle/** @bitfireAT/app-dev
# everything else
* @rfc2822
# For combination with "Require review from code owners" for main-ose branch:
* @bitfireAT/app-dev

View File

@@ -9,9 +9,6 @@ updates:
interval: "weekly"
commit-message:
prefix: "[CI] "
labels:
- "github_actions"
- "dependencies"
groups:
ci-actions:
patterns: ["*"]
@@ -20,8 +17,6 @@ updates:
directory: "/"
schedule:
interval: "weekly"
labels: # don't create "java" label (default for gradle ecosystem)
- "dependencies"
groups:
app-dependencies:
patterns: ["*"]

View File

@@ -8,7 +8,6 @@ on:
branches: [ main-ose ]
schedule:
- cron: '22 10 * * 1'
concurrency:
group: codeql-${{ github.ref }}
cancel-in-progress: true
@@ -22,6 +21,11 @@ jobs:
contents: read
security-events: write
strategy:
fail-fast: false
matrix:
language: [ 'java' ]
steps:
- name: Checkout repository
uses: actions/checkout@v6
@@ -38,11 +42,15 @@ jobs:
- name: Initialize CodeQL
uses: github/codeql-action/init@v4
with:
languages: java-kotlin
build-mode: manual # autobuild uses older JDK
languages: ${{ matrix.language }}
- name: Build # we must not use build cache here
run: ./gradlew --no-daemon --configuration-cache app:assembleDebug
# Autobuild attempts to build any compiled languages (C/C++, C#, Go, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
#- name: Autobuild
# uses: github/codeql-action/autobuild@v2
- name: Build
run: ./gradlew --build-cache --configuration-cache --no-daemon app:assembleOseDebug
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v4

View File

@@ -1,24 +0,0 @@
name: Dependency Submission
on:
push:
branches: [ 'main-ose' ]
permissions:
contents: write
jobs:
dependency-submission:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-java@v5
with:
distribution: temurin
java-version: 21
- name: Generate and submit dependency graph
uses: gradle/actions/dependency-submission@v5
with:
cache-encryption-key: ${{ secrets.gradle_encryption_key }}
dependency-graph-exclude-configurations: '.*[Tt]est.* .*[cC]heck.*'

View File

@@ -9,19 +9,10 @@ concurrency:
group: test-dev-${{ github.ref }}
cancel-in-progress: true
# We provide a remote gradle build cache. Take the settings from the secrets and enable
# configuration and build cache for all gradle jobs.
#
# Note: The secrets are not available for forks and Dependabot PRs.
env:
GRADLE_BUILDCACHE_URL: ${{ secrets.gradle_buildcache_url }}
GRADLE_BUILDCACHE_USERNAME: ${{ secrets.gradle_buildcache_username }}
GRADLE_BUILDCACHE_PASSWORD: ${{ secrets.gradle_buildcache_password }}
GRADLE_OPTS: -Dorg.gradle.caching=true -Dorg.gradle.configuration-cache=true
jobs:
compile:
name: Compile
name: Compile for build cache
if: ${{ github.ref == 'refs/heads/main-ose' }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
@@ -31,31 +22,16 @@ jobs:
java-version: 21
# See https://community.gradle.org/github-actions/docs/setup-gradle/ for more information
- uses: gradle/actions/setup-gradle@v5
- uses: gradle/actions/setup-gradle@v5 # creates build cache when on main branch
with:
cache-encryption-key: ${{ secrets.gradle_encryption_key }}
cache-read-only: false # allow branches to update their configuration cache
gradle-home-cache-excludes: caches/build-cache-1 # don't cache local build cache because we use a remote cache
dependency-graph: generate-and-submit # submit Github Dependency Graph info
- name: Cache Android environment
uses: actions/cache@v5
with:
path: ~/.config/.android # needs to be cached so that configuration cache can work
key: android-${{ hashFiles('app/build.gradle.kts') }}
- run: ./gradlew --build-cache --configuration-cache app:compileOseDebugSource
- name: Compile
run: ./gradlew app:compileOseDebugSource
# Cache configurations for the other jobs (including assemble for CodeQL)
- name: Populate configuration cache
run: |
./gradlew --dry-run app:assembleDebug
./gradlew --dry-run app:lintOseDebug
./gradlew --dry-run app:testOseDebugUnitTest
./gradlew --dry-run app:virtualOseDebugAndroidTest
unit_tests:
test:
needs: compile
if: ${{ !cancelled() }} # even if compile didn't run (because not on main branch)
name: Lint and unit tests
runs-on: ubuntu-latest
steps:
@@ -69,20 +45,14 @@ jobs:
cache-encryption-key: ${{ secrets.gradle_encryption_key }}
cache-read-only: true
- name: Restore Android environment
uses: actions/cache/restore@v5
with:
path: ~/.config/.android
key: android-${{ hashFiles('app/build.gradle.kts') }}
- name: Run lint
run: ./gradlew --build-cache --configuration-cache app:lintOseDebug
- name: Run unit tests
run: ./gradlew --build-cache --configuration-cache app:testOseDebugUnitTest
- name: Lint checks
run: ./gradlew app:lintOseDebug
- name: Unit tests
run: ./gradlew app:testOseDebugUnitTest
instrumented_tests:
test_on_emulator:
needs: compile
if: ${{ !cancelled() }} # even if compile didn't run (because not on main branch)
name: Instrumented tests
runs-on: ubuntu-latest
steps:
@@ -96,41 +66,17 @@ jobs:
cache-encryption-key: ${{ secrets.gradle_encryption_key }}
cache-read-only: true
- name: Restore Android environment
uses: actions/cache/restore@v5
with:
path: ~/.config/.android
key: android-${{ hashFiles('app/build.gradle.kts') }}
# gradle and Android SDK often take more space than what is available on the default runner.
# We try to free a few GB here to make gradle-managed devices more reliable.
- name: Free some disk space
uses: jlumbroso/free-disk-space@main
with:
android: false # we need the Android SDK
large-packages: false # apt takes too long
swap-storage: false # gradle needs much memory
- name: Restore AVD
id: restore-avd
uses: actions/cache/restore@v5
with:
path: ~/.config/.android/avd # where AVD is stored
key: avd-${{ hashFiles('app/build.gradle.kts') }} # gradle-managed devices are defined there
# Enable virtualization for Android emulator
- name: Enable KVM group perms
run: |
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
sudo udevadm control --reload-rules
sudo udevadm trigger --name-match=kvm
- name: Instrumented tests
run: ./gradlew app:virtualOseDebugAndroidTest
- name: Cache AVD
uses: actions/cache/save@v5
if: steps.restore-avd.outputs.cache-hit != 'true'
uses: actions/cache@v4
with:
path: ~/.config/.android/avd # where AVD is stored
path: ~/.config/.android/avd
key: avd-${{ hashFiles('app/build.gradle.kts') }} # gradle-managed devices are defined there
- name: Run device tests
run: ./gradlew --build-cache --configuration-cache app:virtualCheck

30
.tx/config Normal file
View File

@@ -0,0 +1,30 @@
[main]
host = https://www.transifex.com
lang_map = ar_SA: ar, en_GB: en-rGB, fa_IR: fa-rIR, fi_FI: fi, nb_NO: nb, pt_BR: pt-rBR, sk_SK: sk, sl_SI: sl, tr_TR: tr, zh_CN: zh, zh_TW: zh-rTW
[o:bitfireAT:p:davx5:r:app]
file_filter = app/src/main/res/values-<lang>/strings.xml
source_file = app/src/main/res/values/strings.xml
source_lang = en
type = ANDROID
minimum_perc = 20
resource_name = App strings (all flavors)
# Attention: fastlane directories are like "en-us", not "en-rUS"!
[o:bitfireAT:p:davx5:r:metadata-short-description]
file_filter = fastlane/metadata/android/<lang>/short_description.txt
source_file = fastlane/metadata/android/en-US/short_description.txt
source_lang = en
type = TXT
minimum_perc = 100
resource_name = Metadata: short description
[o:bitfireAT:p:davx5:r:metadata-full-description]
file_filter = fastlane/metadata/android/<lang>/full_description.txt
source_file = fastlane/metadata/android/en-US/full_description.txt
source_lang = en
type = TXT
minimum_perc = 100
resource_name = Metadata: full description

View File

@@ -14,11 +14,24 @@ If you send us a pull request, our CLA bot will ask you to sign the
Contributor's License Agreement so that we can use your contribution.
# Copyright notice
# Copyright
Make sure that every file that contains significant work (at least every code file)
starts with the copyright header. Android Studio should do so automatically because the
configuration is stored in the repository (`.idea/copyright`).
starts with the copyright header:
```
/*
* Copyright © All Contributors. See LICENSE and AUTHORS in the root directory for details.
*/
```
You can set this in Android Studio:
1. Settings / Editor / Copyright / Copyright Profiles
2. Paste the text above (without the stars).
3. Set Formatting so that the preview exactly looks like above; one blank line after the block.
4. Set this copyright profile as the default profile for the project.
5. Apply copyright: right-click in file tree / Update copyright.
# Style guide
@@ -97,3 +110,8 @@ Test classes should be in the appropriate directory (see existing tests) and in
tested class. Tests are usually be named like `methodToBeTested_Condition()`, see
[Test apps on Android](https://developer.android.com/training/testing/).
# Authors
If you make significant contributions, feel free to add yourself to the [AUTHORS file](AUTHORS).

View File

@@ -1,9 +1,9 @@
[![Follow @davx5app@fosstodon.org](https://img.shields.io/mastodon/follow/109598783742737223?domain=https%3A%2F%2Ffosstodon.org&style=flat-square)](https://fosstodon.org/@davx5app)
[![Website](https://img.shields.io/website?style=flat-square&up_color=%237cb342&url=https%3A%2F%2Fwww.davx5.com)](https://www.davx5.com/)
[![License](https://img.shields.io/github/license/bitfireAT/davx5-ose?style=flat-square)](https://github.com/bitfireAT/davx5-ose/blob/main/LICENSE)
[![F-Droid](https://img.shields.io/f-droid/v/at.bitfire.davdroid?style=flat-square)](https://f-droid.org/packages/at.bitfire.davdroid/)
![GitHub Downloads (all assets, all releases)](https://img.shields.io/github/downloads/bitfireAT/davx5-ose/total?label=GitHub%20downloads)
[![License](https://img.shields.io/github/license/bitfireAT/davx5-ose?style=flat-square)](https://github.com/bitfireAT/davx5-ose/blob/main/LICENSE)
[![Follow @davx5app@fosstodon.org](https://img.shields.io/mastodon/follow/109598783742737223?domain=https%3A%2F%2Ffosstodon.org&style=flat-square)](https://fosstodon.org/@davx5app)
[![Development tests](https://github.com/bitfireAT/davx5-ose/actions/workflows/test-dev.yml/badge.svg)](https://github.com/bitfireAT/davx5-ose/actions/workflows/test-dev.yml)
![DAVx⁵ logo](app/src/main/res/mipmap-xxxhdpi/ic_launcher.png)
@@ -11,10 +11,8 @@
DAVx⁵
========
> [!IMPORTANT]
> Please see the [DAVx⁵ Web site](https://www.davx5.com) for
> comprehensive information about DAVx⁵, including a list of services it has been tested with,
> a manual and FAQ.
Please see the [DAVx⁵ Web site](https://www.davx5.com) for
comprehensive information about DAVx⁵, including a list of services it has been tested with.
DAVx⁵ is licensed under the [GPLv3 License](LICENSE).

View File

View File

@@ -6,8 +6,9 @@ plugins {
alias(libs.plugins.android.application)
alias(libs.plugins.compose.compiler)
alias(libs.plugins.hilt)
alias(libs.plugins.kotlin.serialization)
alias(libs.plugins.kotlin.android)
alias(libs.plugins.ksp)
alias(libs.plugins.mikepenz.aboutLibraries.android)
}
@@ -18,14 +19,17 @@ android {
defaultConfig {
applicationId = "at.bitfire.davdroid"
versionCode = 405090005
versionName = "4.5.9"
versionCode = 405060100
versionName = "4.5.6.1"
base.archivesName = "davx5-$versionCode-$versionName"
base.archivesName = "davx5-ose-$versionName"
minSdk = 24 // Android 7.0
targetSdk = 36 // Android 16
// whether the build supports and allows to use custom certificates
buildConfigField("boolean", "allowCustomCerts", "true")
testInstrumentationRunner = "at.bitfire.davdroid.HiltTestRunner"
}
@@ -48,20 +52,32 @@ android {
}
// Java namespace for our classes (not to be confused with Android package ID)
namespace = "com.davx5.ose"
namespace = "at.bitfire.davdroid"
flavorDimensions += "distribution"
productFlavors {
create("standard")
create("ose") {
dimension = "distribution"
versionNameSuffix = "-ose"
}
create("gplay") {
versionNameSuffix = "-gplay"
}
}
sourceSets {
getByName("standard") {
kotlin.srcDirs("src/standard/kotlin", "src/davdroid/kotlin")
res.srcDirs("src/standard/res", "src/davdroid/res")
}
getByName("androidTest") {
assets.srcDir("$projectDir/schemas")
}
getByName("gplay") {
kotlin.srcDirs("src/gplay/kotlin", "src/davdroid/kotlin")
res.srcDirs("src/gplay/res", "src/davdroid/res")
}
}
signingConfigs {
@@ -127,10 +143,7 @@ aboutLibraries {
}
dependencies {
// app core
implementation(project(":core"))
// Kotlin / Android
// core
implementation(libs.kotlin.stdlib)
implementation(libs.kotlinx.coroutines)
coreLibraryDesugaring(libs.android.desugaring)
@@ -158,22 +171,21 @@ dependencies {
// Jetpack Compose
implementation(libs.compose.accompanist.permissions)
implementation(platform(libs.androidx.compose.bom))
implementation(libs.androidx.compose.material3)
implementation(libs.androidx.compose.material3.adaptive)
implementation(libs.androidx.compose.materialIconsExtended)
debugImplementation(libs.androidx.compose.ui.tooling)
implementation(libs.androidx.compose.ui.toolingPreview)
implementation(platform(libs.compose.bom))
implementation(libs.compose.material3)
implementation(libs.compose.materialIconsExtended)
debugImplementation(libs.compose.ui.tooling)
implementation(libs.compose.ui.toolingPreview)
// Glance Widgets
implementation(libs.androidx.glance.base)
implementation(libs.androidx.glance.material3)
implementation(libs.glance.base)
implementation(libs.glance.material)
// Jetpack Room
implementation(libs.androidx.room.runtime)
implementation(libs.androidx.room.base)
implementation(libs.androidx.room.paging)
ksp(libs.androidx.room.compiler)
implementation(libs.room.runtime)
implementation(libs.room.base)
implementation(libs.room.paging)
ksp(libs.room.compiler)
// own libraries
implementation(libs.bitfire.cert4android)
@@ -190,10 +202,8 @@ dependencies {
implementation(libs.conscrypt)
implementation(libs.dnsjava)
implementation(libs.guava)
implementation(libs.ktor.client.content.negotiation)
implementation(libs.ktor.client.core)
implementation(libs.ktor.client.okhttp)
implementation(libs.ktor.serialization.kotlinx.json)
implementation(libs.mikepenz.aboutLibraries.m3)
implementation(libs.okhttp.base)
implementation(libs.okhttp.brotli)
@@ -213,7 +223,6 @@ dependencies {
// for tests
androidTestImplementation(libs.androidx.arch.core.testing)
androidTestImplementation(libs.androidx.room.testing)
androidTestImplementation(libs.androidx.test.core)
androidTestImplementation(libs.androidx.test.junit)
androidTestImplementation(libs.androidx.test.rules)
@@ -224,6 +233,7 @@ dependencies {
androidTestImplementation(libs.kotlinx.coroutines.test)
androidTestImplementation(libs.mockk.android)
androidTestImplementation(libs.okhttp.mockwebserver)
androidTestImplementation(libs.room.testing)
testImplementation(libs.bitfire.dav4jvm)
testImplementation(libs.junit)
@@ -231,3 +241,14 @@ dependencies {
testImplementation(libs.okhttp.mockwebserver)
testImplementation(libs.robolectric)
}
// build variants (flavors)
val gplayImplementation by configurations {
dependencies {
implementation(libs.android.billing)
implementation(libs.android.review)
implementation(libs.confettikit)
}
}

View File

1
app/src/.gitignore vendored Normal file
View File

@@ -0,0 +1 @@
espressoTest

View File

@@ -1,6 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:installLocation="internalOnly">
<!-- account management permissions not required for own accounts since API level 22 -->
@@ -8,9 +7,4 @@
<uses-permission android:name="android.permission.GET_ACCOUNTS" android:maxSdkVersion="22"/>
<uses-permission android:name="android.permission.MANAGE_ACCOUNTS" android:maxSdkVersion="22"/>
<!--
Since Mockk 1.14.7 it's required to use minSdk 26. We use 24, so override for tests.
-->
<uses-sdk tools:overrideLibrary="io.mockk.android,io.mockk.proxy.android" />
</manifest>

View File

@@ -10,6 +10,7 @@ import android.os.Build
import android.os.Bundle
import androidx.test.runner.AndroidJUnitRunner
import at.bitfire.davdroid.di.TestCoroutineDispatchersModule
import at.bitfire.davdroid.test.BuildConfig
import at.bitfire.synctools.log.LogcatHandler
import dagger.hilt.android.testing.HiltTestApplication
import java.util.logging.Level
@@ -28,7 +29,7 @@ class HiltTestRunner : AndroidJUnitRunner() {
val rootLogger = Logger.getLogger("")
rootLogger.level = Level.ALL
rootLogger.handlers.forEach { rootLogger.removeHandler(it) }
rootLogger.addHandler(LogcatHandler(javaClass.name))
rootLogger.addHandler(LogcatHandler(BuildConfig.APPLICATION_ID))
// MockK requirements
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.P)

View File

@@ -4,6 +4,7 @@
package at.bitfire.davdroid.db
import android.security.NetworkSecurityPolicy
import androidx.test.filters.SmallTest
import at.bitfire.dav4jvm.okhttp.DavResource
import at.bitfire.dav4jvm.property.webdav.WebDAV
@@ -18,6 +19,7 @@ import org.junit.Assert.assertEquals
import org.junit.Assert.assertFalse
import org.junit.Assert.assertNull
import org.junit.Assert.assertTrue
import org.junit.Assume
import org.junit.Before
import org.junit.Rule
import org.junit.Test
@@ -40,6 +42,7 @@ class CollectionTest {
hiltRule.inject()
httpClient = httpClientBuilder.build()
Assume.assumeTrue(NetworkSecurityPolicy.getInstance().isCleartextTrafficPermitted)
}

View File

@@ -5,10 +5,6 @@
package at.bitfire.davdroid.di
import at.bitfire.davdroid.di.TestCoroutineDispatchersModule.standardTestDispatcher
import at.bitfire.davdroid.di.scope.DefaultDispatcher
import at.bitfire.davdroid.di.scope.IoDispatcher
import at.bitfire.davdroid.di.scope.MainDispatcher
import at.bitfire.davdroid.di.scope.SyncDispatcher
import dagger.Module
import dagger.Provides
import dagger.hilt.components.SingletonComponent

View File

@@ -4,6 +4,7 @@
package at.bitfire.davdroid.network
import android.security.NetworkSecurityPolicy
import dagger.hilt.android.testing.HiltAndroidRule
import dagger.hilt.android.testing.HiltAndroidTest
import io.ktor.client.request.get
@@ -16,6 +17,7 @@ import org.junit.After
import org.junit.Assert.assertEquals
import org.junit.Assert.assertNull
import org.junit.Assert.assertTrue
import org.junit.Assume
import org.junit.Before
import org.junit.Rule
import org.junit.Test
@@ -47,14 +49,6 @@ class HttpClientBuilderTest {
}
@Test
fun testBuild_SharesConnectionPoolAndDispatcher() {
val client1 = httpClientBuilder.get().build()
val client2 = httpClientBuilder.get().build()
assertEquals(client1.connectionPool, client2.connectionPool)
assertEquals(client1.dispatcher, client2.dispatcher)
}
@Test
fun testBuildKtor_CreatesWorkingClient() = runTest {
server.enqueue(MockResponse()
@@ -70,6 +64,7 @@ class HttpClientBuilderTest {
@Test
fun testCookies() {
Assume.assumeTrue(NetworkSecurityPolicy.getInstance().isCleartextTrafficPermitted)
val url = server.url("/test")
// set cookie for root path (/) and /test path in first response

View File

@@ -20,9 +20,7 @@ import dagger.hilt.android.testing.HiltAndroidRule
import dagger.hilt.android.testing.HiltAndroidTest
import org.junit.After
import org.junit.Assert.assertEquals
import org.junit.Assume
import org.junit.Before
import org.junit.Ignore
import org.junit.Rule
import org.junit.Test
import org.junit.rules.TestRule
@@ -63,11 +61,10 @@ class LocalCalendarStoreTest {
}
@Ignore("Flaky in CI")
@Test
fun testUpdateAccount_updatesOwnerAccount() {
// Verify initial state (assume to skip and prevent flaky test failures)
Assume.assumeTrue("InitialAccountName" == getOwnerAccount())
// Verify initial state
verifyOwnerAccountIs(provider, "InitialAccountName")
// Rename account
val oldAccount = account
@@ -77,7 +74,8 @@ class LocalCalendarStoreTest {
localCalendarStore.updateAccount(oldAccount, account, provider)
// Verify [Calendar.OWNER_ACCOUNT] of local calendar was updated
assertEquals("ChangedAccountName", getOwnerAccount())
verifyOwnerAccountIs(provider, "ChangedAccountName")
}
@@ -97,7 +95,7 @@ class LocalCalendarStoreTest {
)
)!!.asSyncAdapter(account)
private fun getOwnerAccount(): String? {
private fun verifyOwnerAccountIs(provider: ContentProviderClient, expectedOwnerAccount: String) {
provider.query(
calendarUri,
arrayOf(Calendars.OWNER_ACCOUNT),
@@ -105,9 +103,9 @@ class LocalCalendarStoreTest {
arrayOf(account.name),
null
)!!.use { cursor ->
if (!cursor.moveToNext())
return null
return cursor.getString(0)
cursor.moveToNext()
val ownerAccount = cursor.getString(0)
assertEquals(expectedOwnerAccount, ownerAccount)
}
}

View File

@@ -4,6 +4,7 @@
package at.bitfire.davdroid.servicedetection
import android.security.NetworkSecurityPolicy
import at.bitfire.davdroid.db.AppDatabase
import at.bitfire.davdroid.db.Collection
import at.bitfire.davdroid.db.Service
@@ -21,6 +22,7 @@ import okhttp3.mockwebserver.MockWebServer
import okhttp3.mockwebserver.RecordedRequest
import org.junit.After
import org.junit.Assert.assertEquals
import org.junit.Assume
import org.junit.Before
import org.junit.Rule
import org.junit.Test
@@ -68,6 +70,7 @@ class CollectionsWithoutHomeSetRefresherTest {
// build HTTP client
client = httpClientBuilder.build()
Assume.assumeTrue(NetworkSecurityPolicy.getInstance().isCleartextTrafficPermitted)
// insert test service
val serviceId = db.serviceDao().insertOrReplace(

View File

@@ -4,6 +4,7 @@
package at.bitfire.davdroid.servicedetection
import android.security.NetworkSecurityPolicy
import at.bitfire.dav4jvm.okhttp.DavResource
import at.bitfire.dav4jvm.property.carddav.CardDAV
import at.bitfire.dav4jvm.property.webdav.WebDAV
@@ -24,6 +25,7 @@ import org.junit.Assert.assertEquals
import org.junit.Assert.assertFalse
import org.junit.Assert.assertNull
import org.junit.Assert.assertTrue
import org.junit.Assume
import org.junit.Before
import org.junit.Rule
import org.junit.Test
@@ -74,6 +76,7 @@ class DavResourceFinderTest {
client = httpClientBuilder
.authenticate(domain = null, getCredentials = { credentials })
.build()
Assume.assumeTrue(NetworkSecurityPolicy.getInstance().isCleartextTrafficPermitted)
val baseURI = URI.create("/")
finder = resourceFinderFactory.create(baseURI, credentials)

View File

@@ -4,6 +4,7 @@
package at.bitfire.davdroid.servicedetection
import android.security.NetworkSecurityPolicy
import at.bitfire.davdroid.db.AppDatabase
import at.bitfire.davdroid.db.Collection
import at.bitfire.davdroid.db.HomeSet
@@ -27,6 +28,7 @@ import okhttp3.mockwebserver.MockWebServer
import okhttp3.mockwebserver.RecordedRequest
import org.junit.After
import org.junit.Assert.assertEquals
import org.junit.Assume
import org.junit.Before
import org.junit.Rule
import org.junit.Test
@@ -74,6 +76,7 @@ class HomeSetRefresherTest {
// build HTTP client
client = httpClientBuilder.build()
Assume.assumeTrue(NetworkSecurityPolicy.getInstance().isCleartextTrafficPermitted)
// insert test service
val serviceId = db.serviceDao().insertOrReplace(

View File

@@ -4,6 +4,7 @@
package at.bitfire.davdroid.servicedetection
import android.security.NetworkSecurityPolicy
import at.bitfire.davdroid.db.AppDatabase
import at.bitfire.davdroid.db.Collection
import at.bitfire.davdroid.db.Principal
@@ -22,6 +23,7 @@ import okhttp3.mockwebserver.MockResponse
import okhttp3.mockwebserver.MockWebServer
import okhttp3.mockwebserver.RecordedRequest
import org.junit.After
import org.junit.Assume
import org.junit.Before
import org.junit.Rule
import org.junit.Test
@@ -69,6 +71,7 @@ class PrincipalsRefresherTest {
// build HTTP client
client = httpClientBuilder.build()
Assume.assumeTrue(NetworkSecurityPolicy.getInstance().isCleartextTrafficPermitted)
// insert test service
val serviceId = db.serviceDao().insertOrReplace(

View File

@@ -4,6 +4,7 @@
package at.bitfire.davdroid.servicedetection
import android.security.NetworkSecurityPolicy
import at.bitfire.davdroid.db.AppDatabase
import at.bitfire.davdroid.db.Service
import at.bitfire.davdroid.network.HttpClientBuilder
@@ -16,6 +17,7 @@ import okhttp3.mockwebserver.MockWebServer
import okhttp3.mockwebserver.RecordedRequest
import org.junit.After
import org.junit.Assert.assertEquals
import org.junit.Assume
import org.junit.Before
import org.junit.Rule
import org.junit.Test
@@ -56,6 +58,7 @@ class ServiceRefresherTest {
// build HTTP client
client = httpClientBuilder.build()
Assume.assumeTrue(NetworkSecurityPolicy.getInstance().isCleartextTrafficPermitted)
// insert test service
val serviceId = db.serviceDao().insertOrReplace(

View File

@@ -22,10 +22,9 @@ import kotlinx.coroutines.withTimeout
import org.junit.After
import org.junit.AfterClass
import org.junit.Assert.assertFalse
import org.junit.Assume
import org.junit.Assert.assertTrue
import org.junit.Before
import org.junit.BeforeClass
import org.junit.Ignore
import org.junit.Rule
import org.junit.Test
import java.util.logging.Logger
@@ -73,7 +72,6 @@ class AccountSettingsMigration21Test {
}
@Ignore("Flaky in CI")
@SdkSuppress(minSdkVersion = 34)
@Test
fun testCancelsSyncAndClearsPendingState() = runBlocking {
@@ -85,8 +83,8 @@ class AccountSettingsMigration21Test {
inPendingState.first { it }
}
// Assume that we are now in the forever pending state (Skips test otherwise)
Assume.assumeTrue(ContentResolver.isSyncPending(account, authority))
// Assert again that we are now in the forever pending state
assertTrue(ContentResolver.isSyncPending(account, authority))
// Run the migration which should cancel the forever pending sync for all accounts
migration.migrate(account)

View File

@@ -5,6 +5,7 @@
package at.bitfire.davdroid.sync
import android.accounts.Account
import at.bitfire.dav4jvm.HttpUtils.toKtorUrl
import at.bitfire.davdroid.settings.AccountSettings
import at.bitfire.davdroid.settings.Credentials
import at.bitfire.davdroid.sync.account.TestAccount
@@ -19,6 +20,7 @@ import org.junit.After
import org.junit.Assert.assertArrayEquals
import org.junit.Assert.assertEquals
import org.junit.Assert.assertNull
import org.junit.Assume
import org.junit.Before
import org.junit.Rule
import org.junit.Test
@@ -26,7 +28,7 @@ import java.net.InetAddress
import javax.inject.Inject
@HiltAndroidTest
class ResourceRetrieverTest {
class ResourceDownloaderTest {
@get:Rule
val hiltRule = HiltAndroidRule(this)
@@ -35,7 +37,7 @@ class ResourceRetrieverTest {
lateinit var accountSettingsFactory: AccountSettings.Factory
@Inject
lateinit var resourceRetrieverFactory: ResourceRetriever.Factory
lateinit var resourceDownloaderFactory: ResourceDownloader.Factory
lateinit var account: Account
lateinit var server: MockWebServer
@@ -62,35 +64,21 @@ class ResourceRetrieverTest {
@Test
fun testRetrieve_DataUri() = runTest {
val downloader = resourceRetrieverFactory.create(account, "example.com")
val result = downloader.retrieve("data:image/png;base64,dGVzdA==")
assertArrayEquals("test".toByteArray(), result)
}
@Test
fun testRetrieve_DataUri_Invalid() = runTest {
val downloader = resourceRetrieverFactory.create(account, "example.com")
val result = downloader.retrieve("data:;INVALID,INVALID")
assertNull(result)
}
@Test
fun testRetrieve_ExternalDomain() = runTest {
fun testDownload_ExternalDomain() = runTest {
val baseUrl = server.url("/")
val localhostIp = InetAddress.getByName(baseUrl.host).hostAddress!!
// URL should be http://localhost, replace with http://127.0.0.1 to have other domain
Assume.assumeTrue(baseUrl.host == "localhost")
val baseUrlIp = baseUrl.newBuilder()
.host(localhostIp)
.host(InetAddress.getByName(baseUrl.host).hostAddress!!)
.build()
server.enqueue(MockResponse()
.setResponseCode(200)
.setBody("TEST"))
val downloader = resourceRetrieverFactory.create(account, baseUrl.host)
val result = downloader.retrieve(baseUrlIp.toString())
val downloader = resourceDownloaderFactory.create(account, baseUrl.host)
val result = downloader.download(baseUrlIp.toKtorUrl())
// authentication was NOT sent because request is not for original domain
val sentAuth = server.takeRequest().getHeader(HttpHeaders.Authorization)
@@ -101,28 +89,14 @@ class ResourceRetrieverTest {
}
@Test
fun testRetrieve_FtpUrl() = runTest {
val downloader = resourceRetrieverFactory.create(account, "example.com")
val result = downloader.retrieve("ftp://example.com/photo.jpg")
assertNull(result)
}
@Test
fun testRetrieve_RelativeHttpsUrl() = runTest {
val downloader = resourceRetrieverFactory.create(account, "example.com")
val result = downloader.retrieve("https:photo.jpg")
assertNull(result)
}
@Test
fun testRetrieve_SameDomain() = runTest {
fun testDownload_SameDomain() = runTest {
server.enqueue(MockResponse()
.setResponseCode(200)
.setBody("TEST"))
val baseUrl = server.url("/")
val downloader = resourceRetrieverFactory.create(account, baseUrl.host)
val result = downloader.retrieve(baseUrl.toString())
val downloader = resourceDownloaderFactory.create(account, baseUrl.host)
val result = downloader.download(baseUrl.toKtorUrl())
// authentication was sent
val sentAuth = server.takeRequest().getHeader(HttpHeaders.Authorization)

View File

@@ -11,7 +11,7 @@ import at.bitfire.dav4jvm.okhttp.Response
import at.bitfire.dav4jvm.property.caldav.CalDAV
import at.bitfire.dav4jvm.property.caldav.GetCTag
import at.bitfire.davdroid.db.Collection
import at.bitfire.davdroid.di.scope.SyncDispatcher
import at.bitfire.davdroid.di.SyncDispatcher
import at.bitfire.davdroid.resource.LocalResource
import at.bitfire.davdroid.resource.SyncState
import at.bitfire.davdroid.util.DavUtils.lastSegment

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.2 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.1 KiB

View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Some files were not shown because too many files have changed in this diff Show More