From 4ccc4d73290309908898387fe0d24503606336ad Mon Sep 17 00:00:00 2001 From: Stefan Fuchs Date: Sat, 16 Jun 2018 16:24:16 +0200 Subject: Enable translation for even name "modechange" Enable translations for dive event name "modechange". But clearly don't do this for the string which is used internally but only push "modechange" to the translation system to be able to translate it in the UI. Signed-off-by: Stefan Fuchs --- profile-widget/profilewidget2.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/profile-widget/profilewidget2.cpp b/profile-widget/profilewidget2.cpp index e7b7c1460..142514a2d 100644 --- a/profile-widget/profilewidget2.cpp +++ b/profile-widget/profilewidget2.cpp @@ -1623,7 +1623,8 @@ void ProfileWidget2::addDivemodeSwitch() QPointF scenePos = mapToScene(mapFromGlobal(action->data().toPoint())); for (i = 0; i < UNDEF_COMP_TYPE; i++) if (QString(divemode_text_ui[i]) == action->text()) - add_event(current_dc, lrint(timeAxis->valueAt(scenePos)), 8, 0, i, "modechange"); + add_event(current_dc, lrint(timeAxis->valueAt(scenePos)), 8, 0, i, + QT_TRANSLATE_NOOP("gettextFromC", "modechange")); invalidate_dive_cache(current_dive); mark_divelist_changed(true); replot(); -- cgit v1.2.3-70-g09d2