如何在版本 66 或更高版本的 Google Chrome 自助服务终端应用中允许视频自动播放 [英] How to allow video autoplay in a Google Chrome kiosk app in version 66 or later

查看:59
本文介绍了如何在版本 66 或更高版本的 Google Chrome 自助服务终端应用中允许视频自动播放的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

从 Google Chrome 版本 66 开始,当播放音量未静音时,它将不再自动开始播放音频和视频文件.

As of version 66 of Google Chrome onwards it will no longer automatically start playback of audio and video files when the playback volume is not muted.

进行此更改是为了防止自动播放广告视频和其他烦人的网页元素.但是,这对自动播放功能的许多完全有效的应用程序(例如在标牌应用程序中)具有负面影响.

This change was made to prevent autoplay on ad videos and other annoying web page elements. However, this has negative consequences for a number of perfectly valid applications of the autoplay feature, for instance in signage applications.

可以在启动 Google Chrome 浏览器时使用命令行选项覆盖不自动播放带声音视频的新默认行为

The new default behaviour of not auto playing a video with sound can be overridden at the startup of the Google Chrome browser with the command line options

--autoplay-policy=no-user-gesture-required

--no-user-gesture-required

新的默认自动播放行为也出现在 ChromeOS 上的 Chrome 浏览器中(目前在测试版中).对于在 ChromeOS 上运行的 Kiosk 应用程序,没有命令行选项,只能使用 Manifest.json 文件进行配置.

The new default autoplay behaviour is also present in the Chrome browser on ChromeOS (currently in the beta channel). For Kiosk-apps running on ChromeOS there are no command line options, only configuration using the Manifest.json file.

目前 Manifest.json 格式的文档中没有允许更改自动播放策略的选项.

Currently there is no option in the documentation of the Manifest.json format that allows changing the autoplay policy.

有什么方法可以更改自助服务终端应用中新的 Chrome 默认自动播放政策,以允许在 Chrome 操作系统上的应用中自动播放视频?

Is there any way to change the new Chrome default autoplay policy in Kiosk apps to allow autoplay of videos in an app on ChromeOS?

推荐答案

事实证明,最终用户必须手动启用自动视频播放,通过:

It turns out that the end user will have to enable automatic video playback manually, by:

  1. 启动时按 Ctrl+Alt+S
  2. 登录
  3. 打开 Chrome 浏览器并输入:chrome://flags/#autoplay-policy
  4. 将自动播放政策"从默认"更改为不需要用户手势"
  5. 按重新启动"
  6. 重启设备

从现在开始,自动播放在您的应用中使用的 webview 组件中再次起作用.

From now on autoplay works again in webview components used in your app.

请参阅 Google 关于此主题的此评论线程.

See this comment thread about this topic by Google.

这篇关于如何在版本 66 或更高版本的 Google Chrome 自助服务终端应用中允许视频自动播放的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆