]> git.lyx.org Git - lyx.git/blobdiff - src/graphics/GraphicsCacheItem.h
Replace FileMonitor with FileMonitor2 in GraphicsCacheItem
[lyx.git] / src / graphics / GraphicsCacheItem.h
index cceee96f32b028e1634305a4a8a6e8682eae9aed..b6d7d4164ca0411e7fd0b44503f0e69a7875348d 100644 (file)
@@ -30,8 +30,7 @@
 
 #include "GraphicsTypes.h"
 
-#include <boost/scoped_ptr.hpp>
-#include <boost/signal.hpp>
+#include <boost/signals2.hpp>
 
 
 namespace lyx {
@@ -47,14 +46,16 @@ class Converter;
 class CacheItem {
 public:
        ///
-       CacheItem(support::FileName const & file);
-
-       /// Define an empty d-tor out-of-line to keep boost::scoped_ptr happy.
+       CacheItem(support::FileName const & file, support::FileName const & doc_file);
+       /// Needed for the pimpl
        ~CacheItem();
 
        ///
        support::FileName const & filename() const;
 
+       /// Try to load a display format.
+       bool tryDisplayFormat() const;
+
        /// It's in the cache. Now start the loading process.
        void startLoading() const;
 
@@ -65,11 +66,6 @@ public:
        void startMonitoring() const;
        ///
        bool monitoring() const;
-       /** Returns the check sum of filename() so that, for example, you can
-        *  ascertain whether to output a new PostScript version of the file
-        *  for a LaTeX run.
-        */
-       unsigned long checksum() const;
 
        /** Get the image associated with filename().
         *  If the image is not yet loaded, returns 0.
@@ -84,10 +80,9 @@ public:
        /** Connect and you'll be informed when the loading status of the image
         *  changes.
         */
-       typedef boost::signal<void()> sig_type;
-       typedef sig_type::slot_type slot_type;
+       typedef boost::signals2::signal<void()>::slot_type slot_type;
        ///
-       boost::signals::connection connect(slot_type const &) const;
+       boost::signals2::connection connect(slot_type const &) const;
 
 private:
        /// noncopyable
@@ -96,9 +91,8 @@ private:
 
        /// Use the Pimpl idiom to hide the internals.
        class Impl;
-
        /// The pointer never changes although *pimpl_'s contents may.
-       boost::scoped_ptr<Impl> const pimpl_;
+       Impl * const pimpl_;
 };
 
 } // namespace graphics