Smrf.NodeXL.Visualization.Wpf.NodeXLControl.Layout_LayOutGraphCompleted C# (CSharp) Method

Layout_LayOutGraphCompleted() protected method

protected Layout_LayOutGraphCompleted ( Object oSender, AsyncCompletedEventArgs oAsyncCompletedEventArgs ) : void
oSender Object
oAsyncCompletedEventArgs System.ComponentModel.AsyncCompletedEventArgs
return void
    Layout_LayOutGraphCompleted
    (
        Object oSender,
        AsyncCompletedEventArgs oAsyncCompletedEventArgs
    )
    {
        AssertValid();

        #if TRACE_LAYOUT_AND_DRAW
        Debug.WriteLine("NodeXLControl: Layout_LayOutGraphCompleted()");
        #endif

        if (oAsyncCompletedEventArgs.Error == null)
        {
            m_eLayoutState = LayoutState.LayoutCompleted;

            // The asynchronous layout has completed and now the graph needs to
            // be drawn.

            UpdateCollapsedGroupLocations(m_oGraph.Vertices);
            BundleAllEdgesIfAppropriate();

            LayOutOrDrawGraph();
        }
        else
        {
            m_eLayoutState = LayoutState.Stable;
        }

        FireGraphLaidOut(oAsyncCompletedEventArgs);
    }
NodeXLControl