/// <summary> /// 释放资源 /// </summary> protected override void Dispose(bool disposing) { if (disposing) { image = null; TranImage = null; TranLaterImage = null; } if (_tBrush != null) { _tBrush.Dispose(); _tBrush = null; } if (sTimer != null) { sTimer.Stop(); sTimer.Dispose(); } if (alpha != null) { alpha.Dispose(); alpha = null; } base.Dispose(disposing); }
/// <summary> /// 清理所有正在使用的资源。 /// </summary> /// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param> protected override void Dispose(bool disposing) { if (disposing) { } if (toolFirst != null) { toolFirst.Dispose(); toolFirst = null; } if (toolEnd != null) { toolEnd.Dispose(); toolEnd = null; } if (toolNext != null) { toolNext.Dispose(); toolNext = null; } if (toolLast != null) { toolLast.Dispose(); toolLast = null; } if (lblPageInfo != null) { lblPageInfo.Dispose(); lblPageInfo = null; } if (txtCurrentPage != null) { txtCurrentPage.Dispose(); txtCurrentPage = null; } if (lbDesc != null) { lbDesc.Dispose(); lbDesc = null; } if (panel1 != null) { panel1.Dispose(); panel1 = null; } if (tControl2 != null) { tControl2.Dispose(); tControl2 = null; } if (components != null) { components.Dispose(); components = null; } base.Dispose(disposing); }