Last active
October 17, 2016 20:08
-
-
Save antila/a71460731e38b9a526a1753186227dde to your computer and use it in GitHub Desktop.
Makes roll20 video boxes take up all avaliable screen size.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$('#hax').off('.hax').remove(); | |
var $videoSettings = $('<input id="hax" type="range" min="200" max="1000"/>'); | |
$videoSettings.appendTo($('#mysettings .content')); | |
var inputChange = function() { | |
var windowSize = $(this).val(); | |
$('.video').css('min-width', windowSize); | |
$('.video').css('min-height', windowSize * (3/4)); | |
$('#playerzone.largevideo object, #playerzone.largevideo .OT_root, .OT_widget-container').attr('style', 'width: ' + windowSize + 'px !important; height: ' + windowSize * (3/4) + 'px !important;'); | |
$('.playername').css('max-width', '100%'); | |
}; | |
$videoSettings.off('.hax').on('change.hax', inputChange); | |
$videoSettings.off('.hax').on('input.hax', inputChange); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment