aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@theqtcompany.com>2015-11-13 15:34:57 +0100
committerUlf Hermann <ulf.hermann@theqtcompany.com>2015-11-16 14:50:57 +0000
commit53957ee2ae7937294b471bb873cfd76e9a12814e (patch)
tree87e9268392156491bccd4e0c3ee8d8e53d69040b
parent00f0e00fb22065e0e4d5702bb851887c7d935e92 (diff)
Translate strings in input events model
Change-Id: Ia549295adafa42b9236f568c04e52b48e8943337 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
-rw-r--r--plugins/qmlprofiler/inputeventsmodel.cpp36
1 files changed, 18 insertions, 18 deletions
diff --git a/plugins/qmlprofiler/inputeventsmodel.cpp b/plugins/qmlprofiler/inputeventsmodel.cpp
index 808e8aff80..6e8aa2af8b 100644
--- a/plugins/qmlprofiler/inputeventsmodel.cpp
+++ b/plugins/qmlprofiler/inputeventsmodel.cpp
@@ -66,52 +66,52 @@ QVariantList InputEventsModel::labels() const
QVariantMap InputEventsModel::details(int index) const
{
QVariantMap result;
- result.insert(QLatin1String("Timestamp"), QmlProfilerDataModel::formatTime(startTime(index)));
+ result.insert(tr("Timestamp"), QmlProfilerDataModel::formatTime(startTime(index)));
QString type;
const InputEvent &event = m_data[index];
switch (event.type) {
case QmlDebug::InputKeyPress:
- type = QLatin1String("Key Press");
+ type = tr("Key Press");
case QmlDebug::InputKeyRelease:
if (type.isEmpty())
- type = QLatin1String("Key Release");
+ type = tr("Key Release");
if (event.a != 0) {
- result.insert(QLatin1String("Key"), QLatin1String(
+ result.insert(tr("Key"), QLatin1String(
QMetaEnum::fromType<Qt::Key>().valueToKey(event.a)));
}
if (event.b != 0) {
- result.insert(QLatin1String("Modifiers"), QLatin1String(
+ result.insert(tr("Modifiers"), QLatin1String(
QMetaEnum::fromType<Qt::KeyboardModifiers>().valueToKeys(event.b)));
}
break;
case QmlDebug::InputMouseDoubleClick:
- type = QLatin1String("Double Click");
+ type = tr("Double Click");
case QmlDebug::InputMousePress:
if (type.isEmpty())
- type = QLatin1String("Mouse Press");
+ type = tr("Mouse Press");
case QmlDebug::InputMouseRelease:
if (type.isEmpty())
- type = QLatin1String("Mouse Release");
- result.insert(QLatin1String("Button"), QLatin1String(
+ type = tr("Mouse Release");
+ result.insert(tr("Button"), QLatin1String(
QMetaEnum::fromType<Qt::MouseButtons>().valueToKey(event.a)));
- result.insert(QLatin1String("Result"), QLatin1String(
+ result.insert(tr("Result"), QLatin1String(
QMetaEnum::fromType<Qt::MouseButtons>().valueToKeys(event.b)));
break;
case QmlDebug::InputMouseMove:
- type = QLatin1String("Mouse Move");
- result.insert(QLatin1String("X"), QString::number(event.a));
- result.insert(QLatin1String("Y"), QString::number(event.b));
+ type = tr("Mouse Move");
+ result.insert(tr("X"), QString::number(event.a));
+ result.insert(tr("Y"), QString::number(event.b));
break;
case QmlDebug::InputMouseWheel:
- type = QLatin1String("Mouse Wheel");
- result.insert(QLatin1String("Angle X"), QString::number(event.a));
- result.insert(QLatin1String("Angle Y"), QString::number(event.b));
+ type = tr("Mouse Wheel");
+ result.insert(tr("Angle X"), QString::number(event.a));
+ result.insert(tr("Angle Y"), QString::number(event.b));
break;
case QmlDebug::InputKeyUnknown:
- type = QLatin1String("Keyboard Event");
+ type = tr("Keyboard Event");
break;
case QmlDebug::InputMouseUnknown:
- type = QLatin1String("Mouse Event");
+ type = tr("Mouse Event");
break;
default:
Q_UNREACHABLE();