Page 1 of 1

Is it possible to turn off sounds only in one browser?

Posted: Fri Mar 27, 2020 3:42 am
by coater
Is it possible to turn off sounds only in one browser ?
not by js(element.volume =0).

Re: Is it possible to turn off sounds only in one browser?

Posted: Fri Mar 27, 2020 10:38 am
by salvadordf
Use TChromium.AudioMuted := True

If I remember correctly, that property can only be read in some CEF threads but you can write it in any thread.
Use the code in the MiniBrowser to see how to implement it.

Re: Is it possible to turn off sounds only in one browser?

Posted: Sat Mar 28, 2020 12:42 am
by coater
Thank you very much! I got it.

Code: Select all

browser.Host.IsAudioMuted
 browser.Host.SetAudioMuted(false )