Whitespace and dead code cleanup

The coding style for switch isn't the prettiest, but let's at least keep
things consistent.

Also, those ugly break statements never got reached, anyway.

And there was no need to re-declare and re-generate currentString.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2014-02-12 06:18:15 -08:00
parent 9c9867dec5
commit 6332976c3d
2 changed files with 7 additions and 9 deletions

View file

@ -1865,11 +1865,9 @@ QVariant LanguageModel::data(const QModelIndex& index, int role) const
case Qt::DisplayRole: {
QLocale l( currentString.remove("subsurface_"));
return currentString == "English" ? currentString : QString("%1 (%2)").arg(l.languageToString(l.language())).arg(l.countryToString(l.country()));
}break;
case Qt::UserRole: {
QString currentString = languages.at(index.row());
}
case Qt::UserRole:
return currentString == "English" ? "en_US" : currentString.remove("subsurface_");
}break;
}
return QVariant();
}