protected override void Dispose(bool disposing) { if (disposing && (components != null)) { components.Dispose(); } lock (this) { if (Graphics != null) { Graphics.Dispose(); } if (Bitmap != null) { Bitmap.Dispose(); } if (hDCGraphics != null) { hDCGraphics.Dispose(); } if (RP != null) { RP.Dispose(); } } base.Dispose(disposing); }
/// <summary> /// Освободить все используемые ресурсы. /// </summary> /// <param name="disposing">истинно, если управляемый ресурс должен быть удален; иначе ложно.</param> protected override void Dispose(bool disposing) { if (disposing && (components != null)) { components.Dispose(); } lock (this) { if (RazorGFX != null) { RazorGFX.Dispose(); } if (RazorBMP != null) { RazorBMP.Dispose(); } if (hDCGraphics != null) { hDCGraphics.Dispose(); } RP.Dispose(); } base.Dispose(disposing); }