define(["tabbedView","require","globalize","userSettings","emby-itemscontainer","emby-tabs","emby-button","emby-scroller"],function(TabbedView,require,globalize,userSettings){"use strict";function getDefaultTabIndex(folderId){switch(userSettings.get("landing-"+folderId)){case"folders":return 1;default:return 0}}function getTabs(){return[{name:globalize.translate("sharedcomponents#HeaderMusicVideos")},{name:globalize.translate("sharedcomponents#Folders")}]}function getRequirePromise(deps){return new Promise(function(resolve,reject){require(deps,resolve)})}function getTabController(index){if(null==index)throw new Error("index cannot be null");var depends=[];switch(index){case 0:depends.push("./videos");break;case 1:depends.push("foldersTab")}var instance=this;return getRequirePromise(depends).then(function(controllerFactory){var controller=instance.tabControllers[index];if(!controller){controller=new controllerFactory(instance.view.querySelector(".tabContent[data-index='"+index+"']"),instance.params),instance.tabControllers[index]=controller}return controller})}function HomeVideosView(view,params){TabbedView.call(this,view,params)}return Object.assign(HomeVideosView.prototype,TabbedView.prototype),HomeVideosView.prototype.getTabs=getTabs,HomeVideosView.prototype.getDefaultTabIndex=getDefaultTabIndex,HomeVideosView.prototype.getTabController=getTabController,HomeVideosView});