/// <summary> /// Raises the destroy event. /// </summary> private void OnDestroy() { // Return the Database if (_sceneDrawer != null) { _sceneDrawer.Dispose(); } if (_favSceneDrawer != null) { _favSceneDrawer.Dispose(); } if (_gameplayDrawer != null) { _gameplayDrawer.Dispose(); } if (_screenshotDrawer != null) { _screenshotDrawer.Dispose(); } if (_historyDrawer != null) { _historyDrawer.Dispose(); } SceneDatabaseProvider.ReturnDatabase(this); }
private void OnDestroy() { // Return the Database SceneDatabaseProvider.ReturnDatabase (this); if(_drawer != null) _drawer.Dispose (); if(_screenshotDrawer != null) _screenshotDrawer.Dispose (); }
private void OnDestroy() { if (_drawer != null) { _drawer.Dispose(); } if (_favDrawer != null) { _favDrawer.Dispose(); } if (_screenshotDrawer != null) { _screenshotDrawer.Dispose(); } SceneDatabaseProvider.ReturnDatabase(this); }