]> git.lyx.org Git - features.git/commitdiff
GuiImage: detaching the QImage does not have any good side effect apparently. It...
authorAbdelrazak Younes <younes@lyx.org>
Fri, 19 Sep 2008 11:42:53 +0000 (11:42 +0000)
committerAbdelrazak Younes <younes@lyx.org>
Fri, 19 Sep 2008 11:42:53 +0000 (11:42 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26456 a592a061-630c-0410-9148-cb99ea01b6c8

src/frontends/qt4/GuiImage.cpp

index cf580b12530150370c2bbdb3b121602c35dec3b4..bc869d2cdbe3af612f7dc2933dacfc4353566ad9 100644 (file)
@@ -90,7 +90,6 @@ bool GuiImage::load()
                LYXERR(Debug::GRAPHICS, "Unable to open image");
                return false;
        }
-       original_.detach();
        return true;
 }
 
@@ -110,13 +109,10 @@ bool GuiImage::setPixmap(Params const & params)
        is_transformed_ |= scale(params);
 
        // Clear the pixmap to save some memory.
-       if (is_transformed_) {
-               original_.detach();
+       if (is_transformed_)
                original_ = QImage();
-       } else {
-               transformed_.detach();
+       else
                transformed_ = QImage();
-       }
 
        return true;
 }