Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable predictive back gesture #3797

Merged
merged 1 commit into from
Nov 4, 2024

Conversation

frebib
Copy link
Contributor

@frebib frebib commented Nov 3, 2024

Content

Enable Android 15+ Predictive back gesture that was previously disabled
It only animates closing the app for now, but it's better than nothing.

Fixes #3795

Motivation and context

Google/Android want everything to support this eventually. It doesn't do anything special with Appyx animations yet, but at least it integrates with the OS and app-closing animations.
The mentioned bug, whilst still open, doesn't appear to happen any more, at least from my testing.

I have been running this patch for a couple of months and haven't really noticed any issues relating to it.
I will note that recently ~last month or so (?) I've been having issues with the keyboard not closing automatically when it should and I'm unsure whether it's caused by this patch, or some other upstream change/patch I'm carrying. Mentioning here mostly in case this gets merged and others report similar issues that coincide with the merge of this

Screenshots / GIFs

209d530b-cf50-41a3-9d01-5e34577784e2.mp4

Tests

  • Use the app and notice that it doesn't seem to have any regressions, but the animations are nice.

Tested devices

  • Physical
  • Emulator
  • OS version(s): Android 15, on Pixel

Checklist

  • Changes have been tested on an Android device or Android emulator with API 23
  • 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 define what will change for the user
  • Pull request includes screenshots or videos if containing UI changes
  • Pull request includes a sign off
  • You've made a self review of your PR

This only animates closing the app, but it's better than nothing.

Signed-off-by: Joe Groocock <me@frebib.net>
@frebib frebib requested a review from a team as a code owner November 3, 2024 20:37
@frebib frebib requested review from jmartinesp and removed request for a team November 3, 2024 20:37
Copy link
Contributor

github-actions bot commented Nov 3, 2024

Thank you for your contribution! Here are a few things to check in the PR to ensure it's reviewed as quickly as possible:

  • Your branch should be based on origin/develop, at least when it was created.
  • The title of the PR will be used for release notes, so it needs to describe the change visible to the user.
  • The test pass locally running ./gradlew test.
  • The code quality check suite pass locally running ./gradlew runQualityChecks.
  • If you modified anything related to the UI, including previews, you'll have to run the Record screenshots GH action in your forked repo: that will generate compatible new screenshots. However, given Github Actions limitations, it will prevent the CI from running temporarily, until you upload a new commit after that one. To do so, just pull the latest changes and push an empty commit.

Copy link

codecov bot commented Nov 3, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Please upload report for BASE (develop@21db1fd). Learn more about missing BASE report.
Report is 15 commits behind head on develop.

Additional details and impacted files
@@            Coverage Diff             @@
##             develop    #3797   +/-   ##
==========================================
  Coverage           ?   82.92%           
==========================================
  Files              ?     1771           
  Lines              ?    44481           
  Branches           ?     5222           
==========================================
  Hits               ?    36887           
  Misses             ?     5755           
  Partials           ?     1839           

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

@jmartinesp
Copy link
Member

I have been running this patch for a couple of months and haven't really noticed any issues relating to it.

I can't find any issues with it either, although the mentioned bug wasn't fixed by Google or at least it wasn't marked as fixed 🤔 .

@bmarty , @ganfra can I ping you for more thorough testing / opinions on this?

@bmarty
Copy link
Member

bmarty commented Nov 4, 2024

If back press when a bottom sheet is displayed behave correctly, I guess we can take the risk to merge this PR.

Copy link
Member

@jmartinesp jmartinesp left a comment

Choose a reason for hiding this comment

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

Approving this as I couldn't find any issues. Thanks!

@jmartinesp jmartinesp merged commit 17ea2aa into element-hq:develop Nov 4, 2024
23 checks passed
@jmartinesp jmartinesp deleted the frebib/predictive-back branch November 4, 2024 12:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enable Predictive back gesture on android
3 participants