Is it possible to trigger a chrome throw using the HTML button?
I wrote a web page that uses a custom receiver, and basically allows the user to show reports to the people’s room in the form of statistics / charts, but they see the controls on their screen.
However, since it is a COMPLETELY broadcast application, I want to show a button on a web page that shows when the user is not casting and then disappears when they are not cast.
So something like:
<button id="castStart" style="display:none;">Start</button> <button id="castStop" style="display:none;">Stop</button>
And then some JS like:
if( CASTAVAILBLE ) { if( CASTING ) { $('#castStart').hide(); $('#castStop').show(); } else { $('#castStart').show(); $('#castStop').hide(); } $('#castStart').on('click', function(e){ startCasting(); $('#castStart').hide(); $('#castStop').show(); }); $('#castStop').on('click', function(e){ sttopCasting(); $('#castStart').show(); $('#castStop').hide(); }); }
So basically the plan is to hide and show the buttons based on when they are executed, and ONLY if they are ABLE for translation (i.e. extension of the extension).
Is it possible?
Update: it looks like I'm doing what I want: https://chrome.com/photowall , so this is possible!
javascript jquery chromecast
Cameron
source share