-
Notifications
You must be signed in to change notification settings - Fork 768
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
Add support for setRate on Android. Fix setRate on iOS when seeking. #196
Conversation
3711b4c
to
d8cbfed
Compare
ead0642
to
6a40177
Compare
6a40177
to
a0ffb0a
Compare
This reverts commit 6686cf0.
Why was this reverted? Does it break anything? |
Can this be merged please? |
@himanshuphirke Nobody reverted anything in this branch, the commits you are seeing were in a fork of this repo: https://github.com/asteasolutions/cordova-plugin-media @bricedupuy Did you review and test this code and can guarantee that it works as expected? |
} else { | ||
console.warn('media.setRate method is currently not supported for', cordova.platformId, 'platform.'); | ||
} | ||
exec(null, null, "Media", "setRate", [this.id, rate]); |
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.
This applies to all platforms now (incl. WP, still), however the actual support is only for iOS and Android, as far as I understand.
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.
It'd probably be nicer to have the bugfix for iOS and the feature for Android as separate PRs. Thanks!
It looks like on Android |
|
||
public void setRate(float speed) { | ||
// Check for API 23+ | ||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) { |
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.
If setRate
requires API 23, then we should add that as a quirk in the documentation stating that devices with a lower API level will be a no operation.
Platforms affected
What does this PR do?
What testing has been done on this change?
Physical device testing on:
Checklist