/// <summary> /// Form closing /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void TileSetForm_FormClosed(object sender, FormClosedEventArgs e) { if (Batch != null) { Batch.Dispose(); } Batch = null; if (TileSet != null) { TileSet.Dispose(); } TileSet = null; if (CheckerBoard != null) { CheckerBoard.Dispose(); } CheckerBoard = null; if (BMFont != null) { BMFont.Dispose(); } BMFont = null; }
/// <summary> /// Dispose resources /// </summary> /// <param name="disposing"></param> protected override void Dispose(bool disposing) { if (disposing && (components != null)) { components.Dispose(); } base.Dispose(disposing); if (TileSet != null) { TileSet.Dispose(); } TileSet = null; if (SpriteBatch != null) { SpriteBatch.Dispose(); } SpriteBatch = null; if (CheckerBoard != null) { CheckerBoard.Dispose(); } CheckerBoard = null; }
/// <summary> /// Form closing /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void DungeonForm_FormClosed(object sender, FormClosedEventArgs e) { DrawTimer.Stop(); if (Dungeon != null) { Dungeon.Dispose(); } Dungeon = null; if (SpriteBatch != null) { SpriteBatch.Dispose(); } SpriteBatch = null; if (Icons != null) { Icons.Dispose(); } Icons = null; if (CheckerBoard != null) { CheckerBoard.Dispose(); } CheckerBoard = null; }
/// <summary> /// /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void AnimationForm_FormClosed(object sender, FormClosedEventArgs e) { if (SpriteBatch != null) { SpriteBatch.Dispose(); } SpriteBatch = null; if (Animation != null) { Animation.Dispose(); } Animation = null; if (CheckerBoard != null) { CheckerBoard.Dispose(); } CheckerBoard = null; }
/// <summary> /// Form closing /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void ItemForm_FormClosed(object sender, FormClosedEventArgs e) { if (TileSet != null) { TileSet.Dispose(); } TileSet = null; if (SpriteBatch != null) { SpriteBatch.Dispose(); } SpriteBatch = null; if (CheckerBoard != null) { CheckerBoard.Dispose(); } CheckerBoard = null; }
/// <summary> /// Form closing /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void BitmapFontForm_FormClosed(object sender, FormClosedEventArgs e) { if (Batch != null) { Batch.Dispose(); } Batch = null; if (CurrentFont != null) { CurrentFont.Dispose(); } CurrentFont = null; if (CheckerBoard != null) { CheckerBoard.Dispose(); } CheckerBoard = null; }
/// <summary> /// /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void LayoutForm_FormClosed(object sender, System.Windows.Forms.FormClosedEventArgs e) { if (Batch != null) { Batch.Dispose(); } Batch = null; if (CheckerBoard != null) { CheckerBoard.Dispose(); } CheckerBoard = null; if (CurrentLayout != null) { CurrentLayout.Dispose(); } CurrentLayout = null; }
/// <summary> /// Form closing /// </summary> /// <param name="sender"></param> /// <param name="e"></param> void ParentForm_FormClosing(object sender, FormClosingEventArgs e) { DrawTimer.Stop(); if (Batch != null) { Batch.Dispose(); } Batch = null; if (Icons != null) { Icons.Dispose(); } Icons = null; if (CheckerBoard != null) { CheckerBoard.Dispose(); } CheckerBoard = null; }