]> git.lyx.org Git - lyx.git/blobdiff - src/graphics/GraphicsCacheItem.h
prepare for 1.1.6pre2
[lyx.git] / src / graphics / GraphicsCacheItem.h
index 27f67f2249806810ac0cdf02abb5e0d712ba2f45..0157d35c97b20698f25bdf50d921466ba266e652 100644 (file)
@@ -37,7 +37,7 @@ using SigC::Signal0;
  */
 
 class GraphicsCacheItem_pimpl;
-
+class LyXImage;
 
 /// A GraphicsCache item holder.
 class GraphicsCacheItem {
@@ -47,7 +47,7 @@ public:
        /// copy c-tor.
        GraphicsCacheItem(GraphicsCacheItem const &);
        /// Assignment operator.
-       GraphicsCacheItem const & operator=(GraphicsCacheItem const &);
+       GraphicsCacheItem & operator=(GraphicsCacheItem const &);
        
        /// Get the height of the image. Returns -1 on error.
        int getHeight() const; 
@@ -56,26 +56,35 @@ public:
        int getWidth() const; 
 
        /// Return a pixmap that can be displayed on X server.
-       Pixmap getImage() const; 
-
+       LyXImage * getImage() const; 
+       ///
        enum ImageStatus {
+               ///
                Loading = 1,
+               ///
                ErrorConverting,
+               ///
                ErrorReading,
+               ///
+               UnknownError,
+               ///
                Loaded
        };
        
        /// Is the pixmap ready for display?
        ImageStatus getImageStatus() const; 
 
-       /// Get a notification when the image conversion is done.
-       /// used by an internal callback mechanism.
+       /** Get a notification when the image conversion is done.
+           used by an internal callback mechanism.
+       */
        void imageConverted(int retval);
 
-
+       /// Create another copy of the object.
+       GraphicsCacheItem * Clone() const;
+       
 private:
-    /// Private c-tor so that only GraphicsCache can create an instance.
-    GraphicsCacheItem();
+       /// Private c-tor so that only GraphicsCache can create an instance.
+       GraphicsCacheItem();
 
        /// internal copy mechanism.
        void copy(GraphicsCacheItem const &);
@@ -85,13 +94,15 @@ private:
        /// Set the filename this item will be pointing too.
        bool setFilename(string const & filename);
 
-    ///
-    friend class GraphicsCache;
+       ///
+       friend class GraphicsCache;
 
+       ///
        GraphicsCacheItem_pimpl * pimpl;
 
-       /// The filename we refer too, this is used when removing ourselves
-       /// from the cache.
+       /** The filename we refer too.
+           This is used when removing ourselves from the cache.
+       */
        string filename_;
 };