using System; using System.Collections.Generic; using DevExpress.XtraTab; namespace Lskj.Model { /// /// Provides the top-level module page lifecycle without coupling module /// code to a particular visual tab control. The WPF shell supplies an /// implementation backed by DXTabItem instances; the classic WinForms /// shell leaves this interface unset and ERPInfo falls back to its real /// XtraTabControl/PageControl. /// public interface IModulePageHost { event EventHandler PageAdded; event EventHandler PageRemoved; event EventHandler PageSelected; XtraTabPage SelectedPage { get; } IEnumerable Pages { get; } void AddPage(XtraTabPage page); bool RemovePage(XtraTabPage page); bool SelectPage(XtraTabPage page); bool ContainsPage(XtraTabPage page); } public sealed class ModulePageEventArgs : EventArgs { public ModulePageEventArgs(XtraTabPage page) { Page = page; } public XtraTabPage Page { get; private set; } } }