aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlessandro Portale <[email protected]>2022-09-01 13:23:10 +0200
committerAlessandro Portale <[email protected]>2022-09-19 12:28:35 +0000
commit75e35cc4f27c6f959f747e19ac844e67c73e9458 (patch)
tree27f0faeed8807feeba050b85c1e07b0589ce5390
parentcbc954866dda2167fe138b7b4e4dc152b61bee94 (diff)
Tracing: Convert to using Tr::tr
-rw-r--r--share/qtcreator/translations/qtcreator_cs.ts8
-rw-r--r--share/qtcreator/translations/qtcreator_da.ts12
-rw-r--r--share/qtcreator/translations/qtcreator_de.ts23
-rw-r--r--share/qtcreator/translations/qtcreator_fr.ts8
-rw-r--r--share/qtcreator/translations/qtcreator_hr.ts16
-rw-r--r--share/qtcreator/translations/qtcreator_ja.ts23
-rw-r--r--share/qtcreator/translations/qtcreator_pl.ts9
-rw-r--r--share/qtcreator/translations/qtcreator_ru.ts22
-rw-r--r--share/qtcreator/translations/qtcreator_uk.ts13
-rw-r--r--share/qtcreator/translations/qtcreator_zh_CN.ts8
-rw-r--r--share/qtcreator/translations/qtcreator_zh_TW.ts4
-rw-r--r--src/libs/tracing/qml/ButtonsBar.qml10
-rw-r--r--src/libs/tracing/qml/CategoryLabel.qml3
-rw-r--r--src/libs/tracing/qml/FlameGraphView.qml7
-rw-r--r--src/libs/tracing/qml/RangeDetails.qml6
-rw-r--r--src/libs/tracing/qml/RowLabel.qml3
-rw-r--r--src/libs/tracing/qml/SelectionRangeDetails.qml10
-rw-r--r--src/libs/tracing/timelinetracemanager.cpp11
-rw-r--r--src/libs/tracing/tracingtr.h2
19 files changed, 71 insertions, 127 deletions
diff --git a/share/qtcreator/translations/qtcreator_cs.ts b/share/qtcreator/translations/qtcreator_cs.ts
index 74aa7064eb4..f3e863b7c3c 100644
--- a/share/qtcreator/translations/qtcreator_cs.ts
+++ b/share/qtcreator/translations/qtcreator_cs.ts
@@ -42723,11 +42723,7 @@ Prověřte, prosím, oprávnění pro přístup k adresáři.</translation>
</message>
</context>
<context>
- <name>RangeDetails</name>
- <message>
- <source>Duration</source>
- <translation type="obsolete">Doba trvání</translation>
- </message>
+ <name>Tracing</name>
<message>
<source>Details</source>
<translation type="obsolete">Podrobnosti</translation>
@@ -46209,7 +46205,7 @@ Tyto předpony se používají dodatečně k nynějšímu názvu souboru na Pře
</message>
</context>
<context>
- <name>SelectionRangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Selection</source>
<translation>Výběr</translation>
diff --git a/share/qtcreator/translations/qtcreator_da.ts b/share/qtcreator/translations/qtcreator_da.ts
index 0695a8071ff..fd66da8720f 100644
--- a/share/qtcreator/translations/qtcreator_da.ts
+++ b/share/qtcreator/translations/qtcreator_da.ts
@@ -4296,7 +4296,7 @@ F.eks., vil &quot;Revision: 15&quot; efterlade grenen ved revision 15.</translat
</message>
</context>
<context>
- <name>ButtonsBar</name>
+ <name>Tracing</name>
<message>
<source>Jump to previous event.</source>
<translation>Hop to forrige event.</translation>
@@ -5193,7 +5193,7 @@ F.eks., vil &quot;Revision: 15&quot; efterlade grenen ved revision 15.</translat
</message>
</context>
<context>
- <name>CategoryLabel</name>
+ <name>Tracing</name>
<message>
<source>Collapse category</source>
<translation>Sammenfold kategori</translation>
@@ -35793,7 +35793,7 @@ Derudover testes enhedens forbindelse.</translation>
</message>
</context>
<context>
- <name>RowLabel</name>
+ <name>Tracing</name>
<message>
<source>[unknown]</source>
<translation>[ukendt]</translation>
@@ -36522,7 +36522,7 @@ Række: %4, Kolonne: %5
</message>
</context>
<context>
- <name>SelectionRangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Selection</source>
<translation>Markering</translation>
@@ -43466,7 +43466,7 @@ skal være et repository krævet SSH-autentifikation (se dokumentation på SSH o
</message>
</context>
<context>
- <name>FlameGraphView</name>
+ <name>Tracing</name>
<message>
<source>others</source>
<translation>andre</translation>
@@ -43765,7 +43765,7 @@ skal være et repository krævet SSH-autentifikation (se dokumentation på SSH o
</message>
</context>
<context>
- <name>Timeline::TimelineTraceManager</name>
+ <name>Tracing</name>
<message>
<source>Could not open %1 for writing.</source>
<translation>Kunne ikke åbne %1 til skrivning.</translation>
diff --git a/share/qtcreator/translations/qtcreator_de.ts b/share/qtcreator/translations/qtcreator_de.ts
index 497839143ac..f3d22974f8d 100644
--- a/share/qtcreator/translations/qtcreator_de.ts
+++ b/share/qtcreator/translations/qtcreator_de.ts
@@ -17481,7 +17481,7 @@ Diese Präfixe werden zusätzlich zum Dateinamen beim Wechseln zwischen Header-
</message>
</context>
<context>
- <name>SelectionRangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Selection</source>
<translation>Auswahl</translation>
@@ -27109,7 +27109,7 @@ Möchten Sie es beenden?</translation>
</message>
</context>
<context>
- <name>ButtonsBar</name>
+ <name>Tracing</name>
<message>
<source>Jump to previous event.</source>
<translation>Gehe zu vorangehendem Ereignis.</translation>
@@ -27130,9 +27130,6 @@ Möchten Sie es beenden?</translation>
<source>View event information on mouseover.</source>
<translation>Information zu Ereignis anzeigen, wenn sich der Mauszeiger darüber befindet.</translation>
</message>
-</context>
-<context>
- <name>CategoryLabel</name>
<message>
<source>Collapse category</source>
<translation>Kategorie einklappen</translation>
@@ -31344,7 +31341,7 @@ konnte dem Projekt &quot;%2&quot; nicht hinzugefügt werden.</translation>
</message>
</context>
<context>
- <name>RowLabel</name>
+ <name>Tracing</name>
<message>
<source>[unknown]</source>
<translation>[unbekannt]</translation>
@@ -41336,7 +41333,7 @@ Breche ausstehende Operationen ab...
</message>
</context>
<context>
- <name>FlameGraphView</name>
+ <name>Tracing</name>
<message>
<source>others</source>
<translation>andere</translation>
@@ -41487,7 +41484,7 @@ Breche ausstehende Operationen ab...
</message>
</context>
<context>
- <name>Timeline::TimelineTraceManager</name>
+ <name>Tracing</name>
<message>
<source>Could not open %1 for writing.</source>
<translation>Die Datei %1 konnte nicht zum Schreiben geöffnet werden.</translation>
@@ -44848,19 +44845,11 @@ Wenn Sie noch keinen privaten Schlüssel besitzen, können Sie hier auch einen e
</message>
</context>
<context>
- <name>RangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Edit note</source>
<translation>Notiz bearbeiten</translation>
</message>
- <message>
- <source>View event information on mouseover.</source>
- <translation>Information zu Ereignis anzeigen, wenn sich der Mauszeiger darüber befindet.</translation>
- </message>
- <message>
- <source>Close</source>
- <translation>Schließen</translation>
- </message>
</context>
<context>
<name>BoostSettingsPage</name>
diff --git a/share/qtcreator/translations/qtcreator_fr.ts b/share/qtcreator/translations/qtcreator_fr.ts
index 89692ac498b..0e64d081dc1 100644
--- a/share/qtcreator/translations/qtcreator_fr.ts
+++ b/share/qtcreator/translations/qtcreator_fr.ts
@@ -43079,11 +43079,7 @@ Pour compiler l&apos;observateur QML, allez à la page des versions de Qt, séle
</message>
</context>
<context>
- <name>RangeDetails</name>
- <message>
- <source>Duration</source>
- <translation type="obsolete">Durée</translation>
- </message>
+ <name>Tracing</name>
<message>
<source>Details</source>
<translation type="obsolete">Détails</translation>
@@ -45121,7 +45117,7 @@ Ces chemines sont utilisés en complément au répertoire courant pour basculer
</message>
</context>
<context>
- <name>SelectionRangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Selection</source>
<translation>Sélection</translation>
diff --git a/share/qtcreator/translations/qtcreator_hr.ts b/share/qtcreator/translations/qtcreator_hr.ts
index d781e55a778..a6c22c8b34b 100644
--- a/share/qtcreator/translations/qtcreator_hr.ts
+++ b/share/qtcreator/translations/qtcreator_hr.ts
@@ -388,7 +388,7 @@
</message>
</context>
<context>
- <name>ButtonsBar</name>
+ <name>Tracing</name>
<message>
<source>Jump to previous event.</source>
<translation>Prijeđi na prethodni događaj.</translation>
@@ -409,9 +409,6 @@
<source>View event information on mouseover.</source>
<translation>Prikaži podatke događaja kad se miš nalazi iznad.</translation>
</message>
-</context>
-<context>
- <name>CategoryLabel</name>
<message>
<source>Collapse category</source>
<translation>Sklopi kategoriju</translation>
@@ -420,9 +417,6 @@
<source>Expand category</source>
<translation>Rasklopi kategoriju</translation>
</message>
-</context>
-<context>
- <name>FlameGraphView</name>
<message>
<source>others</source>
<translation>ostali</translation>
@@ -439,16 +433,10 @@
<source>Visualize %1</source>
<translation>Vizualiziraj %1</translation>
</message>
-</context>
-<context>
- <name>RowLabel</name>
<message>
<source>[unknown]</source>
<translation>[nepoznato]</translation>
</message>
-</context>
-<context>
- <name>SelectionRangeDetails</name>
<message>
<source>Selection</source>
<translation>Odabir</translation>
@@ -12989,7 +12977,7 @@ For more information, see the &quot;Checking Code Syntax&quot; documentation.</s
</message>
</context>
<context>
- <name>Timeline::TimelineTraceManager</name>
+ <name>Tracing</name>
<message>
<source>Could not open %1 for writing.</source>
<translation type="unfinished"></translation>
diff --git a/share/qtcreator/translations/qtcreator_ja.ts b/share/qtcreator/translations/qtcreator_ja.ts
index 4f8219b670d..bbb6d238135 100644
--- a/share/qtcreator/translations/qtcreator_ja.ts
+++ b/share/qtcreator/translations/qtcreator_ja.ts
@@ -5953,7 +5953,7 @@ Add, modify, and remove document filters, which determine the documentation set
</message>
</context>
<context>
- <name>SelectionRangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Selection</source>
<translation>選択部分</translation>
@@ -35796,7 +35796,7 @@ kill しますか?</translation>
</message>
</context>
<context>
- <name>ButtonsBar</name>
+ <name>Tracing</name>
<message>
<source>Jump to previous event.</source>
<translation>前のイベントにジャンプします。</translation>
@@ -36734,7 +36734,7 @@ API バージョンが %1 以上の SDK をインストールしてください�
</message>
</context>
<context>
- <name>CategoryLabel</name>
+ <name>Tracing</name>
<message>
<source>Collapse category</source>
<translation>カテゴリを折りたたむ</translation>
@@ -36743,9 +36743,6 @@ API バージョンが %1 以上の SDK をインストールしてください�
<source>Expand category</source>
<translation>カテゴリを展開する</translation>
</message>
-</context>
-<context>
- <name>RowLabel</name>
<message>
<source>[unknown]</source>
<translation>[不明]</translation>
@@ -37591,7 +37588,7 @@ the program.</source>
</message>
</context>
<context>
- <name>FlameGraphView</name>
+ <name>Tracing</name>
<message>
<source>Details</source>
<translation>詳細</translation>
@@ -47887,15 +47884,7 @@ Output:
</message>
</context>
<context>
- <name>RangeDetails</name>
- <message>
- <source>View event information on mouseover.</source>
- <translation>マウスオーバー時にイベント情報を表示します。</translation>
- </message>
- <message>
- <source>Close</source>
- <translation>閉じる</translation>
- </message>
+ <name>Tracing</name>
</context>
<context>
<name>PerfProfilerFlameGraphView</name>
@@ -48370,7 +48359,7 @@ Output:
</message>
</context>
<context>
- <name>Timeline::TimelineTraceManager</name>
+ <name>Tracing</name>
<message>
<source>Could not open %1 for writing.</source>
<translation>書き込み用に %1 を開けません。</translation>
diff --git a/share/qtcreator/translations/qtcreator_pl.ts b/share/qtcreator/translations/qtcreator_pl.ts
index 8225bbfa50f..2aaee2fc266 100644
--- a/share/qtcreator/translations/qtcreator_pl.ts
+++ b/share/qtcreator/translations/qtcreator_pl.ts
@@ -20030,7 +20030,7 @@ Przedrostki te, w dodatku do nazwy bieżącego pliku, używane są do przełącz
</message>
</context>
<context>
- <name>SelectionRangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Selection</source>
<translation>Selekcja</translation>
@@ -30188,7 +30188,7 @@ Instalowanie lokalnych bibliotek Qt nie jest kompatybilne z Androidem 5.</transl
</message>
</context>
<context>
- <name>ButtonsBar</name>
+ <name>Tracing</name>
<message>
<source>Jump to previous event.</source>
<translation>Skocz do poprzedniego zdarzenia.</translation>
@@ -30209,9 +30209,6 @@ Instalowanie lokalnych bibliotek Qt nie jest kompatybilne z Androidem 5.</transl
<source>View event information on mouseover.</source>
<translation>Pokazuj informacje o zdarzeniach po najechaniu myszą.</translation>
</message>
-</context>
-<context>
- <name>CategoryLabel</name>
<message>
<source>Collapse category</source>
<translation>Zwiń kategorię</translation>
@@ -34008,7 +34005,7 @@ Pliki z katalogu źródłowego pakietu Android są kopiowane do katalogu budowan
</message>
</context>
<context>
- <name>RowLabel</name>
+ <name>Tracing</name>
<message>
<source>[unknown]</source>
<translation>[nieznany]</translation>
diff --git a/share/qtcreator/translations/qtcreator_ru.ts b/share/qtcreator/translations/qtcreator_ru.ts
index aa520f69199..62f34fb563c 100644
--- a/share/qtcreator/translations/qtcreator_ru.ts
+++ b/share/qtcreator/translations/qtcreator_ru.ts
@@ -6046,7 +6046,7 @@ For example, &quot;Revision: 15&quot; will leave the branch at revision 15.</sou
</message>
</context>
<context>
- <name>ButtonsBar</name>
+ <name>Tracing</name>
<message>
<source>Jump to previous event.</source>
<translation>Перейти к предыдущему событию.</translation>
@@ -7086,7 +7086,7 @@ For example, &quot;Revision: 15&quot; will leave the branch at revision 15.</sou
</message>
</context>
<context>
- <name>CategoryLabel</name>
+ <name>Tracing</name>
<message>
<source>Collapse category</source>
<translation>Категория сворачивания</translation>
@@ -20575,7 +20575,7 @@ will also disable the following plugins:
</message>
</context>
<context>
- <name>FlameGraphView</name>
+ <name>Tracing</name>
<message>
<source>others</source>
<translation>другие</translation>
@@ -44696,16 +44696,12 @@ For more details, see /etc/sysctl.d/10-ptrace.conf
</message>
</context>
<context>
- <name>RangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Edit note</source>
<translation>Изменить заметку</translation>
</message>
<message>
- <source>View event information on mouseover.</source>
- <translation>Показывать информацию о событии при наведении курсора.</translation>
- </message>
- <message>
<source>Close</source>
<translation>Закрыть</translation>
</message>
@@ -45785,7 +45781,7 @@ If you do not have a private key yet, you can also create one here.</source>
</message>
</context>
<context>
- <name>RowLabel</name>
+ <name>Tracing</name>
<message>
<source>[unknown]</source>
<translation>[неизвестная]</translation>
@@ -46550,7 +46546,7 @@ Row: %4, Column: %5
</message>
</context>
<context>
- <name>SelectionRangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Selection</source>
<translation>Выделение</translation>
@@ -46567,10 +46563,6 @@ Row: %4, Column: %5
<source>Duration</source>
<translation>Продолжительность</translation>
</message>
- <message>
- <source>Close</source>
- <translation>Закрыть</translation>
- </message>
</context>
<context>
<name>SerialTerminal::Internal::SerialControl</name>
@@ -50319,7 +50311,7 @@ Will not be applied to whitespace in comments and strings.</source>
</message>
</context>
<context>
- <name>Timeline::TimelineTraceManager</name>
+ <name>Tracing</name>
<message>
<source>Could not open %1 for writing.</source>
<translation>Не удалось открыть %1 для записи.</translation>
diff --git a/share/qtcreator/translations/qtcreator_uk.ts b/share/qtcreator/translations/qtcreator_uk.ts
index 3dd0a171914..087019b2257 100644
--- a/share/qtcreator/translations/qtcreator_uk.ts
+++ b/share/qtcreator/translations/qtcreator_uk.ts
@@ -20805,7 +20805,7 @@ For more details, see /etc/sysctl.d/10-ptrace.conf
</message>
</context>
<context>
- <name>RangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Duration:</source>
<translation type="vanished">Тривалість:</translation>
@@ -25898,7 +25898,7 @@ These prefixes are used in addition to current file name on Switch Header/Source
</message>
</context>
<context>
- <name>SelectionRangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Selection</source>
<translation>Виділення</translation>
@@ -43065,7 +43065,7 @@ This wizard will guide you through the essential steps to deploy a ready-to-go d
</message>
</context>
<context>
- <name>ButtonsBar</name>
+ <name>Tracing</name>
<message>
<source>Jump to previous event.</source>
<translation>Перейти до попередньої події.</translation>
@@ -43086,9 +43086,6 @@ This wizard will guide you through the essential steps to deploy a ready-to-go d
<source>View event information on mouseover.</source>
<translation type="unfinished"></translation>
</message>
-</context>
-<context>
- <name>CategoryLabel</name>
<message>
<source>&lt;bytecode&gt;</source>
<translation type="vanished">&lt;байт-код&gt;</translation>
@@ -48242,7 +48239,7 @@ Affected are breakpoints %1</source>
</message>
</context>
<context>
- <name>RowLabel</name>
+ <name>Tracing</name>
<message>
<source>[unknown]</source>
<translation>[невідомий]</translation>
@@ -52157,7 +52154,7 @@ the program.</source>
</message>
</context>
<context>
- <name>FlameGraphView</name>
+ <name>Tracing</name>
<message>
<source>Details</source>
<translation>Деталі</translation>
diff --git a/share/qtcreator/translations/qtcreator_zh_CN.ts b/share/qtcreator/translations/qtcreator_zh_CN.ts
index a19b741b931..3e281d9cb94 100644
--- a/share/qtcreator/translations/qtcreator_zh_CN.ts
+++ b/share/qtcreator/translations/qtcreator_zh_CN.ts
@@ -40634,7 +40634,7 @@ To compile QML Observer, go to the Qt Versions page, select the current Qt versi
</message>
</context>
<context>
- <name>RangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Duration</source>
<translation type="obsolete">持续时间</translation>
@@ -43393,7 +43393,7 @@ p, li { white-space: pre-wrap; }
</message>
</context>
<context>
- <name>SelectionRangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Selection</source>
<translation type="obsolete">选择</translation>
@@ -43402,10 +43402,6 @@ p, li { white-space: pre-wrap; }
<source>Start</source>
<translation type="obsolete">启动</translation>
</message>
- <message>
- <source>Duration</source>
- <translation type="obsolete">持续时间</translation>
- </message>
</context>
<context>
<name>Qnx</name>
diff --git a/share/qtcreator/translations/qtcreator_zh_TW.ts b/share/qtcreator/translations/qtcreator_zh_TW.ts
index 8884be2f76c..48437bf84c6 100644
--- a/share/qtcreator/translations/qtcreator_zh_TW.ts
+++ b/share/qtcreator/translations/qtcreator_zh_TW.ts
@@ -25330,7 +25330,7 @@ To compile QML Observer, go to the Qt Versions page, select the current Qt versi
</message>
</context>
<context>
- <name>RangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Duration:</source>
<translation>持續時間:</translation>
@@ -27260,7 +27260,7 @@ p, li { white-space: pre-wrap; }
</message>
</context>
<context>
- <name>SelectionRangeDetails</name>
+ <name>Tracing</name>
<message>
<source>Selection</source>
<translation>選擇</translation>
diff --git a/src/libs/tracing/qml/ButtonsBar.qml b/src/libs/tracing/qml/ButtonsBar.qml
index 8fd520505ec..a8dd5aaf084 100644
--- a/src/libs/tracing/qml/ButtonsBar.qml
+++ b/src/libs/tracing/qml/ButtonsBar.qml
@@ -47,7 +47,7 @@ ToolBar {
Layout.fillHeight: true
imageSource: "image://icons/prev"
- ToolTip.text: qsTr("Jump to previous event.")
+ ToolTip.text: qsTranslate("Tracing", "Jump to previous event.")
onClicked: buttons.jumpToPrev()
}
@@ -56,7 +56,7 @@ ToolBar {
Layout.fillHeight: true
imageSource: "image://icons/next"
- ToolTip.text: qsTr("Jump to next event.")
+ ToolTip.text: qsTranslate("Tracing", "Jump to next event.")
onClicked: buttons.jumpToNext()
}
@@ -65,7 +65,7 @@ ToolBar {
Layout.fillHeight: true
imageSource: "image://icons/zoom"
- ToolTip.text: qsTr("Show zoom slider.")
+ ToolTip.text: qsTranslate("Tracing", "Show zoom slider.")
checkable: true
checked: false
onCheckedChanged: buttons.zoomControlChanged()
@@ -76,7 +76,7 @@ ToolBar {
Layout.fillHeight: true
imageSource: "image://icons/" + (checked ? "rangeselected" : "rangeselection");
- ToolTip.text: qsTr("Select range.")
+ ToolTip.text: qsTranslate("Tracing", "Select range.")
checkable: true
checked: false
onCheckedChanged: buttons.rangeSelectChanged()
@@ -87,7 +87,7 @@ ToolBar {
Layout.fillHeight: true
imageSource: "image://icons/selectionmode"
- ToolTip.text: qsTr("View event information on mouseover.")
+ ToolTip.text: qsTranslate("Tracing", "View event information on mouseover.")
checkable: true
checked: false
onCheckedChanged: buttons.lockChanged()
diff --git a/src/libs/tracing/qml/CategoryLabel.qml b/src/libs/tracing/qml/CategoryLabel.qml
index 16cf63fb392..88dc5e89f46 100644
--- a/src/libs/tracing/qml/CategoryLabel.qml
+++ b/src/libs/tracing/qml/CategoryLabel.qml
@@ -163,7 +163,8 @@ Item {
implicitHeight: txt.height - 1
enabled: expanded || (model && !model.empty)
imageSource: expanded ? "image://icons/close_split" : "image://icons/split"
- ToolTip.text: expanded ? qsTr("Collapse category") : qsTr("Expand category")
+ ToolTip.text: expanded ? qsTranslate("Tracing", "Collapse category")
+ : qsTranslate("Tracing", "Expand category")
onClicked: model.expanded = !expanded
}
diff --git a/src/libs/tracing/qml/FlameGraphView.qml b/src/libs/tracing/qml/FlameGraphView.qml
index a670a079219..1a203f77ecf 100644
--- a/src/libs/tracing/qml/FlameGraphView.qml
+++ b/src/libs/tracing/qml/FlameGraphView.qml
@@ -41,7 +41,7 @@ ScrollView {
property var details: function(flameGraph) { return []; }
property var summary: function(attached) {
if (!attached.dataValid)
- return qsTr("others");
+ return qsTranslate("Tracing", "others");
return attached.data(summaryRole) + " (" + percent(sizeRole, attached) + "%)";
}
@@ -230,7 +230,8 @@ ScrollView {
// Functions, not properties to limit the initial overhead when creating the nodes,
// and because FlameGraph.data(...) cannot be notified anyway.
function title() {
- return FlameGraph.data(root.detailsTitleRole) || qsTr("unknown");
+ return FlameGraph.data(root.detailsTitleRole)
+ || qsTranslate("Tracing", "unknown");
}
function note() {
@@ -275,7 +276,7 @@ ScrollView {
if (currentNode)
return currentNode.title();
else if (root.model === null || root.model.rowCount() === 0)
- return qsTr("No data available");
+ return qsTranslate("Tracing", "No data available");
else
return "";
}
diff --git a/src/libs/tracing/qml/RangeDetails.qml b/src/libs/tracing/qml/RangeDetails.qml
index c4c99c44873..14d6aa9e7af 100644
--- a/src/libs/tracing/qml/RangeDetails.qml
+++ b/src/libs/tracing/qml/RangeDetails.qml
@@ -88,7 +88,7 @@ Item {
implicitHeight: typeTitle.height
visible: !rangeDetails.noteReadonly
onClicked: noteEdit.focus = true
- ToolTip.text: qsTr("Edit note")
+ ToolTip.text: qsTranslate("Tracing", "Edit note")
}
ImageToolButton {
@@ -98,7 +98,7 @@ Item {
anchors.right: closeIcon.left
implicitHeight: typeTitle.height
onClicked: locked = !locked
- ToolTip.text: qsTr("View event information on mouseover.")
+ ToolTip.text: qsTranslate("Tracing", "View event information on mouseover.")
}
ImageToolButton {
@@ -108,7 +108,7 @@ Item {
implicitHeight: typeTitle.height
imageSource: "image://icons/close_window"
onClicked: rangeDetails.clearSelection()
- ToolTip.text: qsTr("Close")
+ ToolTip.text: qsTranslate("Tracing", "Close")
}
}
diff --git a/src/libs/tracing/qml/RowLabel.qml b/src/libs/tracing/qml/RowLabel.qml
index 53ca5c6eaf2..37cab676619 100644
--- a/src/libs/tracing/qml/RowLabel.qml
+++ b/src/libs/tracing/qml/RowLabel.qml
@@ -14,7 +14,8 @@ Button {
signal selectBySelectionId()
signal setRowHeight(int newHeight)
- property string labelText: label.description ? label.description : qsTr("[unknown]")
+ property string labelText: label.description ? label.description
+ : qsTranslate("Tracing", "[unknown]")
onPressed: selectBySelectionId();
ToolTip.text: labelText + (label.displayName ? (" (" + label.displayName + ")") : "")
diff --git a/src/libs/tracing/qml/SelectionRangeDetails.qml b/src/libs/tracing/qml/SelectionRangeDetails.qml
index c77c901c16f..e837135121b 100644
--- a/src/libs/tracing/qml/SelectionRangeDetails.qml
+++ b/src/libs/tracing/qml/SelectionRangeDetails.qml
@@ -54,7 +54,7 @@ Item {
//title
TimelineText {
id: typeTitle
- text: " "+qsTr("Selection")
+ text: " "+qsTranslate("Tracing", "Selection")
font.bold: true
height: 20
verticalAlignment: Text.AlignVCenter
@@ -78,11 +78,11 @@ Item {
Repeater {
id: details
property var contents: [
- qsTr("Start") + ":",
+ qsTranslate("Tracing", "Start") + ":",
TimeFormatter.format(startTime, referenceDuration),
- (qsTr("End") + ":"),
+ (qsTranslate("Tracing", "End") + ":"),
TimeFormatter.format(endTime, referenceDuration),
- (qsTr("Duration") + ":"),
+ (qsTranslate("Tracing", "Duration") + ":"),
TimeFormatter.format(duration, referenceDuration)
]
@@ -112,6 +112,6 @@ Item {
anchors.top: selectionRangeDetails.top
implicitHeight: typeTitle.height
onClicked: selectionRangeDetails.close()
- ToolTip.text: qsTr("Close")
+ ToolTip.text: qsTranslate("Tracing", "Close")
}
}
diff --git a/src/libs/tracing/timelinetracemanager.cpp b/src/libs/tracing/timelinetracemanager.cpp
index 2c0b45849be..293bcf3c9ae 100644
--- a/src/libs/tracing/timelinetracemanager.cpp
+++ b/src/libs/tracing/timelinetracemanager.cpp
@@ -2,8 +2,9 @@
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0+ OR GPL-3.0 WITH Qt-GPL-exception-1.0
#include "timelinenotesmodel.h"
-#include "timelinetracemanager.h"
#include "timelinetracefile.h"
+#include "timelinetracemanager.h"
+#include "tracingtr.h"
#include <utils/qtcassert.h>
#include <utils/temporaryfile.h>
@@ -229,7 +230,7 @@ QFuture<void> TimelineTraceManager::save(const QString &filename)
if (file.open(QIODevice::WriteOnly))
writer->save(&file);
else
- writer->fail(tr("Could not open %1 for writing.").arg(filename));
+ writer->fail(Tr::tr("Could not open %1 for writing.").arg(filename));
if (future.isCanceled())
file.remove();
@@ -255,7 +256,7 @@ QFuture<void> TimelineTraceManager::load(const QString &filename)
if (file.open(QIODevice::ReadOnly))
reader->load(&file);
else
- reader->fail(tr("Could not open %1 for reading.").arg(filename));
+ reader->fail(Tr::tr("Could not open %1 for reading.").arg(filename));
reader->deleteLater();
});
@@ -374,8 +375,8 @@ void TimelineTraceManager::restrictByFilter(TraceEventFilter filter)
finalize();
}, [this](const QString &message) {
if (!message.isEmpty()) {
- emit error(tr("Could not re-read events from temporary trace file: %1\n"
- "The trace data is lost.").arg(message));
+ emit error(Tr::tr("Could not re-read events from temporary trace file: %1\n"
+ "The trace data is lost.").arg(message));
}
clearAll();
}, future);
diff --git a/src/libs/tracing/tracingtr.h b/src/libs/tracing/tracingtr.h
index 12da89810e7..05e4bd6a537 100644
--- a/src/libs/tracing/tracingtr.h
+++ b/src/libs/tracing/tracingtr.h
@@ -5,7 +5,7 @@
#include <QCoreApplication>
-namespace Tracing {
+namespace Timeline {
struct Tr
{