adapt_framework icon indicating copy to clipboard operation
adapt_framework copied to clipboard

Expose a starting volume on the Media component

Open brian-learningpool opened this issue 9 years ago • 10 comments

This would be a very useful feature, especially for linking YouTube videos which are beyond the user's control.

brian-learningpool avatar Feb 03 '17 09:02 brian-learningpool

I've got this working with a new setting called "Default Volume" which has a dropdown with volume percentages from 0% to 100% in 10% increments (as @brian-learningpool) suggested.

Would it be ok to throw in a "Show Volume Control" setting as well? Otherwise the only option for the user to change the volume is by using the up/down arrow keys. Of course this could also be controlled by pasting in an object into the "Player Options" setting but I suspect not all users would be able to do that

barryo-learningpool avatar Jun 08 '17 08:06 barryo-learningpool

This won't work on mobile where the devices where volume can only be 0 or 1.

oliverfoster avatar Jun 08 '17 08:06 oliverfoster

Thanks @oliverfoster. Does that mean we shouldn't try to show the volume control or try to set a specific volume level between 0 and 1? It looks like the volume control just doesn't show up on ios devices as the audio level is under the user's physical control.

barryo-learningpool avatar Jun 08 '17 09:06 barryo-learningpool

I'm not sure. If it's needed on desktop it would be nice to have... I guess? It just needs to be made clear that it won't work on ios. Android needs testing.

oliverfoster avatar Jun 08 '17 09:06 oliverfoster

I guess its fair enough to add something like "Not supported in iOS devices" with further explanation of what will happen in the help text

barryo-learningpool avatar Jun 08 '17 09:06 barryo-learningpool

Yup. That sounds sensible and perhaps a note in the readme for media?

oliverfoster avatar Jun 08 '17 09:06 oliverfoster

Ok I'll add that in. We tried https://www.w3schools.com/html/html5_video.asp on an Android device and the volume control shows up but it just allows the user to mute/unmute the audio.

barryo-learningpool avatar Jun 08 '17 09:06 barryo-learningpool

Cool. I think it's probably safe to say that volume isn't available on mobile and don't show the volume controls on mobile at all? Make it really simple and drop some complexity?

oliverfoster avatar Jun 08 '17 09:06 oliverfoster

Here is the PR: https://github.com/adaptlearning/adapt-contrib-media/pull/167

barryo-learningpool avatar Jun 08 '17 11:06 barryo-learningpool

done in https://github.com/adaptlearning/adapt-contrib-media/commit/80db0f08193d465ae8ad91d8b24996529fd37540

moloko avatar Jul 04 '17 09:07 moloko