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

Fix voice message duration view #948

Merged
merged 1 commit into from
Dec 18, 2022
Merged

Fix voice message duration view #948

merged 1 commit into from
Dec 18, 2022

Conversation

Creuqe
Copy link

@Creuqe Creuqe commented Aug 20, 2022

The seconds for a voice message duration, and also its decreasing duration when played, were just the total duration of the audio. So, a 3 minute audio would appear as 3:180 at the audio's right, and 2:170 for example when said audio is being played.

I added a modulo operator for 60 after the time millisecond to seconds conversion, just before setting it as viewable text, same for the progress function.

First time contributor checklist

Contributor checklist

  • I have tested my contribution on these devices:
  • Device A, Android X.Y.Z
  • Device B, Android Z.Y
  • Virtual device W, Android Y.Y.Z
  • My contribution is fully baked and ready to be merged as is
  • I ensure that all the open issues my contribution fixes are mentioned in the commit message of my first commit using the Fixes oxen-io/session-android-temp#162 syntax

Description

The seconds for a voice message duration, and also its decreasing duration when played, were just the total duration of the audio. So, a 3 minute audio would appear as 3:180 at the audio's right, and 2:170 for example when said audio is being played.

I added a modulo operator for 60 after the time millisecond to seconds conversion, just before setting it as viewable text, same for the progress function.
@Creuqe
Copy link
Author

Creuqe commented Aug 20, 2022

Please link issue oxen-io/session-android-temp#426 to this.

I did not test this as I currently do not have the setup to compile the repository, any other dev is welcome to check it.

@hjubb
Copy link

hjubb commented Sep 12, 2022

I'll give it a check to see if we can merge it in for a release next. Thanks for the contribution!

@hjubb hjubb changed the base branch from master to dev December 18, 2022 23:52
@hjubb hjubb merged commit 95298bb into oxen-io:dev Dec 18, 2022
@Creuqe Creuqe deleted the patch-1 branch January 26, 2023 19:56
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