using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows; using Dragablz; using PDF_Office.Views; using Prism.Ioc; using Prism.Regions; namespace PDF_Office.CustomControl.SystemControl { public class InterTabClient : IInterTabClient { private IContainerProvider containerProvider; public InterTabClient(IContainerProvider container) { containerProvider = container; } public INewTabHost GetNewHost(IInterTabClient interTabClient, object partition, TabablzControl source) { var view = containerProvider.Resolve(); var regionManager = containerProvider.Resolve(); RegionManager.SetRegionManager(view, regionManager); RegionManager.UpdateRegions(); return new NewTabHost(view, view.TabablzControl); } public TabEmptiedResponse TabEmptiedHandler(TabablzControl tabControl, Window window) { return TabEmptiedResponse.CloseWindowOrLayoutBranch; } } }