-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Remove unnecessary compat method calls. #8382
Remove unnecessary compat method calls. #8382
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the PR.
LGTM however someone with more Android experience might have a look at this before merging :)
Worked well while doing a quick test.
even though these methods might not be of use currently, I see no advantage in removing them. androidx is updateable, the core Android OS on most devices is not due to lacking manufacturer support. So sticking to an updatable API seems advantageous to me. |
I agree with @Redirion, I see no advantage |
I was under the impression that NewPipe Legacy is no longer being maintained (there's a pretty significant gap in the latest versions of NewPipe and NewPipe Legacy), so I removed those method calls (two of them call older methods on older API levels and don't make use of backport implementations).
|
Mmmh ok. This is a micro-optimization, since using wrapped functions is slower and uses less apk size than using non-wrapped ones, but it is really a minuscole difference. But it actually makes sense to use non-compat methods to reduce code complexity.
Actually, that does not hold well, since otherwise we should use androidx methods for every place possible, but that would be a nightmare. Let's remove them if possible. |
Kudos, SonarCloud Quality Gate passed! |
What is it?
Description of the changes in your PR
minSdk
being 19 (KitKat).Fixes the following issue(s)
APK testing
The APK can be found by going to the "Checks" tab below the title. On the left pane, click on "CI", scroll down to "artifacts" and click "app" to download the zip file which contains the debug APK of this PR.
Due diligence