Fix crash on cygwin with completion in text mode.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23308 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Enrico Forestieri 2008-02-28 10:28:10 +00:00
parent e56e5e213c
commit 268dce39b4

View File

@ -130,9 +130,10 @@ public:
if (role != Qt::DisplayRole && role != Qt::EditRole) if (role != Qt::DisplayRole && role != Qt::EditRole)
return QVariant(); return QVariant();
if (index.column() == 0) if (index.column() == 0) {
return toqstr(list_->data(index.row())); docstring const word = list_->data(index.row());
else if (index.column() == 1) { return toqstr(word);
} else if (index.column() == 1) {
// get icon from cache // get icon from cache
QPixmap scaled; QPixmap scaled;
QString const name = ":" + toqstr(list_->icon(index.row())); QString const name = ":" + toqstr(list_->icon(index.row()));