cms.registerWidgetHandler("video",new function(){InlineWidget.apply(this,arguments);this.getName=function(){return"video"};this.getIcon=function(){return"fa-youtube-play"};this.getToolbarButtons=function(){var a=this;return{options:{icon:"fa-youtube-play",click:function(c,b){a.openOptionsForm(c,b)}}}};this.getOptionsFormSettings=function(){var a=this;return{onValidate:function(b,c){a.runBackend("validate",b,function(d){c(d)})}}};this.onCreateWidget=function(a,b){this.openOptionsForm(b,a.id);return a};this.applyOptions=function(c,a,b){cms.showLoadingIndicator();var d=this.dom(c);this.runBackend("getVideoCode",a,function(e){d.empty().append(e.html);cms.hideLoadingIndicator()})}});