#include <boost/scoped_ptr.hpp>
#include <boost/signals/trackable.hpp>
+#include <boost/weak_ptr.hpp>
/** No two InsetExternalParams variables can have the same temporary file.
};
-class RenderInset;
+class RenderBase;
///
class InsetExternal : public InsetOld, public boost::signals::trackable
void setParams(InsetExternalParams const &, Buffer const &);
private:
+ void cache(BufferView *) const;
+ BufferView * view() const;
/** This method is connected to the graphics loader, so we are
* informed when the image has been loaded.
*/
/// The current params
InsetExternalParams params_;
/// The thing that actually draws the image on LyX's screen.
- boost::scoped_ptr<RenderInset> renderer_;
+ boost::scoped_ptr<RenderBase> renderer_;
+
+ /// Cached
+ mutable boost::weak_ptr<BufferView> view_;
};