packages/Windows API Code Pack 1.1/source/Samples/DirectX/CS/Direct2D/D2DShapes/D2DShapesControl.cs
/// <summary>
/// Peels the shape from the end(top) of the list,
/// updates the render targets and puts the peeled shape to the stack of peelings.
/// </summary>
/// <returns></returns>
Peels the shape from the end(top) of the list,
updates the render targets and puts the peeled shape to the stack of peelings.
Peels the shape from the end ( top ) of the list updates the render targets and puts the peeled shape to the stack of peelings .
internal DrawingShape PeelShape()
        {
            lock (renderSyncObject)
            {
                if (drawingShapes.Count == 0)
                    return null;
                string statName = drawingShapes[drawingShapes.Count - 1].GetType().Name.Replace("Shape", " count");
                UpdateStats(statName, -1);
                peelings.Push(drawingShapes[drawingShapes.Count - 1]);
                drawingShapes.RemoveAt(drawingShapes.Count - 1);
                RefreshAll();
                return peelings.Peek();
            }
        }
internal DrawingShape PeelShape ( ) { lock ( renderSyncObject ) { if ( drawingShapes . Count == 0 ) return null ; string statName = drawingShapes [ drawingShapes . Count - 1 ] . GetType ( ) . Name . Replace ( " " , " " ) ; UpdateStats ( statName , - 1 ) ; peelings . Push ( drawingShapes [ drawingShapes . Count - 1 ] ) ; drawingShapes . RemoveAt ( drawingShapes . Count - 1 ) ; RefreshAll ( ) ; return peelings . Peek ( ) ; } }
Peels the shape from the end(top) of the list,
updates the render targets and puts the peeled shape to the stack of peelings.
Peels the shape from the end ( top ) of the list updates the render targets and puts the peeled shape to the stack of peelings .
None