private void Dispose(bool disposing) { if (!this.disposed) { if (disposing) { //dispose managed components } if (hImage >= 0) { FSDK.FreeImage(hImage); hImage = -1; } } disposed = true; }