diff --git a/web/app/View/Monitors/index.ctp b/web/app/View/Monitors/index.ctp index c210c659e..e309444be 100755 --- a/web/app/View/Monitors/index.ctp +++ b/web/app/View/Monitors/index.ctp @@ -27,16 +27,4 @@ Js->get('#monitors'); $this->Js->sortable(array('complete' => '$.post("/monitors/reorder", $("#monitors").sortable("serialize"))',)); -?> - - \ No newline at end of file +?> \ No newline at end of file diff --git a/web/app/webroot/js/main.js b/web/app/webroot/js/main.js old mode 100644 new mode 100755 index d1bb97ccb..fddaee49d --- a/web/app/webroot/js/main.js +++ b/web/app/webroot/js/main.js @@ -193,6 +193,17 @@ $(document).ready(function() { } }); }); + + + $(".livestream_resize").each(function(index, element){ + if($(element).attr('src').indexOf('scale=') >= 0){ + var newScale = Math.ceil(($(element).width() / $(element).attr('width')) * 100); + var src = $(element).attr('src').replace('scale=100', 'scale='+newScale); + $(element).attr('src', src); + console.log("resized"); + } + }); + return false; // Monitors //