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

PlayerHelper: Improvment readability, performance and manage errors #12001

Open
wants to merge 13 commits into
base: dev
Choose a base branch
from

Conversation

neosis91
Copy link
Contributor

@neosis91 neosis91 commented Feb 3, 2025

What is it?

  • Bugfix (user facing)
  • Feature (user facing)
  • Codebase improvement (dev facing)
  • Meta improvement to the project (dev facing)

Description of the changes in your PR

  • improvment readability
  • imrpovment performance
  • remove else with return
  • add try/ catch

Due diligence

- Enhanced the structure and organization of the globalScreenOrientationLocked method to make it more readable
- Removed unnecessary comments to streamline the code and improve overall clarity.
… methods: improvment readability and try catch errors
@github-actions github-actions bot added the size/medium PRs with less than 250 changed lines label Feb 3, 2025
@neosis91 neosis91 changed the title Improvment player helper DownloaderImpl: Improvment readability, performance and manage errors Feb 3, 2025
@neosis91 neosis91 changed the title DownloaderImpl: Improvment readability, performance and manage errors PlayerHelper: Improvment readability, performance and manage errors Feb 3, 2025
@neosis91 neosis91 marked this pull request as ready for review February 3, 2025 07:18
MEGABYTE become static variable
- use DateUtils.formatElapsedTime method
remove STRING_FORMATTER not used in helper
@ShareASmile ShareASmile added player Issues related to any player (main, popup and background) codequality Improvements to the codebase to improve the code quality labels Feb 6, 2025
@@ -154,9 +154,6 @@ public void onAudioSessionIdChanged(@NonNull final EventTime eventTime,
notifyAudioSessionUpdate(true, audioSessionId);
}
private void notifyAudioSessionUpdate(final boolean active, final int audioSessionId) {
if (!PlayerHelper.isUsingDSP()) {
Copy link
Member

Choose a reason for hiding this comment

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

Why is this check removed?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
codequality Improvements to the codebase to improve the code quality player Issues related to any player (main, popup and background) size/medium PRs with less than 250 changed lines
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants