mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-22 01:59:02 +00:00
fix crash in preferences dialog
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15732 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
f2025c20e9
commit
60059d0c08
@ -938,10 +938,13 @@ void PrefConverters::updateGui()
|
||||
|
||||
void PrefConverters::switch_converter(int nr)
|
||||
{
|
||||
if (nr<0)
|
||||
if (nr < 0)
|
||||
return;
|
||||
|
||||
int const cnr = convertersLW->currentItem()->type();
|
||||
// FIXME: why is there now valid current item?
|
||||
if (cnr < 0)
|
||||
return;
|
||||
Converter const & c(form_->converters().get(cnr));
|
||||
converterFromCO->setCurrentIndex(form_->formats().getNumber(c.from));
|
||||
converterToCO->setCurrentIndex(form_->formats().getNumber(c.to));
|
||||
@ -970,6 +973,9 @@ void PrefConverters::updateButtons()
|
||||
|| from.name() == to.name());
|
||||
|
||||
int const cnr = convertersLW->currentItem()->type();
|
||||
// FIXME: why is there now valid current item?
|
||||
if (cnr < 0)
|
||||
return;
|
||||
Converter const & c(form_->converters().get(cnr));
|
||||
string const old_command = c.command;
|
||||
string const old_flag = c.flags;
|
||||
|
Loading…
Reference in New Issue
Block a user