mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-09 18:31:04 +00:00
Clear the error list from previous errors
We only copied the error list to the cloned buffer when makeLatexfile failed. This means that a second try will never clear the error list and the user will be presented the same list again. Therefore, we unconditionally copy the error list such that we also clear the list on success.
This commit is contained in:
parent
9a37ec5152
commit
b754fb0253
@ -3600,13 +3600,11 @@ bool Buffer::doExport(string const & format, bool put_in_tempdir,
|
||||
// LaTeX backend
|
||||
else if (backend_format == format) {
|
||||
runparams.nice = true;
|
||||
if (!makeLaTeXFile(FileName(filename), string(), runparams)) {
|
||||
if (d->cloned_buffer_) {
|
||||
d->cloned_buffer_->d->errorLists["Export"] =
|
||||
d->errorLists["Export"];
|
||||
}
|
||||
bool const success = makeLaTeXFile(FileName(filename), string(), runparams);
|
||||
if (d->cloned_buffer_)
|
||||
d->cloned_buffer_->d->errorLists["Export"] = d->errorLists["Export"];
|
||||
if (!success)
|
||||
return false;
|
||||
}
|
||||
} else if (!lyxrc.tex_allows_spaces
|
||||
&& contains(filePath(), ' ')) {
|
||||
Alert::error(_("File name error"),
|
||||
@ -3614,13 +3612,11 @@ bool Buffer::doExport(string const & format, bool put_in_tempdir,
|
||||
return false;
|
||||
} else {
|
||||
runparams.nice = false;
|
||||
if (!makeLaTeXFile(FileName(filename), filePath(), runparams)) {
|
||||
if (d->cloned_buffer_) {
|
||||
d->cloned_buffer_->d->errorLists["Export"] =
|
||||
d->errorLists["Export"];
|
||||
}
|
||||
bool const success = makeLaTeXFile(FileName(filename), string(), runparams);
|
||||
if (d->cloned_buffer_)
|
||||
d->cloned_buffer_->d->errorLists["Export"] = d->errorLists["Export"];
|
||||
if (!success)
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
string const error_type = (format == "program")
|
||||
|
@ -99,6 +99,8 @@ What's new
|
||||
|
||||
- Fix undo warning when inserting plain text file (bug 7916).
|
||||
|
||||
- Do not repeatedly show export errors of a previous export.
|
||||
|
||||
|
||||
* DOCUMENTATION AND LOCALIZATION
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user