Make LFUN_HELP_OPEN open the document in read-only mode.

This fixes problems where Mac users can modify the documentation
by mistake. Note that it is still possible to open those document by
explicit path or to toggle off the read-only status (but this is only
useful to documentors anyway).


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33260 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jean-Marc Lasgouttes 2010-01-29 12:01:17 +00:00
parent a1e991a82e
commit 167b6dc0f2

View File

@ -1020,6 +1020,7 @@ void GuiApplication::dispatch(FuncRequest const & cmd, DispatchResult & dr)
Buffer * buf = current_view_->loadDocument(fname, false); Buffer * buf = current_view_->loadDocument(fname, false);
if (buf) { if (buf) {
current_view_->setBuffer(buf); current_view_->setBuffer(buf);
buf->setReadonly(true);
buf->updateLabels(); buf->updateLabels();
buf->errors("Parse"); buf->errors("Parse");
} }