X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2FBufferList.h;h=f6804c522630a290b389cd8d68e3b7239ac6aa82;hb=42eb8a373a35da02c45c0d225d37f5d677ddfc2d;hp=179cc358bc2af2d1400b10704d870697ddccfa87;hpb=09b7e6e60aea3644c568212b7dd1f90c85020d2e;p=lyx.git diff --git a/src/BufferList.h b/src/BufferList.h index 179cc358bc..f6804c5226 100644 --- a/src/BufferList.h +++ b/src/BufferList.h @@ -40,10 +40,8 @@ public: iterator end(); const_iterator end() const; - /// write all buffers, asking the user, returns false if cancelled - bool quitWriteAll(); - /// create a new buffer + /// \return 0 if the Buffer creation is not possible for whatever reason. Buffer * newBuffer(std::string const & s, bool ronly = false); /// delete a buffer @@ -61,8 +59,11 @@ public: /// emergency save for all buffers void emergencyWriteAll(); - /// close buffer. Returns false if cancelled by user - bool close(Buffer * buf, bool ask); + /// save emergency file for the given buffer + /** + * \return a status message towards the user. + */ + docstring emergencyWrite(Buffer * buf); /// return true if no buffers loaded bool empty() const; @@ -108,16 +109,10 @@ private: BufferList(BufferList const &); void operator=(BufferList const &); - /// ask to save a buffer on quit, returns false if should cancel - bool quitWriteBuffer(Buffer * buf); - typedef std::vector BufferStorage; /// storage of all buffers BufferStorage bstore; - - /// save emergency file for the given buffer - void emergencyWrite(Buffer * buf); }; /// Implementation is in LyX.cpp