]> git.lyx.org Git - lyx.git/blobdiff - src/graphics/GraphicsCacheItem_pimpl.C
prepare for 1.1.6pre2
[lyx.git] / src / graphics / GraphicsCacheItem_pimpl.C
index c9b27171657376b008911451b52320b52b09fdeb..42d7aca00d3ae2f7d7498565d22d1f617a20918c 100644 (file)
@@ -41,9 +41,7 @@ GraphicsCacheItem_pimpl::GraphicsCacheItem_pimpl()
 
 GraphicsCacheItem_pimpl::~GraphicsCacheItem_pimpl()
 {
-       if (imageStatus_ == GraphicsCacheItem::Loaded) {
-               XFreePixmap(fl_get_display(), pixmap_);
-       }
+       delete pixmap_;
        delete renderer;
 }
 
@@ -109,7 +107,7 @@ GraphicsCacheItem_pimpl::renderXPM(string const & filename)
        temp = ChangeExtension(filename, string());
        
        // Add some stuff to have it a unique temp file.
-       xpmfile = TmpFileName(string(), temp);
+       xpmfile = lyx::tempName(string(), temp); //TmpFileName(string(), temp);
        xpmfile = ChangeExtension(xpmfile, ".xpm");     
        
        command += xpmfile;