]> Creatis software - creaMaracasVisu.git/blobdiff - lib/maracasVisuLib/src/interface/wxWindows/widgets/imageUndoRedo/imageInfoUR.cxx
DFCH: ManualPaint + imageUndoRedo -> 50% tested. (Save Images undo and redo) :) :)
[creaMaracasVisu.git] / lib / maracasVisuLib / src / interface / wxWindows / widgets / imageUndoRedo / imageInfoUR.cxx
index b45e21d920915b8e27a58880380875b090ab85c2..18c255eeae6ce381f34d7cc203bf4fe96792cf06 100755 (executable)
@@ -13,7 +13,6 @@ ImageInfoUR::ImageInfoUR() {
 }
 
 ImageInfoUR::~ImageInfoUR() {
-       this->m_Image->Delete();
 }
 
 void ImageInfoUR::SetImageName(const std::string &imgName) {
@@ -42,7 +41,7 @@ void ImageInfoUR::RemoveImageFromMemory(const std::string& gPath) {
        if (!this->m_OnDisk) {
                this->SaveImageAsMHD(gPath);
        }
-       this->m_Image->Delete();
+       this->m_Image = NULL;
        this->SetStatus(false);
 }
 void ImageInfoUR::LoadImageMHDToMemory(const std::string& gPath) {
@@ -62,9 +61,7 @@ void ImageInfoUR::SaveImageAsMHD(const std::string& gPath) {
        w->SetCompression(false);
        w->SetFileDimensionality(this->m_Image->GetDataDimension());
        w->SetFileName(filename.c_str());
-       w->Update();
        w->Write();
-       w->Delete();
 }
 
 void ImageInfoUR::RemoveImageFromDisk(const std::string& gPath)