Fix compilation with qt 4.2: QString::operator[] returns a QCharRef,

which is supposedly like a QChar... except that some methods like isUpper 
were forgotten in the process.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33580 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jean-Marc Lasgouttes 2010-02-26 14:46:42 +00:00
parent 4aeca63887
commit 6d671bf5f2

View File

@ -783,9 +783,9 @@ void MenuDefinition::expandLanguageSelector(Buffer const * buf)
bool success = false;
// try capitals first
for (int i = 0; i < label.size(); ++i) {
if (!label[i].isUpper())
QChar const ch = label[i];
if (!ch.isUpper())
continue;
QString const ch = QString(label[i]);
if (!accelerators.contains(ch, Qt::CaseInsensitive)) {
label = label + toqstr("|") + ch;
accelerators.append(ch);