--autoplay-policy, no-user-gesture-required flags to allow video and audio to play without user input
This commit is contained in:
committed by
Joshua Granick
parent
734ed288ab
commit
5bbfd42f59
@@ -46,6 +46,10 @@ class ElectronSetup {
|
|||||||
if (height == 0) height = 600;
|
if (height == 0) height = 600;
|
||||||
var frame:Bool = window.borderless == false;
|
var frame:Bool = window.borderless == false;
|
||||||
|
|
||||||
|
var commandLine = Reflect.getProperty(electron.main.App, "commandLine");
|
||||||
|
var appendSwitch:haxe.Constraints.Function = Reflect.getProperty(commandLine, "appendSwitch");
|
||||||
|
appendSwitch('--autoplay-policy','no-user-gesture-required');
|
||||||
|
|
||||||
electron.main.App.on( 'ready', function(e) {
|
electron.main.App.on( 'ready', function(e) {
|
||||||
var config:Dynamic = {
|
var config:Dynamic = {
|
||||||
fullscreen: window.fullscreen,
|
fullscreen: window.fullscreen,
|
||||||
|
|||||||
Reference in New Issue
Block a user