Commit Graph

60 Commits

Author SHA1 Message Date
Benoit Marty 77564d7870 Fix PiP crash with IllegalStateException. Activity must be resumed to enter PiP mode.
https://sentry.tools.element.io/organizations/element/issues/1449388/events/2eb06349f6224481960a64916d51ae60/?project=59
2024-09-24 15:46:19 +02:00
Jorge Martin Espinosa 663362ac7f Add forced logout flow when the proxy is no longer available (#3458)
* Add `MatrixClient.isSlidingSyncProxySupported` function

* Update localazy strings

* Modify `ErrorDialog` to have an `onSubmit` call, which will be used for the submit action.

Also make the title text optional and dismissing the dialog by tapping outside/going back configurable.

* Check if a forced migration to SSS is needed because the proxy is no longer available.

In that case, display the non-dismissable dialog and force the user to log out after enabling SSS.

* Enable native/simplified sliding sync by default.

* Refactor the login to make sure we:

1. Always try native/simplified sliding sync login first, if available.
2. Then, if it wasn't available or failed with an sliding sync not supported error, try with the proxy instead (either discovered proxy or forced custom one).

* Move logic to `LoggedInPresenter` and the UI to `LoggedInView`

* Update screenshots

---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2024-09-16 09:13:02 +00:00
Benoit Marty 6251cb9269 Merge pull request #3422 from element-hq/feature/bma/agpl
Change license to AGPL
2024-09-06 20:40:28 +02:00
Benoit Marty 375ac25d8d Migrate license to AGPL - XML files. 2024-09-06 17:43:35 +02:00
Benoit Marty f61df38e55 Migrate license to AGPL.
Run script `uv run license-editor --repository ../element-x-android`
2024-09-06 17:19:19 +02:00
Benoit Marty 467c63fd15 Ensure Call is not hang up when user is asked to grant system permissions. 2024-09-06 16:17:21 +02:00
Jorge Martin Espinosa 9f2db3e52d Fix Element Call closing automatically on API 34 (#3402)
* Fix Element Call closing automatically on API 34

It seems like registering a user leave hint listener way too early was causing the activity to try to enter PiP erroneously and that led to the activity closing instead.
2024-09-05 14:28:05 +00:00
bmarty 5ad2764402 Sync Strings from Localazy 2024-09-02 00:15:17 +00:00
Benoit Marty ad646c9098 Remove feature flag PictureInPicture 2024-08-27 18:41:40 +02:00
Benoit Marty 7f4b84638f Rename PipActivity to PipView 2024-08-26 17:15:32 +02:00
Benoit Marty 9fab13c50b Avoid keeping a reference to the eventSink in a separate value 2024-08-26 17:11:41 +02:00
Benoit Marty 306043876f Rename WebPipApi to PipController 2024-08-26 16:50:55 +02:00
Benoit Marty 0b2edcb6d1 Fix UI tests. 2024-08-23 16:40:48 +02:00
Benoit Marty a4b6d4c5d7 Simplify code. 2024-08-23 16:34:44 +02:00
Benoit Marty 368db3feb4 Allow entering Pip mode when controls.canEnterPip() cannot be evaluated. 2024-08-23 16:28:13 +02:00
Benoit Marty 18dcdc0e64 Communicate with Element Call about PiP status.
Also only use eventSink to communicate with the Presenter, instead of having public methods.
Change WeakReference to an Activity to a listener and update tests.
2024-08-23 16:19:21 +02:00
bmarty 3e67448006 Sync Strings from Localazy 2024-08-19 00:25:36 +00:00
ElementBot 8bd48fdc60 Sync Strings (#3297)
Co-authored-by: bmarty <3940906+bmarty@users.noreply.github.com>
2024-08-12 06:03:23 +00:00
ganfra d8532c0d19 Sync on push : fix CallScreenPresenterTests after last changes. 2024-08-01 11:21:05 +02:00
bmarty 76804d9e48 Sync Strings from Localazy 2024-07-29 00:26:27 +00:00
ElementBot 1f01bd73c4 Sync Strings (#3232)
Co-authored-by: bmarty <3940906+bmarty@users.noreply.github.com>
2024-07-22 08:59:47 +00:00
Benoit Marty 5bda29ca7e Rework FakeMatrixRoom so that it contains only lambdas. (#3229)
* Upgrade lint to 8.7.0-alpha01

* FakeMatrixRoom: lambda everywhere

Fix test compilation issues
2024-07-22 10:39:48 +02:00
Jorge Martin Espinosa 344e07bc0b Cancel ringing call notification on call cancellation (#3047)
* Cancel ringing call notification on call cancellation

* Improve implementation, add some comments to clarify how it works.

* Make sure the call timeout job is cancelled
2024-07-19 17:51:44 +02:00
Benoit Marty a0b8679776 Add preview for Call screen in different PipState. 2024-07-15 17:23:03 +02:00
Benoit Marty 15d4782aa6 When PiP is supported, use Back for top left icon instead of Close. #3197 2024-07-15 17:23:03 +02:00
Benoit Marty 497f5d9f38 Call in PiP: when closing PiP, hang up the call.
The Activity is actually not destroyed as I expected.
2024-07-15 17:22:34 +02:00
Benoit Marty d27e86f396 Call in PiP: add feature flag, disabled in release builds. 2024-07-15 16:48:39 +02:00
Benoit Marty bb5ae89b2f Introduce ElementThemeApp to avoid code duplication. 2024-07-09 11:10:10 +02:00
Benoit Marty da78222090 Merge branch 'develop' into feature/bma/realDarkTheme 2024-07-09 10:19:26 +02:00
Benoit Marty 214c9d2d2b Fix KtLint issue 2024-07-08 18:48:51 +02:00
Benoit Marty c73d814220 CallScreenPresenter is reading the current theme, it needs to be in the ElementTheme block. Closes #3153 2024-07-08 18:35:03 +02:00
Benoit Marty 9856ece42a Ensure PinUnlockActivity and IncomingCallActivity use the internal theme set by the user. 2024-07-08 18:17:44 +02:00
Benoit Marty 962320a0d8 Remove test on API 24 (working locally but not on CI :/) 2024-07-08 14:38:54 +02:00
Benoit Marty 0093e611cd Add Ui test on CallScreenView 2024-07-08 12:30:06 +02:00
Benoit Marty 664f78741d Add preview for loading state. 2024-07-08 12:08:42 +02:00
Benoit Marty a005c80fe4 Add support for Picture in Picture for ElementCallActivity 2024-07-08 12:04:59 +02:00
Benoit Marty 1a99a9f0e6 Format file. No other change. 2024-07-05 16:24:57 +02:00
jmartinesp dabaa2d265 Sync Strings from Localazy 2024-07-03 11:21:27 +00:00
Jorge Martin Espinosa 05df1f2065 Fix crash when getting the system ringtone for ringing calls (#3131) 2024-07-02 16:12:29 +00:00
Benoit Marty 3135c5307f Fix tests 2024-07-02 13:50:10 +02:00
Benoit Marty 8ec283f2ca Use SDK to get Element Wellknown content. 2024-07-02 13:28:26 +02:00
Benoit Marty 4df18eadf4 Remove unused import 2024-07-01 16:18:20 +02:00
Benoit Marty f34ba47906 Inject constructor 2024-07-01 16:12:27 +02:00
Benoit Marty 8ef970e3f7 Provide language and theme to Element Call. #3079 2024-07-01 15:51:41 +02:00
Benoit Marty 6a6e66765a Remove default value for languageTag and theme. 2024-07-01 14:32:27 +02:00
Benoit Marty 2529a8d844 Add parameter names. 2024-07-01 14:30:35 +02:00
bmarty 32c5da898b Sync Strings from Localazy 2024-07-01 00:22:10 +00:00
Jorge Martin Espinosa ce28a05467 Replace the 'answer' PendingIntent in ringing call notifications (#3093)
* Replace the 'answer' PendingIntent in ringing call notifications

Co-authored-by: Benoit Marty <benoit@matrix.org>

---------

Co-authored-by: Benoit Marty <benoit@matrix.org>
2024-06-25 10:36:29 +02:00
ElementBot fd6bcb7857 Sync Strings (#3077)
Co-authored-by: bmarty <3940906+bmarty@users.noreply.github.com>
2024-06-24 09:29:35 +02:00
Jorge Martin Espinosa 2e32adf1f1 Improve how active calls work (#3029)
* Improve how active calls work:

- Sending the `m.call.notify` event is now done in `CallScreenPresenter` once we know the sync is running.
- You can mark a call of both external url or room type as joined.
- Hanging up checks the current active call type and will only remove it if it matches.
2024-06-18 12:07:08 +02:00