private void ZAddMailbox(iMailboxContainer pContainer, cMailbox pMailbox) { foreach (TreeNode lNode in tvw.Nodes) { ZAddMailbox(lNode, pContainer, pMailbox); } }
public cNodeTag(cMailbox pMailbox, TreeNode pPleaseWait) { Namespace = null; Mailbox = pMailbox ?? throw new ArgumentNullException(nameof(pMailbox)); MailboxContainer = pMailbox; CanSelect = pMailbox.CanSelect; PleaseWait = pPleaseWait; }
public cNodeTag(cNamespace pNamespace, TreeNode pPleaseWait) { Namespace = pNamespace ?? throw new ArgumentNullException(nameof(pNamespace)); Mailbox = null; MailboxContainer = pNamespace; CanSelect = false; PleaseWait = pPleaseWait; }
public cNodeTag(cMailbox pMailbox, TreeNode pPleaseWait) { Namespace = null; Mailbox = pMailbox ?? throw new ArgumentNullException(nameof(pMailbox)); MailboxContainer = pMailbox; CanSelect = pMailbox.CanSelect; PleaseWait = pPleaseWait; if (pPleaseWait == null) { State = eState.expanded; } else { State = eState.neverexpanded; } }
public cNodeTag(cNamespace pNamespace, TreeNode pPleaseWait) { Namespace = pNamespace ?? throw new ArgumentNullException(nameof(pNamespace)); Mailbox = null; MailboxContainer = pNamespace; CanSelect = false; PleaseWait = pPleaseWait; if (pPleaseWait == null) { State = eState.expanded; } else { State = eState.neverexpanded; } }
private void ZAddMailbox(TreeNode pNode, iMailboxContainer pContainer, cMailbox pMailbox) { var lTag = pNode.Tag as cNodeTag; if (lTag != null && lTag.State == cNodeTag.eState.expanded) { if (lTag.MailboxContainer.Equals(pContainer)) { ZAddMailbox(pNode, pMailbox, true); } foreach (TreeNode lNode in pNode.Nodes) { ZAddMailbox(lNode, pContainer, pMailbox); } } }
private void tvw_AfterSelect(object sender, TreeViewEventArgs e) { if (!(e.Node.Tag is cNodeTag lTag)) { cmdOK.Enabled = false; return; } if (mContainer) { cmdOK.Enabled = true; MailboxContainer = lTag.MailboxContainer; } else { if (lTag.Namespace != null) { cmdOK.Enabled = false; return; } bool lCanSelect; try { lCanSelect = lTag.Mailbox.CanSelect; } catch { lCanSelect = false; } cmdOK.Enabled = lCanSelect; if (lCanSelect) { Mailbox = lTag.Mailbox; } else { Mailbox = null; } } }
/// <inheritdoc cref="cAPIDocumentationTemplate.Equals(object)"/> public bool Equals(iMailboxContainer pObject) => this == pObject as cNamespace;