Ejemplo n.º 1
0
        private void bw_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
        {
            var result = e.Result as object[];

            if (result != null)
            {
                var children = result[0] as TreeNode[];

                if (children != null && children.Length > 0)
                {
                    foreach (TreeNode child in children)
                    {
                        Node.Nodes.Add(child);
                    }
                }
            }

            if (WorkerFinished != null)
            {
                WorkerFinished.Invoke(Node);
            }
        }
Ejemplo n.º 2
0
 protected void OnWorkerFinished(WorkState state)
 {
     WorkerFinished?.Invoke(this, new WorkStateEventArgs(state));
 }
Ejemplo n.º 3
0
 protected void OnWorkerFinished()
 {
     WorkerFinished?.Invoke(this, new WorkStateEventArgs(CurrentWorkState));
 }