mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-13 17:20:55 +00:00
* QPrefsDialog.C (remove_format): Prevent deletion of file formats
if they are used by a converter and warn the user accordingly. Fixes crash (bug 2431). git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/branches/BRANCH_1_4_X@13513 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
bf4edb9a09
commit
88d71d9375
@ -1,3 +1,9 @@
|
||||
2006-03-28 Jürgen Spitzmüller <j.spitzmueller@gmx.de>
|
||||
|
||||
* QPrefsDialog.C (remove_format): Prevent deletion of file formats
|
||||
if they are used by a converter and warn the user accordingly.
|
||||
Fixes crash (bug 2431).
|
||||
|
||||
2006-03-22 Jean-Marc Lasgouttes <lasgouttes@lyx.org>
|
||||
|
||||
* QDocument.C (apply): skip secnumdepth and tocdepth if the class
|
||||
|
@ -19,6 +19,8 @@
|
||||
#include "qcoloritem.h"
|
||||
#include "qfontexample.h"
|
||||
|
||||
#include "frontends/Alert.h"
|
||||
|
||||
#include "ui/QPrefAsciiModule.h"
|
||||
#include "ui/QPrefDateModule.h"
|
||||
#include "ui/QPrefKeyboardModule.h"
|
||||
@ -845,7 +847,14 @@ void QPrefsDialog::remove_format()
|
||||
int const nr(fileformatsModule->formatsLB->currentItem());
|
||||
if (nr < 0)
|
||||
return;
|
||||
form_->formats().erase(form_->formats().get(nr).name());
|
||||
string const current_text = form_->formats().get(nr).name();
|
||||
if (form_->converters().formatIsUsed(current_text)) {
|
||||
Alert::error(_("Format in use"),
|
||||
_("Cannot remove a Format used by a Converter. "
|
||||
"Remove the converter first."));
|
||||
return;
|
||||
}
|
||||
form_->formats().erase(current_text);
|
||||
updateFormats();
|
||||
form_->converters().update(form_->formats());
|
||||
|
||||
|
@ -106,7 +106,10 @@ What's new
|
||||
|
||||
- Fix alignment of superscript previews (bug 2391).
|
||||
|
||||
- Reenable quotes in ERT (bug 2429)
|
||||
- Reenable quotes in ERT (bug 2429).
|
||||
|
||||
- Prevent deletion of file formats that are used by a converter. Fixes crash
|
||||
(bug 2431).
|
||||
|
||||
* Configuration/Installation:
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user