From 4ea4f87ebf84d6d52eb730caecc472c3c43dc784 Mon Sep 17 00:00:00 2001 From: Georg Baum Date: Mon, 8 Nov 2004 08:22:03 +0000 Subject: [PATCH] fix error message, add some documentation git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@9202 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/ChangeLog | 5 +++++ src/converter.C | 6 +++--- src/converter.h | 5 +++-- 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 3ccdc9bd96..b3e2e373e0 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2004-11-07 Georg Baum + + * converter.C (move): don't lie in the error message + * converter.h (isReachable, move): document + 2004-11-07 Lars Gullik Bjonnes * buffer.C: remove unused using lyx::support::atoi diff --git a/src/converter.C b/src/converter.C index 7ce839105a..4ec623c2db 100644 --- a/src/converter.C +++ b/src/converter.C @@ -438,8 +438,6 @@ bool Converters::convert(Buffer const * buffer, } -// If from = /path/file.ext and to = /path2/file2.ext2 then this method -// moves each /path/file*.ext file to /path2/file2*.ext2' bool Converters::move(string const & fmt, string const & from, string const & to, bool copy) { @@ -468,7 +466,9 @@ bool Converters::move(string const & fmt, : mover.rename(from2, to2); if (!moved && no_errors) { Alert::error(_("Cannot convert file"), - bformat(_("Could not move a temporary file from %1$s to %2$s."), + bformat(copy ? + _("Could not copy a temporary file from %1$s to %2$s.") : + _("Could not move a temporary file from %1$s to %2$s."), from2, to2)); no_errors = false; } diff --git a/src/converter.h b/src/converter.h index ce290766fc..bfdb26f788 100644 --- a/src/converter.h +++ b/src/converter.h @@ -97,7 +97,7 @@ public: std::vector const getReachable(std::string const & from, bool only_viewable, bool clear_visited); - /// + /// Does a conversion path from format \p from to format \p to exist? bool isReachable(std::string const & from, std::string const & to); /// Graph::EdgePath const getPath(std::string const & from, std::string const & to); @@ -141,7 +141,8 @@ private: ConverterList converterlist_; /// std::string latex_command_; - /// + /// If \p from = /path/file.ext and \p to = /path2/file2.ext2 then + /// this method moves each /path/file*.ext file to /path2/file2*.ext2 bool move(std::string const & fmt, std::string const & from, std::string const & to, bool copy); -- 2.39.2