CVirtualDirectoryModel: Mark strings as translatable where applicable
This commit is contained in:
parent
04bfb17f3c
commit
041afedea3
|
@ -75,18 +75,20 @@ QVariant CVirtualDirectoryModel::data(const QModelIndex& rkIndex, int Role) cons
|
||||||
if (Role == Qt::DisplayRole || Role == Qt::ToolTipRole)
|
if (Role == Qt::DisplayRole || Role == Qt::ToolTipRole)
|
||||||
{
|
{
|
||||||
if (!rkIndex.parent().isValid())
|
if (!rkIndex.parent().isValid())
|
||||||
return "Resources";
|
{
|
||||||
|
return tr("Resources");
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
CVirtualDirectory *pDir = IndexDirectory(rkIndex);
|
CVirtualDirectory *pDir = IndexDirectory(rkIndex);
|
||||||
if (pDir) return TO_QSTRING(pDir->Name());
|
if (pDir)
|
||||||
|
return TO_QSTRING(pDir->Name());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (Role == Qt::DecorationRole)
|
if (Role == Qt::DecorationRole)
|
||||||
{
|
{
|
||||||
return QIcon(":/icons/Open_24px.svg");
|
return QIcon(QStringLiteral(":/icons/Open_24px.svg"));
|
||||||
}
|
}
|
||||||
|
|
||||||
return QVariant::Invalid;
|
return QVariant::Invalid;
|
||||||
|
|
Loading…
Reference in New Issue