public EditSimpleListPage( string pageID, string subjectName, Icon displayIcon, string ownerType, string subjectListRelationship, string memberType, GetSubjectDescriptionDelegate getSubjectDescription, GetListMembersDelegate getListMembers, DoAddMemberDelegate addMember, DoDelMemberDelegate delMember, EditDialog editDialog) { this.pageID = pageID; InitializeComponent(); lbSubject.Text = String.Format(lbSubject.Text, subjectName); lbSubjectListRelationship.Text = String.Format(lbSubjectListRelationship.Text, subjectListRelationship); pbSubjectImage.Image = displayIcon.ToBitmap(); this.getSubjectDescription = getSubjectDescription; this.getListMembers = getListMembers; this.addMember = addMember; this.delMember = delMember; this.listOwnerType = ownerType; this.listMemberType = memberType; this.editDialog = editDialog; this.tbDescription.Select(); }
protected override bool Apply(EditDialog.EditDialogAction actionCause) { base.Apply(actionCause); foreach (IDirectoryPropertiesPage ppage in this.GetPages()) { if (ppage != null && ppage is ServiceRecoveryPage) { GeneralPropertyPage generalPage = ppage as GeneralPropertyPage; if (generalPage != null) { if (!generalPage.OnApply()) return false; } ServiceRecoveryPage recoveryPage = ppage as ServiceRecoveryPage; if (recoveryPage != null) { if (!recoveryPage.OnApply()) return false; } DependenciesPage dependencyPage = ppage as DependenciesPage; if (dependencyPage != null) { if (!dependencyPage.OnApply()) return false; } } } commit = true; return true; }