-
Notifications
You must be signed in to change notification settings - Fork 9.8k
[webview_flutter] Consistent allowsInlineMediaPlayback on iOS #2309
Conversation
I went ahead and created a (very simple) patch to address this very annoying issue. I did not see it at first but now I see there is a (better and more robust?) PR already submitted to do the job: #2227 I would be happy to abandon my PR in favor of @sarbagyastha's version if his has a chance of getting merged. |
hi @alexmarkley - cool & thank you for the PR. |
@ened Currently this flag's behavior is different across different Apple devices, which means that the current end user experience is inconsistent between iOS and iPad. The current behavior on iPhone is to ignore the As such I would be absolutely shocked if it introduced any unexpected or unwanted changes to any users of this plugin. However, as I mentioned earlier, if we want a more robust implementation of this functionality which exposes the platform-specific flags to the Flutter code, perhaps we should encourage @sarbagyastha and get his PR accepted: #2227 On another note, with regards to a test, I don't know how that would work. How can we implement a test for this behavior? Either way I will go ahead and rebase with a new changelog and version bump. |
eec2244
to
dde72a9
Compare
@ened I went ahead and cleaned up the pull request to track the latest upstream changes. Also, to clarify, I am having trouble seeing the value of exposing this flag at the Flutter/Widget level, since you would then have to turn it on twice -- once in your HTML5 That said, I am not dogmatic about it, I'm happy to see the problem solved no matter how it gets solved. 😄 |
A Flutter level setting would be useful because most of the videos on the web are streamed from video sharing platforms (Youtube, Vimeo, etc) with Those videos are embedded with an Thanks for making the PR! |
Any update on this PR? |
@searchy2 Vimeo does allow this setting to be modified via their embed api (see the Either way, if we want a more robust (read: complex) solution, please see #2227 Until @sarbagyastha's solution gets merged, I'll just keep updating this PR to track master. |
dde72a9
to
d34c05f
Compare
Been waiting for this feature for a while, currently this feature is supported in |
d34c05f
to
cd30231
Compare
I just rebased my patch against origin again. Solving this problem is a requirement for my use case, and I'm currently using this patch (until some solution gets upstreamed). If anybody with merge rights would be willing to provide more concrete guidance on what steps would be necessary and appropriate for getting this merged, I would be happy to do a little more work to get it done. Thanks! |
Thank you @alexmarkley, i'm waiting too for an update on this solution |
263bec6
to
9609f67
Compare
I just rebased this patch against the origin again. I have no additional updates on this issue at this time. Related issues: |
A PR exists to propagate a configuration parameter from the GUI, but it is not merged yet flutter#2309
any updates on this? |
Any news? |
Are there any updates on this? |
184b233
to
836d9b9
Compare
I rebased my patch against master again. Still looking for guidance on how to proceed with this. TBH I disagree with @searchy2 and @ened. I do not believe this is a new feature, I am of the opinion that this is a bug for all affected users, and the risk of backwards-incompatible behavior is vanishingly small. |
836d9b9
to
3148af8
Compare
Rebased again. |
Those seem like some awfully easy conflicts to fix ^^ |
3148af8
to
cec2cf8
Compare
Rebased again. |
When will this fix release? |
Thanks for the contribution!
Since it appears that was landed as #3334, I'm going to close this as obsolete. If that's not the case, please let me know. |
Description
By default, iPhone does not allow "inline" video in WKWebView, even if the content explicitly calls for it using the "playsinline" attribute. Instead, iPhone overrides the web view and produces a full screen video controller.
In contrast, iPad and Android provide support for "inline" media by default.
See: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/video#attr-playsinline
See Also: https://developer.apple.com/documentation/webkit/wkwebviewconfiguration/1614793-allowsinlinemediaplayback
Related Issues
Checklist
Before you create this PR confirm that it meets all requirements listed below by checking the relevant checkboxes (
[x]
). This will ensure a smooth and quick review process.///
).flutter analyze
) does not report any problems on my PR.Notes:
Breaking Change
Does your PR require plugin users to manually update their apps to accommodate your change?