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

VoIP Screen Sharing Permission #5811

Merged
merged 9 commits into from
Apr 21, 2022

Conversation

onurays
Copy link
Contributor

@onurays onurays commented Apr 21, 2022

Initial PR for screen sharing during a call.

  • Add screen sharing button into call screen
  • Show permission dialog
  • Start a foreground service with a sticky notification for Android Q and later
  • Toggle start/stop screen sharing button
Share Screen Button Permission Dialog Stop Sharing Screen
screen_sharing_1 screen_sharing_2 screen_sharing_3

@onurays onurays changed the title VoIP Screen Sharing Permissions VoIP Screen Sharing Permission Apr 21, 2022
@onurays onurays requested review from a team and mnaturel and removed request for a team April 21, 2022 09:31
@github-actions
Copy link

github-actions bot commented Apr 21, 2022

Unit Test Results

114 files  ±0  114 suites  ±0   1m 39s ⏱️ +25s
202 tests ±0  202 ✔️ ±0  0 💤 ±0  0 ±0 
678 runs  ±0  678 ✔️ ±0  0 💤 ±0  0 ±0 

Results for commit 56b3e8a. ± Comparison against base commit c21ec98.

♻️ This comment has been updated with latest results.

@onurays onurays requested review from a team and ericdecanini and removed request for mnaturel and a team April 21, 2022 10:01
Copy link
Contributor

@ericdecanini ericdecanini left a comment

Choose a reason for hiding this comment

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

LGTM! Left a couple of optional suggestions

@@ -30,6 +30,8 @@ sealed class VectorCallViewEvents : VectorViewEvents {
object ShowDialPad : VectorCallViewEvents()
object ShowCallTransferScreen : VectorCallViewEvents()
object FailToTransfer : VectorCallViewEvents()
object ShowScreenSharingPermissionDialog : VectorCallViewEvents()
object StopScreenSharingService : VectorCallViewEvents()
Copy link
Contributor

Choose a reason for hiding this comment

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

Optional: This is a good opportunity to get rid of the commented code below. They're nearly 2 years old, I don't think we'll need it

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Right :) done.

Comment on lines 34 to 37
// Show a sticky notification
val notificationId = System.currentTimeMillis().toInt()
val notification = notificationUtils.buildScreenSharingNotification()
startForeground(notificationId, notification)
Copy link
Contributor

Choose a reason for hiding this comment

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

Optional: extracting this code into a private fun showStickyNotification() could get rid of the need for a comment ;)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Nice idea, done.

Onuray Sahin added 2 commits April 21, 2022 15:09
* develop: (107 commits)
  Fixes long line and comment lint errors
  Fixes lint errors
  Adds changelog file
  Formats entire project
  Adds changelog file
  Makes MediaType internal
  Bump libphonenumber from 8.12.46 to 8.12.47
  updating release version in preparation for next cycle
  generating changelog
  Replaces writeAsync with awaitTransaction
  Replaces doWithRealm with writeAsync
  Translated using Weblate (Polish)
  Translated using Weblate (Slovak)
  Crash: open private room by link. Use RoomId instead of the alias.
  Translated using Weblate (Arabic)
  Makes MediaFileUtils function internal
  Removes runCatching from TemporaryFileCreator
  using unix end of line character instead of windows as *nix OSes are more common dev environments
  remove spaces feedback from left panel (#5686)
  Translated using Weblate (French)
  ...

# Conflicts:
#	vector/src/main/java/im/vector/app/features/call/VectorCallViewModel.kt
@onurays onurays merged commit 8eaa2f8 into develop Apr 21, 2022
@onurays onurays deleted the feature/ons/voip_screen_sharing_permission branch April 21, 2022 13:03
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.

2 participants