Skip to content

PR 3/3: Experimental Native Element Call behind lab flag - #7747

Open
BillCarsonFr wants to merge 5 commits into
feature/valere/native_call_stackfrom
feature/valere/native_call_ui
Open

BillCarsonFr wants to merge 5 commits into
feature/valere/native_call_stackfrom
feature/valere/native_call_ui

Conversation

@BillCarsonFr

@BillCarsonFr BillCarsonFr commented Sep 21, 2026

Copy link
Copy Markdown
Member

Content

image

Motivation and context

Screenshots / GIFs

Tests

  • Step 1
  • Step 2
  • Step ...

Tested devices

  • Physical
  • Emulator
  • OS version(s):

Checklist

  • I am aware of the etiquette.
  • This PR was made with the help of AI:
    • Yes. In this case, please request a review by Copilot.
    • No.
  • Changes have been tested on an Android device or Android emulator with API 24
  • UI change has been tested on both light and dark themes
  • Accessibility has been taken into account. See https://github.com/element-hq/element-x-android/blob/develop/CONTRIBUTING.md#accessibility
  • Pull request is based on the develop branch
  • Pull request title will be used in the release note, it clearly defines what will change for the user
  • Pull request includes screenshots or videos if containing UI changes
  • You've made a self review of your PR

@BillCarsonFr
BillCarsonFr added this pull request to stack #7746 September 21, 2026 17:22
@BillCarsonFr BillCarsonFr added the PR-Wip For anything that isn't ready to ship and will be enabled at a later date label Sep 21, 2026
@github-actions

github-actions Bot commented Sep 21, 2026

Copy link
Copy Markdown
Contributor

📱 Scan the QR code below to install the build (arm64 only) for this PR.
QR code
If you can't scan the QR code you can install the build via this link: https://i.diawi.com/ZWcee2

@codecov

codecov Bot commented Sep 21, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 4.87805% with 39 lines in your changes missing coverage. Please review.
⚠️ Please upload report for BASE (feature/valere/native_call_stack@5b638a6). Learn more about missing BASE report.

Files with missing lines Patch % Lines
.../features/callnative/impl/DefaultNativeCallHost.kt 0.00% 20 Missing ⚠️
...roid/features/callnative/impl/ElementXCallStyle.kt 0.00% 7 Missing ⚠️
...features/callnative/impl/ElementCallControllers.kt 0.00% 6 Missing ⚠️
...d/features/callnative/impl/DefaultNativeCallPip.kt 0.00% 4 Missing ⚠️
...c/main/kotlin/io/element/android/x/MainActivity.kt 0.00% 2 Missing ⚠️
Additional details and impacted files
@@                         Coverage Diff                         @@
##             feature/valere/native_call_stack    #7747   +/-   ##
===================================================================
  Coverage                                    ?   80.95%           
===================================================================
  Files                                       ?     2801           
  Lines                                       ?    82836           
  Branches                                    ?    11405           
===================================================================
  Hits                                        ?    67061           
  Misses                                      ?    11389           
  Partials                                    ?     4386           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@BillCarsonFr
BillCarsonFr force-pushed the feature/valere/native_call_ui branch from 86d3389 to a949ce8 Compare September 22, 2026 12:01
@BillCarsonFr
BillCarsonFr force-pushed the feature/valere/native_call_ui branch from a949ce8 to 348b7f3 Compare September 22, 2026 21:19
@jmartinesp

Copy link
Copy Markdown
Member

2 issues I found so far with PiP:

  • When sending the call to background using the home button/gesture, the PiP window is at the bottom with the right aspect ratio, but when doing the same with the top left icon, it's always in landscape and at the top-right corner of the screen.
  • When a call is ended through the notification, the PiP triggered from the home action is still visible - only that one, the one from the top-left icon works as expected -, displaying the chat screen in a creative way 😅 :
image

@BillCarsonFr

Copy link
Copy Markdown
Member Author
  • When sending the call to background using the home button/gesture, the PiP window is at the bottom with the right aspect ratio, but when doing the same with the top left icon, it's always in landscape and at the top-right corner of the screen.

The in app PIP is different from the system app, it is a custom one. I wanted to experiment on that to see if we could do some interesting interactions.
It is still very much experimental.
I can try to make it more usefull, leave as is, or descope?

@jmartinesp

Copy link
Copy Markdown
Member

The in app PIP is different from the system app, it is a custom one. I wanted to experiment on that to see if we could do some interesting interactions. It is still very much experimental. I can try to make it more usefull, leave as is, or descope?

Oh, I didn't realise this one was in-app. I think the ideal solution would be to have both PiP windows behaving similarly (same position, use the other user's aspect ratio, etc.) but I'm not sure how feasible that is.

@BillCarsonFr

Copy link
Copy Markdown
Member Author

@jmartinesp I bumped the element-call version to a new release.
Fixes the issues you saw https://github.com/element-hq/element-call-android/releases/tag/v0.1.0-rc.3

For now the in app floating call respect the video source ratio, but not position.

@BillCarsonFr
BillCarsonFr marked this pull request as ready for review September 23, 2026 13:50
@BillCarsonFr
BillCarsonFr requested a review from a team as a code owner September 23, 2026 13:50
@BillCarsonFr
BillCarsonFr requested review from ganfra and removed request for a team September 23, 2026 13:50
BillCarsonFr and others added 5 commits September 24, 2026 14:58
A wrapper around the logged-in content rather than an overlay, because a minimized call takes a strip of height above it while a maximized one covers it.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
supportsPictureInPicture and smallestScreenSize have to be declared here, because a library cannot change a host Activity's manifest entry.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@BillCarsonFr
BillCarsonFr force-pushed the feature/valere/native_call_ui branch from f4ad8bc to a756917 Compare September 24, 2026 13:00
@sonarqubecloud

Copy link
Copy Markdown

@jmartinesp jmartinesp left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I think this is good enough for an initial integration behind a feature flag, and the code seems OK.

onDispose { }
}

ElementCallOverlay(

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Double checking, but what we're doing is, instead of opening a new activity for EC, we're using MainActivity and overlaying EC on top of everything, right?

I'm a bit concerned this could cause issues with other UI elements, like pop ups or snackbars that could be displayed in a window on top of the current activity, but I can't think of anything at the moment that could cause this scenario.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

PR-Wip For anything that isn't ready to ship and will be enabled at a later date

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants