Skip to content

DROID-2966 Chats | Enhancement | Introduce MediaActivity + add in-app media player allowing screen rotation (MVP version) #2515

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

Merged
merged 11 commits into from
Jun 9, 2025

Conversation

uburoiubu
Copy link
Member


  • I understand that contributing to this repository will require me to agree with the CLA

Description

What type of PR is this? (check all applicable)

  • 🍕 Feature
  • 🐛 Bug Fix
  • 📝 Documentation Update
  • 🎨 Style
  • 🧑‍💻 Code Refactor
  • 🔥 Performance Improvements
  • ✅ Test
  • 🤖 Build
  • 🔁 CI

Related Tickets & Documents

Mobile & Desktop Screenshots/Recordings

Added tests?

  • 👍 yes
  • 🙅 no, because they aren't needed
  • 🙋 no, because I need help

Added to documentation?

  • 📜 README.md
  • 📓 tech-docs
  • 🙅 no documentation needed

[optional] Are there any post-deployment tasks we need to perform?

@uburoiubu uburoiubu changed the title Droid 2966 in app media player for chat DROID-2966 Chats | Enhancement | Introduce MediaActivity + add in-app media player allowing screen rotation Jun 9, 2025
@uburoiubu uburoiubu marked this pull request as ready for review June 9, 2025 17:49
@uburoiubu uburoiubu requested a review from konstantiniiv as a code owner June 9, 2025 17:49
@uburoiubu uburoiubu requested a review from Copilot June 9, 2025 17:49
@uburoiubu uburoiubu self-assigned this Jun 9, 2025
Copilot

This comment was marked as outdated.

@uburoiubu uburoiubu changed the title DROID-2966 Chats | Enhancement | Introduce MediaActivity + add in-app media player allowing screen rotation DROID-2966 Chats | Enhancement | Introduce MediaActivity + add in-app media player allowing screen rotation (MVP version) Jun 9, 2025
@uburoiubu uburoiubu requested a review from Copilot June 9, 2025 19:16
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR introduces the MediaActivity along with an in-app media player for videos and images while supporting screen rotation, enhancing the chats feature with media playback capabilities. Key changes include:

  • Adding new dependency versions in the gradle libs configuration
  • Propagating the new onRequestVideoPlayer callback through chat UI components
  • Introducing MediaScreen, MediaActivity, and associated UI components for media playback

Reviewed Changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated no comments.

Show a summary per file
File Description
gradle/libs.versions.toml Added media3 dependency versions
feature-chats/ui/ChatScreen.kt Added onRequestVideoPlayer parameter and forwarded calls
feature-chats/ui/ChatPreviews.kt Updated previews to pass the onRequestVideoPlayer callback
feature-chats/ui/ChatBubble.kt Added onRequestVideoPlayer parameter to Bubble composable and attachments
feature-chats/ui/Attachments.kt Refactored attachment handling and renamed a private helper function
app/src/main/java/com/anytypeio/anytype/ui/media/screens/MediaScreen.kt Added MediaScreen with ImageViewer and VideoPlayer composables
app/src/main/java/com/anytypeio/anytype/ui/media/MediaActivity.kt Introduced MediaActivity to launch MediaScreen
app/src/main/java/com/anytypeio/anytype/ui/chats/ChatFragment.kt Updated chat fragment to handle video playback via MediaActivity
app/src/main/AndroidManifest.xml Registered MediaActivity with orientation and screenSize configuration
Comments suppressed due to low confidence (1)

app/src/main/java/com/anytypeio/anytype/ui/media/screens/MediaScreen.kt:347

  • The standalone drag support modifier is not applied to an existing UI element, which means drag gestures on the DotScrubberSlider may never be detected. Consider chaining this modifier to the BoxWithConstraints modifier (or another appropriate parent) to enable the intended drag interaction.
Modifier.pointerInput(Unit) {

@uburoiubu uburoiubu merged commit 5e6f20a into main Jun 9, 2025
3 checks passed
@uburoiubu uburoiubu deleted the droid-2966-in-app-media-player-for-chat branch June 9, 2025 20:25
@github-actions github-actions bot locked and limited conversation to collaborators Jun 9, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants