mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 13:18:28 +00:00
* GuiPrefs.cpp:
- do not allow to change a format's short name if the format is used by a converter (fixes crash issue #6815). git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35079 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
547773f0d0
commit
a84925bebe
@ -1923,8 +1923,17 @@ void PrefFileformats::on_shortcutED_textEdited(const QString & s)
|
||||
void PrefFileformats::on_formatED_editingFinished()
|
||||
{
|
||||
string const newname = fromqstr(formatED->displayText());
|
||||
if (newname == currentFormat().name())
|
||||
string const oldname = currentFormat().name();
|
||||
if (newname == oldname)
|
||||
return;
|
||||
if (form_->converters().formatIsUsed(oldname)) {
|
||||
Alert::error(_("Format in use"),
|
||||
_("You cannot change a format's short name "
|
||||
"if the format is used by a converter. "
|
||||
"Please remove the converter first."));
|
||||
updateView();
|
||||
return;
|
||||
}
|
||||
|
||||
currentFormat().setName(newname);
|
||||
changed();
|
||||
|
Loading…
Reference in New Issue
Block a user