コード例 #1
0
 /// <summary>
 /// Disposes this object.
 /// </summary>
 /// <param name="disposing">
 /// True if this method was called as part of the Dispose method.
 /// </param>
 protected virtual void Dispose(bool disposing)
 {
     if (disposing)
     {
         lock (this)
         {
             if (starfield != null)
             {
                 starfield.Dispose();
                 starfield = null;
             }
         }
     }
 }
コード例 #2
0
 /// <summary>
 /// Disposes this object.
 /// </summary>
 /// <param name="disposing">
 /// True if this method was called as part of the Dispose method.
 /// </param>
 protected virtual void Dispose(bool disposing)
 {
     if (disposing)
     {
         lock (this)
         {
             if (bloomComponent != null)
             {
                 bloomComponent.Dispose();
                 bloomComponent = null;
             }
             if (starfield != null)
             {
                 starfield.Dispose();
                 starfield = null;
             }
         }
     }
 }