Boot2Qt: Tr::tr

Interestingly, the contexts were predominantly Qdb::*, standardize
on that. Long term we might collapse RemoteLinux descendants anyway.

Change-Id: Id7009ee6b662d6c29f98e3809619b604aeeea7d9
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
This commit is contained in:
hjk
2023-01-18 08:42:48 +01:00
parent 88131d4c93
commit 46e660c646
32 changed files with 141 additions and 321 deletions

View File

@@ -44423,7 +44423,7 @@ Doppelklicken Sie einen Eintrag um ihn zu ändern.</translation>
</message> </message>
</context> </context>
<context> <context>
<name>Qdb::Internal::QdbDevice</name> <name>::Qdb</name>
<message> <message>
<source>Starting command &quot;%1&quot; on device &quot;%2&quot;.</source> <source>Starting command &quot;%1&quot; on device &quot;%2&quot;.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -44488,9 +44488,6 @@ Doppelklicken Sie einen Eintrag um ihn zu ändern.</translation>
<source>Boot2Qt Network Device Setup</source> <source>Boot2Qt Network Device Setup</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbMakeDefaultAppService</name>
<message> <message>
<source>Remote process failed: %1</source> <source>Remote process failed: %1</source>
<translation>Der entfernte Prozess schlug fehl: %1</translation> <translation>Der entfernte Prozess schlug fehl: %1</translation>
@@ -44503,9 +44500,6 @@ Doppelklicken Sie einen Eintrag um ihn zu ändern.</translation>
<source>Reset the default application.</source> <source>Reset the default application.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbRunConfiguration</name>
<message> <message>
<source>Full command line:</source> <source>Full command line:</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -50839,7 +50833,7 @@ in &quot;%2&quot; aus.
</message> </message>
</context> </context>
<context> <context>
<name>Qdb::Internal::DeviceDetector</name> <name>::Qdb</name>
<message> <message>
<source>Device &quot;%1&quot; %2</source> <source>Device &quot;%1&quot; %2</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -50852,16 +50846,10 @@ in &quot;%2&quot; aus.
<source>Device detection error: %1</source> <source>Device detection error: %1</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbDeviceTracker</name>
<message> <message>
<source>Shutting down device discovery due to unexpected response: %1</source> <source>Shutting down device discovery due to unexpected response: %1</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbMessageTracker</name>
<message> <message>
<source>Shutting down message reception due to unexpected response: %1</source> <source>Shutting down message reception due to unexpected response: %1</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -50870,9 +50858,6 @@ in &quot;%2&quot; aus.
<source>QDB message: %1</source> <source>QDB message: %1</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbWatcher</name>
<message> <message>
<source>Unexpected QLocalSocket error: %1</source> <source>Unexpected QLocalSocket error: %1</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -50901,16 +50886,10 @@ in &quot;%2&quot; aus.
<source>Starting QDB host server.</source> <source>Starting QDB host server.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbDeployConfiguration</name>
<message> <message>
<source>Deploy to Boot2Qt target</source> <source>Deploy to Boot2Qt target</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbMakeDefaultAppStep</name>
<message> <message>
<source>Set this application to start by default</source> <source>Set this application to start by default</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -50923,9 +50902,6 @@ in &quot;%2&quot; aus.
<source>Change default application</source> <source>Change default application</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb</name>
<message> <message>
<source>Flash wizard &quot;%1&quot; failed to start.</source> <source>Flash wizard &quot;%1&quot; failed to start.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -50938,17 +50914,11 @@ in &quot;%2&quot; aus.
<source>Flash Boot to Qt Device</source> <source>Flash Boot to Qt Device</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>QtVersion</name>
<message> <message>
<source>Boot2Qt</source> <source>Boot2Qt</source>
<comment>Qt version is used for Boot2Qt development</comment> <comment>Qt version is used for Boot2Qt development</comment>
<translation type="unfinished">Boot2Qt</translation> <translation type="unfinished">Boot2Qt</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbStopApplicationService</name>
<message> <message>
<source>Could not check and possibly stop running application.</source> <source>Could not check and possibly stop running application.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -50961,16 +50931,10 @@ in &quot;%2&quot; aus.
<source>Stopped the running application.</source> <source>Stopped the running application.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbStopApplicationStep</name>
<message> <message>
<source>Stop already running application</source> <source>Stop already running application</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>::Boot2Qt</name>
<message> <message>
<source>Boot2Qt: %1</source> <source>Boot2Qt: %1</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>

View File

@@ -45125,7 +45125,7 @@ The name of the release build configuration created by default for a qmake proje
</message> </message>
</context> </context>
<context> <context>
<name>Qdb::Internal::DeviceDetector</name> <name>::Qdb</name>
<message> <message>
<source>Device &quot;%1&quot; %2</source> <source>Device &quot;%1&quot; %2</source>
<translation> &quot;%1&quot; %2</translation> <translation> &quot;%1&quot; %2</translation>
@@ -45138,16 +45138,10 @@ The name of the release build configuration created by default for a qmake proje
<source>Device detection error: %1</source> <source>Device detection error: %1</source>
<translation>: %1</translation> <translation>: %1</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbDeviceTracker</name>
<message> <message>
<source>Shutting down device discovery due to unexpected response: %1</source> <source>Shutting down device discovery due to unexpected response: %1</source>
<translation>: %1</translation> <translation>: %1</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbMessageTracker</name>
<message> <message>
<source>Shutting down message reception due to unexpected response: %1</source> <source>Shutting down message reception due to unexpected response: %1</source>
<translation>: %1</translation> <translation>: %1</translation>
@@ -45156,9 +45150,6 @@ The name of the release build configuration created by default for a qmake proje
<source>QDB message: %1</source> <source>QDB message: %1</source>
<translation>QDB : %1</translation> <translation>QDB : %1</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbWatcher</name>
<message> <message>
<source>Unexpected QLocalSocket error: %1</source> <source>Unexpected QLocalSocket error: %1</source>
<translation> QLocalSocket : %1</translation> <translation> QLocalSocket : %1</translation>
@@ -45187,16 +45178,10 @@ The name of the release build configuration created by default for a qmake proje
<source>Starting QDB host server.</source> <source>Starting QDB host server.</source>
<translation>GDB </translation> <translation>GDB </translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbDeployConfiguration</name>
<message> <message>
<source>Deploy to Boot2Qt target</source> <source>Deploy to Boot2Qt target</source>
<translation>Boot2Qt </translation> <translation>Boot2Qt </translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbDevice</name>
<message> <message>
<source>Starting command &quot;%1&quot; on device &quot;%2&quot;.</source> <source>Starting command &quot;%1&quot; on device &quot;%2&quot;.</source>
<translation> &quot;%2&quot; &quot;%1&quot; </translation> <translation> &quot;%2&quot; &quot;%1&quot; </translation>
@@ -45209,9 +45194,6 @@ The name of the release build configuration created by default for a qmake proje
<source>Device name:</source> <source>Device name:</source>
<translation type="unfinished">:</translation> <translation type="unfinished">:</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbMakeDefaultAppService</name>
<message> <message>
<source>Remote process failed: %1</source> <source>Remote process failed: %1</source>
<translation>: %1</translation> <translation>: %1</translation>
@@ -45224,9 +45206,6 @@ The name of the release build configuration created by default for a qmake proje
<source>Reset the default application.</source> <source>Reset the default application.</source>
<translation></translation> <translation></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbMakeDefaultAppStep</name>
<message> <message>
<source>Set this application to start by default</source> <source>Set this application to start by default</source>
<translation></translation> <translation></translation>
@@ -45239,9 +45218,6 @@ The name of the release build configuration created by default for a qmake proje
<source>Change default application</source> <source>Change default application</source>
<translation></translation> <translation></translation>
</message> </message>
</context>
<context>
<name>Qdb</name>
<message> <message>
<source>Flash wizard &quot;%1&quot; failed to start.</source> <source>Flash wizard &quot;%1&quot; failed to start.</source>
<translation>Flash &quot;%1&quot; </translation> <translation>Flash &quot;%1&quot; </translation>
@@ -45250,9 +45226,6 @@ The name of the release build configuration created by default for a qmake proje
<source>Flash wizard executable &quot;%1&quot; not found.</source> <source>Flash wizard executable &quot;%1&quot; not found.</source>
<translation>Flash &quot;%1&quot; </translation> <translation>Flash &quot;%1&quot; </translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbRunConfiguration</name>
<message> <message>
<source>Executable on device:</source> <source>Executable on device:</source>
<translation>:</translation> <translation>:</translation>
@@ -45265,9 +45238,6 @@ The name of the release build configuration created by default for a qmake proje
<source>Executable on host:</source> <source>Executable on host:</source>
<translation>:</translation> <translation>:</translation>
</message> </message>
</context>
<context>
<name>::Boot2Qt</name>
<message> <message>
<source>Boot2Qt: %1</source> <source>Boot2Qt: %1</source>
<translation>Boot2Qt: %1</translation> <translation>Boot2Qt: %1</translation>

View File

@@ -5195,7 +5195,7 @@ For example, &quot;Revision: 15&quot; will leave the branch at revision 15.</sou
</message> </message>
</context> </context>
<context> <context>
<name>::Boot2Qt</name> <name>::Qdb</name>
<message> <message>
<source>Boot2Qt: %1</source> <source>Boot2Qt: %1</source>
<translation>Boot2Qt: %1</translation> <translation>Boot2Qt: %1</translation>
@@ -34129,7 +34129,7 @@ The affected files are:
</message> </message>
</context> </context>
<context> <context>
<name>Qdb</name> <name>::Qdb</name>
<message> <message>
<source>Flash wizard &quot;%1&quot; failed to start.</source> <source>Flash wizard &quot;%1&quot; failed to start.</source>
<translation>Не удалось запустить программатор «%1».</translation> <translation>Не удалось запустить программатор «%1».</translation>
@@ -34142,9 +34142,6 @@ The affected files are:
<source>Flash Boot to Qt Device</source> <source>Flash Boot to Qt Device</source>
<translation>Запрограммировать устройство Boot to Qt</translation> <translation>Запрограммировать устройство Boot to Qt</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::DeviceDetector</name>
<message> <message>
<source>Device &quot;%1&quot; %2</source> <source>Device &quot;%1&quot; %2</source>
<translation>Устройство «%1» %2</translation> <translation>Устройство «%1» %2</translation>
@@ -34157,16 +34154,10 @@ The affected files are:
<source>Device detection error: %1</source> <source>Device detection error: %1</source>
<translation>Ошибка определения устройства: %1</translation> <translation>Ошибка определения устройства: %1</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbDeployConfiguration</name>
<message> <message>
<source>Deploy to Boot2Qt target</source> <source>Deploy to Boot2Qt target</source>
<translation>Развёртывание на Boot2Qt</translation> <translation>Развёртывание на Boot2Qt</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbDevice</name>
<message> <message>
<source>Starting command &quot;%1&quot; on device &quot;%2&quot;.</source> <source>Starting command &quot;%1&quot; on device &quot;%2&quot;.</source>
<translation>Запуск команды «%1» на устройстве «%2».</translation> <translation>Запуск команды «%1» на устройстве «%2».</translation>
@@ -34231,16 +34222,10 @@ The affected files are:
<source>Boot2Qt Network Device Setup</source> <source>Boot2Qt Network Device Setup</source>
<translation>Настройка сетевого устройства Boot2Qt</translation> <translation>Настройка сетевого устройства Boot2Qt</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbDeviceTracker</name>
<message> <message>
<source>Shutting down device discovery due to unexpected response: %1</source> <source>Shutting down device discovery due to unexpected response: %1</source>
<translation>Завершение определения устройств из-за неожиданного ответа: %1</translation> <translation>Завершение определения устройств из-за неожиданного ответа: %1</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbMakeDefaultAppService</name>
<message> <message>
<source>Remote process failed: %1</source> <source>Remote process failed: %1</source>
<translation>Ошибка внешнего процесса: %1</translation> <translation>Ошибка внешнего процесса: %1</translation>
@@ -34253,9 +34238,6 @@ The affected files are:
<source>Reset the default application.</source> <source>Reset the default application.</source>
<translation>Сбросить приложение по умолчанию.</translation> <translation>Сбросить приложение по умолчанию.</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbMakeDefaultAppStep</name>
<message> <message>
<source>Change default application</source> <source>Change default application</source>
<translation>Сменить приложение по умолчанию</translation> <translation>Сменить приложение по умолчанию</translation>
@@ -34268,9 +34250,6 @@ The affected files are:
<source>Reset default application</source> <source>Reset default application</source>
<translation>Сбросить приложение по умолчанию</translation> <translation>Сбросить приложение по умолчанию</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbMessageTracker</name>
<message> <message>
<source>Shutting down message reception due to unexpected response: %1</source> <source>Shutting down message reception due to unexpected response: %1</source>
<translation>Завершение приёма сообщения из-за неожиданного ответа: %1</translation> <translation>Завершение приёма сообщения из-за неожиданного ответа: %1</translation>
@@ -34279,9 +34258,6 @@ The affected files are:
<source>QDB message: %1</source> <source>QDB message: %1</source>
<translation>Сообщение QDB: %1</translation> <translation>Сообщение QDB: %1</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbRunConfiguration</name>
<message> <message>
<source>Full command line:</source> <source>Full command line:</source>
<translation>Полная командная строка:</translation> <translation>Полная командная строка:</translation>
@@ -34306,9 +34282,6 @@ The affected files are:
<source>The remote executable must be set in order to run on a Boot2Qt device.</source> <source>The remote executable must be set in order to run on a Boot2Qt device.</source>
<translation>Для запуска на устройстве Boot2Qt внешнего приложения, его необходимо задать.</translation> <translation>Для запуска на устройстве Boot2Qt внешнего приложения, его необходимо задать.</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbStopApplicationService</name>
<message> <message>
<source>Could not check and possibly stop running application.</source> <source>Could not check and possibly stop running application.</source>
<translation>Не удалось проверить и, вероятно, остановить работающее приложение.</translation> <translation>Не удалось проверить и, вероятно, остановить работающее приложение.</translation>
@@ -34321,16 +34294,10 @@ The affected files are:
<source>Stopped the running application.</source> <source>Stopped the running application.</source>
<translation>Работающее приложение остановлено.</translation> <translation>Работающее приложение остановлено.</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbStopApplicationStep</name>
<message> <message>
<source>Stop already running application</source> <source>Stop already running application</source>
<translation>Остановка работающего приложения</translation> <translation>Остановка работающего приложения</translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbWatcher</name>
<message> <message>
<source>Unexpected QLocalSocket error: %1</source> <source>Unexpected QLocalSocket error: %1</source>
<translation>Неожиданная ошибка QLocalSocket: %1</translation> <translation>Неожиданная ошибка QLocalSocket: %1</translation>

View File

@@ -5336,7 +5336,7 @@ Local pulls are not applied to the master branch.</source>
</message> </message>
</context> </context>
<context> <context>
<name>::Boot2Qt</name> <name>::Qdb</name>
<message> <message>
<source>Boot2Qt: %1</source> <source>Boot2Qt: %1</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -31744,7 +31744,7 @@ The affected files are:
</message> </message>
</context> </context>
<context> <context>
<name>Qdb</name> <name>::Qdb</name>
<message> <message>
<source>Flash wizard &quot;%1&quot; failed to start.</source> <source>Flash wizard &quot;%1&quot; failed to start.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -31757,9 +31757,6 @@ The affected files are:
<source>Flash Boot to Qt Device</source> <source>Flash Boot to Qt Device</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::DeviceDetector</name>
<message> <message>
<source>Device &quot;%1&quot; %2</source> <source>Device &quot;%1&quot; %2</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -31772,16 +31769,10 @@ The affected files are:
<source>Device detection error: %1</source> <source>Device detection error: %1</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbDeployConfiguration</name>
<message> <message>
<source>Deploy to Boot2Qt target</source> <source>Deploy to Boot2Qt target</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbDevice</name>
<message> <message>
<source>Starting command &quot;%1&quot; on device &quot;%2&quot;.</source> <source>Starting command &quot;%1&quot; on device &quot;%2&quot;.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -31846,16 +31837,10 @@ The affected files are:
<source>Boot2Qt Network Device Setup</source> <source>Boot2Qt Network Device Setup</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbDeviceTracker</name>
<message> <message>
<source>Shutting down device discovery due to unexpected response: %1</source> <source>Shutting down device discovery due to unexpected response: %1</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbMakeDefaultAppService</name>
<message> <message>
<source>Remote process failed: %1</source> <source>Remote process failed: %1</source>
<translation type="unfinished">:%1</translation> <translation type="unfinished">:%1</translation>
@@ -31868,9 +31853,6 @@ The affected files are:
<source>Reset the default application.</source> <source>Reset the default application.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbMakeDefaultAppStep</name>
<message> <message>
<source>Set this application to start by default</source> <source>Set this application to start by default</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -31883,9 +31865,6 @@ The affected files are:
<source>Change default application</source> <source>Change default application</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbMessageTracker</name>
<message> <message>
<source>Shutting down message reception due to unexpected response: %1</source> <source>Shutting down message reception due to unexpected response: %1</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -31894,9 +31873,6 @@ The affected files are:
<source>QDB message: %1</source> <source>QDB message: %1</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbRunConfiguration</name>
<message> <message>
<source>Full command line:</source> <source>Full command line:</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -31921,9 +31897,6 @@ The affected files are:
<source>The remote executable must be set in order to run on a Boot2Qt device.</source> <source>The remote executable must be set in order to run on a Boot2Qt device.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbStopApplicationService</name>
<message> <message>
<source>Could not check and possibly stop running application.</source> <source>Could not check and possibly stop running application.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -31936,16 +31909,10 @@ The affected files are:
<source>Stopped the running application.</source> <source>Stopped the running application.</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbStopApplicationStep</name>
<message> <message>
<source>Stop already running application</source> <source>Stop already running application</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
</context>
<context>
<name>Qdb::Internal::QdbWatcher</name>
<message> <message>
<source>Unexpected QLocalSocket error: %1</source> <source>Unexpected QLocalSocket error: %1</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
@@ -39262,7 +39229,7 @@ For more details, see /etc/sysctl.d/10-ptrace.conf
</message> </message>
</context> </context>
<context> <context>
<name>QtVersion</name> <name>::Qdb</name>
<message> <message>
<source>Boot2Qt</source> <source>Boot2Qt</source>
<comment>Qt version is used for Boot2Qt development</comment> <comment>Qt version is used for Boot2Qt development</comment>

View File

@@ -14,6 +14,7 @@ add_qtc_plugin(Boot2Qt
qdbqtversion.cpp qdbqtversion.h qdbqtversion.cpp qdbqtversion.h
qdbrunconfiguration.cpp qdbrunconfiguration.h qdbrunconfiguration.cpp qdbrunconfiguration.h
qdbstopapplicationstep.cpp qdbstopapplicationstep.h qdbstopapplicationstep.cpp qdbstopapplicationstep.h
qdbtr.h
qdbutils.cpp qdbutils.h qdbutils.cpp qdbutils.h
) )

View File

@@ -33,6 +33,7 @@ QtcPlugin {
"qdbplugin.h", "qdbplugin.h",
"qdbstopapplicationstep.cpp", "qdbstopapplicationstep.cpp",
"qdbstopapplicationstep.h", "qdbstopapplicationstep.h",
"qdbtr.h",
"qdbqtversion.cpp", "qdbqtversion.cpp",
"qdbqtversion.h", "qdbqtversion.h",
"qdbrunconfiguration.cpp", "qdbrunconfiguration.cpp",

View File

@@ -3,11 +3,13 @@
#include "devicedetector.h" #include "devicedetector.h"
#include "../qdbutils.h"
#include "../qdbconstants.h" #include "../qdbconstants.h"
#include "../qdbdevice.h" #include "../qdbdevice.h"
#include "../qdbtr.h"
#include "../qdbutils.h"
#include <projectexplorer/devicesupport/devicemanager.h> #include <projectexplorer/devicesupport/devicemanager.h>
#include <utils/qtcassert.h> #include <utils/qtcassert.h>
#include <QHash> #include <QHash>
@@ -15,8 +17,7 @@
using namespace ProjectExplorer; using namespace ProjectExplorer;
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
static bool isAutodetectedQdbDevice(const IDevice::ConstPtr &device) static bool isAutodetectedQdbDevice(const IDevice::ConstPtr &device)
{ {
@@ -74,11 +75,11 @@ void DeviceDetector::handleDeviceEvent(QdbDeviceTracker::DeviceEventType eventTy
} }
const Utils::Id deviceId = Constants::QdbHardwareDevicePrefix.withSuffix(':' + serial); const Utils::Id deviceId = Constants::QdbHardwareDevicePrefix.withSuffix(':' + serial);
const auto messagePrefix = tr("Device \"%1\" %2").arg(serial); const auto messagePrefix = Tr::tr("Device \"%1\" %2").arg(serial);
DeviceManager * const dm = DeviceManager::instance(); DeviceManager * const dm = DeviceManager::instance();
if (eventType == QdbDeviceTracker::NewDevice) { if (eventType == QdbDeviceTracker::NewDevice) {
const QString name = tr("Qt Debug Bridge device %1").arg(serial); const QString name = Tr::tr("Qt Debug Bridge device %1").arg(serial);
QdbDevice::Ptr device = QdbDevice::create(); QdbDevice::Ptr device = QdbDevice::create();
device->setupId(IDevice::AutoDetected, deviceId); device->setupId(IDevice::AutoDetected, deviceId);
device->setDisplayName(name); device->setDisplayName(name);
@@ -109,7 +110,7 @@ void DeviceDetector::handleDeviceEvent(QdbDeviceTracker::DeviceEventType eventTy
void DeviceDetector::handleTrackerError(const QString &errorMessage) void DeviceDetector::handleTrackerError(const QString &errorMessage)
{ {
showMessage(tr("Device detection error: %1").arg(errorMessage), true); showMessage(Tr::tr("Device detection error: %1").arg(errorMessage), true);
stop(); stop();
} }
@@ -123,5 +124,4 @@ void DeviceDetector::resetDevices()
} }
} }
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -3,12 +3,10 @@
#pragma once #pragma once
#include "../qdbdevice.h"
#include "qdbdevicetracker.h" #include "qdbdevicetracker.h"
#include "qdbmessagetracker.h" #include "qdbmessagetracker.h"
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
class DeviceDetector : public QObject class DeviceDetector : public QObject
{ {
@@ -34,5 +32,4 @@ private:
QdbMessageTracker m_messageTracker; QdbMessageTracker m_messageTracker;
}; };
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -2,16 +2,15 @@
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
#include "qdbdevicetracker.h" #include "qdbdevicetracker.h"
#include "qdbwatcher.h"
#include "../qdbutils.h"
#include "hostmessages.h" #include "hostmessages.h"
#include "qdbwatcher.h"
#include "../qdbtr.h"
#include <QJsonDocument> #include <QJsonDocument>
#include <QJsonObject> #include <QJsonObject>
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
QdbDeviceTracker::QdbDeviceTracker(QObject *parent) QdbDeviceTracker::QdbDeviceTracker(QObject *parent)
: QObject(parent) : QObject(parent)
@@ -36,7 +35,7 @@ void QdbDeviceTracker::handleWatchMessage(const QJsonDocument &document)
if (type != ResponseType::NewDevice && type != ResponseType::DisconnectedDevice) { if (type != ResponseType::NewDevice && type != ResponseType::DisconnectedDevice) {
stop(); stop();
const QString message = const QString message =
tr("Shutting down device discovery due to unexpected response: %1"); Tr::tr("Shutting down device discovery due to unexpected response: %1");
emit trackerError(message.arg(QString::fromUtf8(document.toJson()))); emit trackerError(message.arg(QString::fromUtf8(document.toJson())));
return; return;
} }
@@ -61,5 +60,4 @@ void QdbDeviceTracker::handleWatchMessage(const QJsonDocument &document)
emit deviceEvent(eventType, info); emit deviceEvent(eventType, info);
} }
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -2,11 +2,11 @@
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
#pragma once #pragma once
#include <QObject> #include <QObject>
#include <QMap> #include <QMap>
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
class QdbWatcher; class QdbWatcher;
@@ -35,5 +35,4 @@ private:
QdbWatcher *m_qdbWatcher = nullptr; QdbWatcher *m_qdbWatcher = nullptr;
}; };
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -4,6 +4,7 @@
#include "qdbmessagetracker.h" #include "qdbmessagetracker.h"
#include "qdbwatcher.h" #include "qdbwatcher.h"
#include "../qdbtr.h"
#include "../qdbutils.h" #include "../qdbutils.h"
#include "hostmessages.h" #include "hostmessages.h"
@@ -11,8 +12,7 @@
#include <QJsonObject> #include <QJsonObject>
#include <QJsonArray> #include <QJsonArray>
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
QdbMessageTracker::QdbMessageTracker(QObject *parent) QdbMessageTracker::QdbMessageTracker(QObject *parent)
: QObject(parent) : QObject(parent)
@@ -39,7 +39,7 @@ void QdbMessageTracker::handleWatchMessage(const QJsonDocument &document)
if (type != ResponseType::Messages) { if (type != ResponseType::Messages) {
stop(); stop();
const QString message = const QString message =
tr("Shutting down message reception due to unexpected response: %1"); Tr::tr("Shutting down message reception due to unexpected response: %1");
emit trackerError(message.arg(QString::fromUtf8(document.toJson()))); emit trackerError(message.arg(QString::fromUtf8(document.toJson())));
return; return;
} }
@@ -58,9 +58,8 @@ void QdbMessageTracker::handleWatchMessage(const QJsonDocument &document)
} }
m_messageCache.append(message); m_messageCache.append(message);
showMessage(tr("QDB message: %1").arg(message), true); showMessage(Tr::tr("QDB message: %1").arg(message), true);
} }
} }
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -2,11 +2,11 @@
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
#pragma once #pragma once
#include <QObject> #include <QObject>
#include <QContiguousCache> #include <QContiguousCache>
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
class QdbWatcher; class QdbWatcher;
@@ -29,5 +29,4 @@ private:
QContiguousCache<QString> m_messageCache = QContiguousCache<QString>(10); QContiguousCache<QString> m_messageCache = QContiguousCache<QString>(10);
}; };
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -3,17 +3,17 @@
#include "qdbwatcher.h" #include "qdbwatcher.h"
#include "../qdbutils.h"
#include "hostmessages.h" #include "hostmessages.h"
#include "../qdbtr.h"
#include "../qdbutils.h"
#include <utils/fileutils.h> #include <utils/filepath.h>
#include <utils/qtcprocess.h> #include <utils/qtcprocess.h>
#include <QFile> #include <QFile>
#include <QTimer> #include <QTimer>
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
const int startupDelay = 500; // time in ms to wait for host server startup before retrying const int startupDelay = 500; // time in ms to wait for host server startup before retrying
const QString qdbSocketName = "qdb.socket"; const QString qdbSocketName = "qdb.socket";
@@ -79,14 +79,14 @@ void QdbWatcher::handleWatchError(QLocalSocket::LocalSocketError error)
if (error != QLocalSocket::ServerNotFoundError if (error != QLocalSocket::ServerNotFoundError
&& error != QLocalSocket::ConnectionRefusedError) { && error != QLocalSocket::ConnectionRefusedError) {
stop(); stop();
emit watcherError(tr("Unexpected QLocalSocket error: %1") emit watcherError(Tr::tr("Unexpected QLocalSocket error: %1")
.arg(m_socket->errorString())); .arg(m_socket->errorString()));
return; return;
} }
if (m_retried) { if (m_retried) {
stop(); stop();
emit watcherError(tr("Could not connect to QDB host server even after trying to start it.")); emit watcherError(Tr::tr("Could not connect to QDB host server even after trying to start it."));
return; return;
} }
retry(); retry();
@@ -99,7 +99,7 @@ void QdbWatcher::handleWatchMessage()
const auto document = QJsonDocument::fromJson(responseBytes); const auto document = QJsonDocument::fromJson(responseBytes);
if (document.isNull()) { if (document.isNull()) {
const QString message = const QString message =
tr("Invalid JSON response received from QDB server: %1"); Tr::tr("Invalid JSON response received from QDB server: %1");
emit watcherError(message.arg(QString::fromUtf8(responseBytes))); emit watcherError(message.arg(QString::fromUtf8(responseBytes)));
return; return;
} }
@@ -112,16 +112,16 @@ void QdbWatcher::forkHostServer()
Utils::FilePath qdbFilePath = findTool(QdbTool::Qdb); Utils::FilePath qdbFilePath = findTool(QdbTool::Qdb);
QFile executable(qdbFilePath.toString()); QFile executable(qdbFilePath.toString());
if (!executable.exists()) { if (!executable.exists()) {
const QString message = tr("Could not find QDB host server executable. " const QString message = Tr::tr("Could not find QDB host server executable. "
"You can set the location with environment variable %1.") "You can set the location with environment variable %1.")
.arg(overridingEnvironmentVariable(QdbTool::Qdb)); .arg(overridingEnvironmentVariable(QdbTool::Qdb));
showMessage(message, true); showMessage(message, true);
return; return;
} }
if (Utils::QtcProcess::startDetached({qdbFilePath, {"server"}})) if (Utils::QtcProcess::startDetached({qdbFilePath, {"server"}}))
showMessage(tr("QDB host server started."), false); showMessage(Tr::tr("QDB host server started."), false);
else else
showMessage(tr("Could not start QDB host server in %1").arg(qdbFilePath.toString()), true); showMessage(Tr::tr("Could not start QDB host server in %1").arg(qdbFilePath.toString()), true);
} }
void QdbWatcher::retry() void QdbWatcher::retry()
@@ -130,7 +130,7 @@ void QdbWatcher::retry()
{ {
QMutexLocker lock(&s_startMutex); QMutexLocker lock(&s_startMutex);
if (!s_startedServer) { if (!s_startedServer) {
showMessage(tr("Starting QDB host server."), false); showMessage(Tr::tr("Starting QDB host server."), false);
forkHostServer(); forkHostServer();
s_startedServer = true; s_startedServer = true;
} }
@@ -138,5 +138,4 @@ void QdbWatcher::retry()
QTimer::singleShot(startupDelay, this, &QdbWatcher::startPrivate); QTimer::singleShot(startupDelay, this, &QdbWatcher::startPrivate);
} }
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -14,12 +14,12 @@ QT_BEGIN_NAMESPACE
class QJsonDocument; class QJsonDocument;
QT_END_NAMESPACE QT_END_NAMESPACE
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
class QdbWatcher : public QObject class QdbWatcher : public QObject
{ {
Q_OBJECT Q_OBJECT
public: public:
QdbWatcher(QObject *parent = nullptr); QdbWatcher(QObject *parent = nullptr);
virtual ~QdbWatcher(); virtual ~QdbWatcher();
@@ -49,6 +49,5 @@ private:
RequestType m_requestType; RequestType m_requestType;
}; };
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -4,6 +4,7 @@
#include "qdbdeployconfigurationfactory.h" #include "qdbdeployconfigurationfactory.h"
#include "qdbconstants.h" #include "qdbconstants.h"
#include "qdbtr.h"
#include <projectexplorer/deploymentdataview.h> #include <projectexplorer/deploymentdataview.h>
#include "projectexplorer/devicesupport/idevice.h" #include "projectexplorer/devicesupport/idevice.h"
@@ -15,15 +16,13 @@
using namespace ProjectExplorer; using namespace ProjectExplorer;
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
QdbDeployConfigurationFactory::QdbDeployConfigurationFactory() QdbDeployConfigurationFactory::QdbDeployConfigurationFactory()
{ {
setConfigBaseId(Constants::QdbDeployConfigurationId); setConfigBaseId(Constants::QdbDeployConfigurationId);
addSupportedTargetDeviceType(Constants::QdbLinuxOsType); addSupportedTargetDeviceType(Constants::QdbLinuxOsType);
setDefaultDisplayName(QCoreApplication::translate("Qdb::Internal::QdbDeployConfiguration", setDefaultDisplayName(Tr::tr("Deploy to Boot2Qt target"));
"Deploy to Boot2Qt target"));
setUseDeploymentDataView(); setUseDeploymentDataView();
addInitialStep(RemoteLinux::Constants::MakeInstallStepId, [](Target *target) { addInitialStep(RemoteLinux::Constants::MakeInstallStepId, [](Target *target) {
@@ -59,5 +58,4 @@ QdbDeployConfigurationFactory::QdbDeployConfigurationFactory()
}); });
} }
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -5,8 +5,7 @@
#include <projectexplorer/deployconfiguration.h> #include <projectexplorer/deployconfiguration.h>
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
class QdbDeployConfigurationFactory final : public ProjectExplorer::DeployConfigurationFactory class QdbDeployConfigurationFactory final : public ProjectExplorer::DeployConfigurationFactory
{ {
@@ -14,5 +13,4 @@ public:
QdbDeployConfigurationFactory(); QdbDeployConfigurationFactory();
}; };
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -3,8 +3,9 @@
#include "qdbdevice.h" #include "qdbdevice.h"
#include "qdbutils.h"
#include "qdbconstants.h" #include "qdbconstants.h"
#include "qdbtr.h"
#include "qdbutils.h"
#include <coreplugin/icore.h> #include <coreplugin/icore.h>
@@ -27,8 +28,7 @@ using namespace ProjectExplorer;
using namespace RemoteLinux; using namespace RemoteLinux;
using namespace Utils; using namespace Utils;
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
class QdbProcessImpl : public LinuxProcessInterface class QdbProcessImpl : public LinuxProcessInterface
{ {
@@ -58,7 +58,7 @@ public:
m_appRunner.setCommand(command); m_appRunner.setCommand(command);
m_appRunner.start(); m_appRunner.start();
showMessage(QdbDevice::tr("Starting command \"%1\" on device \"%2\".") showMessage(Tr::tr("Starting command \"%1\" on device \"%2\".")
.arg(command.toUserOutput(), m_deviceName)); .arg(command.toUserOutput(), m_deviceName));
} }
@@ -78,18 +78,18 @@ private:
if (failure) { if (failure) {
QString errorString; QString errorString;
if (!m_appRunner.errorString().isEmpty()) { if (!m_appRunner.errorString().isEmpty()) {
errorString = QdbDevice::tr("Command failed on device \"%1\": %2") errorString = Tr::tr("Command failed on device \"%1\": %2")
.arg(m_deviceName, m_appRunner.errorString()); .arg(m_deviceName, m_appRunner.errorString());
} else { } else {
errorString = QdbDevice::tr("Command failed on device \"%1\".").arg(m_deviceName); errorString = Tr::tr("Command failed on device \"%1\".").arg(m_deviceName);
} }
showMessage(errorString, true); showMessage(errorString, true);
if (!stdOut.isEmpty()) if (!stdOut.isEmpty())
showMessage(QdbDevice::tr("stdout was: \"%1\"").arg(stdOut)); showMessage(Tr::tr("stdout was: \"%1\"").arg(stdOut));
if (!stdErr.isEmpty()) if (!stdErr.isEmpty())
showMessage(QdbDevice::tr("stderr was: \"%1\"").arg(stdErr)); showMessage(Tr::tr("stderr was: \"%1\"").arg(stdErr));
} else { } else {
showMessage(QdbDevice::tr("Commands on device \"%1\" finished successfully.") showMessage(Tr::tr("Commands on device \"%1\" finished successfully.")
.arg(m_deviceName)); .arg(m_deviceName));
} }
deleteLater(); deleteLater();
@@ -104,13 +104,13 @@ private:
QdbDevice::QdbDevice() QdbDevice::QdbDevice()
{ {
setDisplayType(tr("Boot2Qt Device")); setDisplayType(Tr::tr("Boot2Qt Device"));
addDeviceAction({tr("Reboot Device"), [](const IDevice::Ptr &device, QWidget *) { addDeviceAction({Tr::tr("Reboot Device"), [](const IDevice::Ptr &device, QWidget *) {
(void) new DeviceApplicationObserver(device, {device->filePath("reboot"), {}}); (void) new DeviceApplicationObserver(device, {device->filePath("reboot"), {}});
}}); }});
addDeviceAction({tr("Restore Default App"), [](const IDevice::Ptr &device, QWidget *) { addDeviceAction({Tr::tr("Restore Default App"), [](const IDevice::Ptr &device, QWidget *) {
(void) new DeviceApplicationObserver(device, {device->filePath("appcontroller"), {"--remove-default"}}); (void) new DeviceApplicationObserver(device, {device->filePath("appcontroller"), {"--remove-default"}});
}}); }});
} }
@@ -170,14 +170,14 @@ class QdbSettingsPage : public QWizardPage
public: public:
QdbSettingsPage() QdbSettingsPage()
{ {
setWindowTitle(QdbDevice::tr("WizardPage")); setWindowTitle(Tr::tr("WizardPage"));
setTitle(QdbDevice::tr("Device Settings")); setTitle(Tr::tr("Device Settings"));
nameLineEdit = new QLineEdit(this); nameLineEdit = new QLineEdit(this);
nameLineEdit->setPlaceholderText(QdbDevice::tr("A short, free-text description")); nameLineEdit->setPlaceholderText(Tr::tr("A short, free-text description"));
addressLineEdit = new QLineEdit(this); addressLineEdit = new QLineEdit(this);
addressLineEdit->setPlaceholderText(QdbDevice::tr("Host name or IP address")); addressLineEdit->setPlaceholderText(Tr::tr("Host name or IP address"));
auto usbWarningLabel = new QLabel(this); auto usbWarningLabel = new QLabel(this);
usbWarningLabel->setText(QString("<html><head/><body><it><b>%1</it><p>%2</p></body></html>") usbWarningLabel->setText(QString("<html><head/><body><it><b>%1</it><p>%2</p></body></html>")
@@ -187,8 +187,8 @@ public:
"<p>The connectivity to the device is tested after finishing.")); "<p>The connectivity to the device is tested after finishing."));
auto formLayout = new QFormLayout(this); auto formLayout = new QFormLayout(this);
formLayout->addRow(QdbDevice::tr("Device name:"), nameLineEdit); formLayout->addRow(Tr::tr("Device name:"), nameLineEdit);
formLayout->addRow(QdbDevice::tr("Device address:"), addressLineEdit); formLayout->addRow(Tr::tr("Device address:"), addressLineEdit);
formLayout->addRow(usbWarningLabel); formLayout->addRow(usbWarningLabel);
connect(nameLineEdit, &QLineEdit::textChanged, this, &QWizardPage::completeChanged); connect(nameLineEdit, &QLineEdit::textChanged, this, &QWizardPage::completeChanged);
@@ -214,7 +214,7 @@ public:
QdbDeviceWizard(QWidget *parent) QdbDeviceWizard(QWidget *parent)
: QWizard(parent) : QWizard(parent)
{ {
setWindowTitle(QdbDevice::tr("Boot2Qt Network Device Setup")); setWindowTitle(Tr::tr("Boot2Qt Network Device Setup"));
settingsPage.setCommitPage(true); settingsPage.setCommitPage(true);
enum { SettingsPageId }; enum { SettingsPageId };
@@ -246,7 +246,7 @@ private:
QdbLinuxDeviceFactory::QdbLinuxDeviceFactory() QdbLinuxDeviceFactory::QdbLinuxDeviceFactory()
: IDeviceFactory(Constants::QdbLinuxOsType) : IDeviceFactory(Constants::QdbLinuxOsType)
{ {
setDisplayName(QdbDevice::tr("Boot2Qt Device")); setDisplayName(Tr::tr("Boot2Qt Device"));
setCombinedIcon(":/qdb/images/qdbdevicesmall.png", ":/qdb/images/qdbdevice.png"); setCombinedIcon(":/qdb/images/qdbdevicesmall.png", ":/qdb/images/qdbdevice.png");
setConstructionFunction(&QdbDevice::create); setConstructionFunction(&QdbDevice::create);
setCreator([] { setCreator([] {
@@ -259,5 +259,4 @@ QdbLinuxDeviceFactory::QdbLinuxDeviceFactory()
}); });
} }
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -3,17 +3,13 @@
#pragma once #pragma once
#include "qdbconstants.h"
#include <projectexplorer/kit.h> #include <projectexplorer/kit.h>
#include <remotelinux/linuxdevice.h> #include <remotelinux/linuxdevice.h>
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
class QdbDevice final : public RemoteLinux::LinuxDevice class QdbDevice final : public RemoteLinux::LinuxDevice
{ {
Q_DECLARE_TR_FUNCTIONS(Qdb::Internal::QdbDevice)
public: public:
typedef QSharedPointer<QdbDevice> Ptr; typedef QSharedPointer<QdbDevice> Ptr;
typedef QSharedPointer<const QdbDevice> ConstPtr; typedef QSharedPointer<const QdbDevice> ConstPtr;
@@ -45,5 +41,4 @@ public:
QdbLinuxDeviceFactory(); QdbLinuxDeviceFactory();
}; };
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -4,9 +4,8 @@
#include "qdbdevicedebugsupport.h" #include "qdbdevicedebugsupport.h"
#include "qdbconstants.h" #include "qdbconstants.h"
#include "qdbdevice.h"
#include "qdbrunconfiguration.h"
#include <projectexplorer/devicesupport/idevice.h>
#include <projectexplorer/projectexplorerconstants.h> #include <projectexplorer/projectexplorerconstants.h>
#include <qmldebug/qmldebugcommandlinearguments.h> #include <qmldebug/qmldebugcommandlinearguments.h>

View File

@@ -4,6 +4,7 @@
#include "qdbmakedefaultappstep.h" #include "qdbmakedefaultappstep.h"
#include "qdbconstants.h" #include "qdbconstants.h"
#include "qdbtr.h"
#include <projectexplorer/devicesupport/idevice.h> #include <projectexplorer/devicesupport/idevice.h>
#include <projectexplorer/projectexplorerconstants.h> #include <projectexplorer/projectexplorerconstants.h>
@@ -20,14 +21,12 @@ using namespace ProjectExplorer;
using namespace Utils; using namespace Utils;
using namespace Utils::Tasking; using namespace Utils::Tasking;
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
// QdbMakeDefaultAppService // QdbMakeDefaultAppService
class QdbMakeDefaultAppService : public RemoteLinux::AbstractRemoteLinuxDeployService class QdbMakeDefaultAppService : public RemoteLinux::AbstractRemoteLinuxDeployService
{ {
Q_DECLARE_TR_FUNCTIONS(Qdb::Internal::QdbMakeDefaultAppService)
public: public:
void setMakeDefault(bool makeDefault) { m_makeDefault = makeDefault; } void setMakeDefault(bool makeDefault) { m_makeDefault = makeDefault; }
@@ -55,12 +54,12 @@ private:
}; };
const auto doneHandler = [this](const QtcProcess &) { const auto doneHandler = [this](const QtcProcess &) {
if (m_makeDefault) if (m_makeDefault)
emit progressMessage(tr("Application set as the default one.")); emit progressMessage(Tr::tr("Application set as the default one."));
else else
emit progressMessage(tr("Reset the default application.")); emit progressMessage(Tr::tr("Reset the default application."));
}; };
const auto errorHandler = [this](const QtcProcess &process) { const auto errorHandler = [this](const QtcProcess &process) {
emit errorMessage(tr("Remote process failed: %1").arg(process.errorString())); emit errorMessage(Tr::tr("Remote process failed: %1").arg(process.errorString()));
}; };
return Group { Process(setupHandler, doneHandler, errorHandler) }; return Group { Process(setupHandler, doneHandler, errorHandler) };
} }
@@ -72,8 +71,6 @@ private:
class QdbMakeDefaultAppStep final : public RemoteLinux::AbstractRemoteLinuxDeployStep class QdbMakeDefaultAppStep final : public RemoteLinux::AbstractRemoteLinuxDeployStep
{ {
Q_DECLARE_TR_FUNCTIONS(Qdb::Internal::QdbMakeDefaultAppStep)
public: public:
QdbMakeDefaultAppStep(BuildStepList *bsl, Id id) QdbMakeDefaultAppStep(BuildStepList *bsl, Id id)
: AbstractRemoteLinuxDeployStep(bsl, id) : AbstractRemoteLinuxDeployStep(bsl, id)
@@ -83,8 +80,8 @@ public:
auto selection = addAspect<SelectionAspect>(); auto selection = addAspect<SelectionAspect>();
selection->setSettingsKey("QdbMakeDefaultDeployStep.MakeDefault"); selection->setSettingsKey("QdbMakeDefaultDeployStep.MakeDefault");
selection->addOption(tr("Set this application to start by default")); selection->addOption(Tr::tr("Set this application to start by default"));
selection->addOption(tr("Reset default application")); selection->addOption(Tr::tr("Reset default application"));
setInternalInitializer([service, selection] { setInternalInitializer([service, selection] {
service->setMakeDefault(selection->value() == 0); service->setMakeDefault(selection->value() == 0);
@@ -99,10 +96,9 @@ public:
QdbMakeDefaultAppStepFactory::QdbMakeDefaultAppStepFactory() QdbMakeDefaultAppStepFactory::QdbMakeDefaultAppStepFactory()
{ {
registerStep<QdbMakeDefaultAppStep>(Constants::QdbMakeDefaultAppStepId); registerStep<QdbMakeDefaultAppStep>(Constants::QdbMakeDefaultAppStepId);
setDisplayName(QdbMakeDefaultAppStep::tr("Change default application")); setDisplayName(Tr::tr("Change default application"));
setSupportedDeviceType(Qdb::Constants::QdbLinuxOsType); setSupportedDeviceType(Qdb::Constants::QdbLinuxOsType);
setSupportedStepList(ProjectExplorer::Constants::BUILDSTEPS_DEPLOY); setSupportedStepList(ProjectExplorer::Constants::BUILDSTEPS_DEPLOY);
} }
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -5,8 +5,7 @@
#include <projectexplorer/buildstep.h> #include <projectexplorer/buildstep.h>
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
class QdbMakeDefaultAppStepFactory final : public ProjectExplorer::BuildStepFactory class QdbMakeDefaultAppStepFactory final : public ProjectExplorer::BuildStepFactory
{ {
@@ -14,5 +13,4 @@ public:
QdbMakeDefaultAppStepFactory(); QdbMakeDefaultAppStepFactory();
}; };
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -4,13 +4,16 @@
#include "qdbplugin.h" #include "qdbplugin.h"
#include "device-detection/devicedetector.h" #include "device-detection/devicedetector.h"
#include "qdbconstants.h"
#include "qdbdeployconfigurationfactory.h" #include "qdbdeployconfigurationfactory.h"
#include "qdbdevice.h"
#include "qdbstopapplicationstep.h" #include "qdbstopapplicationstep.h"
#include "qdbmakedefaultappstep.h" #include "qdbmakedefaultappstep.h"
#include "qdbdevicedebugsupport.h" #include "qdbdevicedebugsupport.h"
#include "qdbqtversion.h" #include "qdbqtversion.h"
#include "qdbrunconfiguration.h" #include "qdbrunconfiguration.h"
#include "qdbutils.h" #include "qdbutils.h"
#include "qdbtr.h"
#include <coreplugin/actionmanager/actioncontainer.h> #include <coreplugin/actionmanager/actioncontainer.h>
#include <coreplugin/actionmanager/actionmanager.h> #include <coreplugin/actionmanager/actionmanager.h>
@@ -34,7 +37,6 @@
#include <utils/qtcprocess.h> #include <utils/qtcprocess.h>
#include <QAction> #include <QAction>
#include <QFileInfo>
using namespace ProjectExplorer; using namespace ProjectExplorer;
using namespace Utils; using namespace Utils;
@@ -56,8 +58,7 @@ static void startFlashingWizard()
} else if (QtcProcess::startDetached({filePath, {}})) { } else if (QtcProcess::startDetached({filePath, {}})) {
return; return;
} }
const QString message = const QString message = Tr::tr("Flash wizard \"%1\" failed to start.");
QCoreApplication::translate("Qdb", "Flash wizard \"%1\" failed to start.");
showMessage(message.arg(filePath.toUserOutput()), true); showMessage(message.arg(filePath.toUserOutput()), true);
} }
@@ -76,9 +77,8 @@ void registerFlashAction(QObject *parentForAction)
return; return;
const FilePath fileName = flashWizardFilePath(); const FilePath fileName = flashWizardFilePath();
if (!fileName.exists()) { if (!fileName.exists()) {
const QString message = const QString message = Tr::tr("Flash wizard executable \"%1\" not found.");
QCoreApplication::translate("Qdb", "Flash wizard executable \"%1\" not found."); showMessage(message.arg(fileName.toUserOutput()));
showMessage(message.arg(fileName.toString()));
return; return;
} }
@@ -92,8 +92,7 @@ void registerFlashAction(QObject *parentForAction)
Core::Context globalContext(Core::Constants::C_GLOBAL); Core::Context globalContext(Core::Constants::C_GLOBAL);
const QString actionText = QCoreApplication::translate("Qdb", "Flash Boot to Qt Device"); QAction *flashAction = new QAction(Tr::tr("Flash Boot to Qt Device"), parentForAction);
QAction *flashAction = new QAction(actionText, parentForAction);
Core::Command *flashCommand = Core::ActionManager::registerAction(flashAction, Core::Command *flashCommand = Core::ActionManager::registerAction(flashAction,
flashActionId, flashActionId,
globalContext); globalContext);

View File

@@ -5,8 +5,7 @@
#include <extensionsystem/iplugin.h> #include <extensionsystem/iplugin.h>
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
class QdbPlugin final : public ExtensionSystem::IPlugin class QdbPlugin final : public ExtensionSystem::IPlugin
{ {
@@ -25,5 +24,4 @@ private:
class QdbPluginPrivate *d = nullptr; class QdbPluginPrivate *d = nullptr;
}; };
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -4,13 +4,13 @@
#include "qdbqtversion.h" #include "qdbqtversion.h"
#include "qdbconstants.h" #include "qdbconstants.h"
#include "qdbtr.h"
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
QString QdbQtVersion::description() const QString QdbQtVersion::description() const
{ {
return QCoreApplication::translate("QtVersion", "Boot2Qt", "Qt version is used for Boot2Qt development"); return Tr::tr("Boot2Qt", "Qt version is used for Boot2Qt development");
} }
QSet<Utils::Id> QdbQtVersion::targetDeviceTypes() const QSet<Utils::Id> QdbQtVersion::targetDeviceTypes() const
@@ -19,5 +19,4 @@ QSet<Utils::Id> QdbQtVersion::targetDeviceTypes() const
} }
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -5,8 +5,7 @@
#include <qtsupport/baseqtversion.h> #include <qtsupport/baseqtversion.h>
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
class QdbQtVersion : public QtSupport::QtVersion class QdbQtVersion : public QtSupport::QtVersion
{ {
@@ -18,5 +17,4 @@ public:
QSet<Utils::Id> targetDeviceTypes() const final; QSet<Utils::Id> targetDeviceTypes() const final;
}; };
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -4,6 +4,7 @@
#include "qdbrunconfiguration.h" #include "qdbrunconfiguration.h"
#include "qdbconstants.h" #include "qdbconstants.h"
#include "qdbtr.h"
#include <projectexplorer/buildsystem.h> #include <projectexplorer/buildsystem.h>
#include <projectexplorer/buildtargetinfo.h> #include <projectexplorer/buildtargetinfo.h>
@@ -22,19 +23,16 @@
using namespace ProjectExplorer; using namespace ProjectExplorer;
using namespace Utils; using namespace Utils;
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
// FullCommandLineAspect // FullCommandLineAspect
class FullCommandLineAspect : public StringAspect class FullCommandLineAspect : public StringAspect
{ {
Q_DECLARE_TR_FUNCTIONS(Qdb::Internal::QdbRunConfiguration);
public: public:
explicit FullCommandLineAspect(RunConfiguration *rc) explicit FullCommandLineAspect(RunConfiguration *rc)
{ {
setLabelText(tr("Full command line:")); setLabelText(Tr::tr("Full command line:"));
auto exeAspect = rc->aspect<ExecutableAspect>(); auto exeAspect = rc->aspect<ExecutableAspect>();
auto argumentsAspect = rc->aspect<ArgumentsAspect>(); auto argumentsAspect = rc->aspect<ArgumentsAspect>();
@@ -58,8 +56,6 @@ public:
class QdbRunConfiguration : public RunConfiguration class QdbRunConfiguration : public RunConfiguration
{ {
Q_DECLARE_TR_FUNCTIONS(Qdb::Internal::QdbRunConfiguration);
public: public:
QdbRunConfiguration(Target *target, Utils::Id id); QdbRunConfiguration(Target *target, Utils::Id id);
@@ -73,14 +69,14 @@ QdbRunConfiguration::QdbRunConfiguration(Target *target, Id id)
{ {
auto exeAspect = addAspect<ExecutableAspect>(target, ExecutableAspect::RunDevice); auto exeAspect = addAspect<ExecutableAspect>(target, ExecutableAspect::RunDevice);
exeAspect->setSettingsKey("QdbRunConfig.RemoteExecutable"); exeAspect->setSettingsKey("QdbRunConfig.RemoteExecutable");
exeAspect->setLabelText(tr("Executable on device:")); exeAspect->setLabelText(Tr::tr("Executable on device:"));
exeAspect->setPlaceHolderText(tr("Remote path not set")); exeAspect->setPlaceHolderText(Tr::tr("Remote path not set"));
exeAspect->makeOverridable("QdbRunConfig.AlternateRemoteExecutable", exeAspect->makeOverridable("QdbRunConfig.AlternateRemoteExecutable",
"QdbRunCofig.UseAlternateRemoteExecutable"); "QdbRunCofig.UseAlternateRemoteExecutable");
auto symbolsAspect = addAspect<SymbolFileAspect>(); auto symbolsAspect = addAspect<SymbolFileAspect>();
symbolsAspect->setSettingsKey("QdbRunConfig.LocalExecutable"); symbolsAspect->setSettingsKey("QdbRunConfig.LocalExecutable");
symbolsAspect->setLabelText(tr("Executable on host:")); symbolsAspect->setLabelText(Tr::tr("Executable on host:"));
symbolsAspect->setDisplayStyle(SymbolFileAspect::LabelDisplay); symbolsAspect->setDisplayStyle(SymbolFileAspect::LabelDisplay);
auto envAspect = addAspect<RemoteLinux::RemoteLinuxEnvironmentAspect>(target); auto envAspect = addAspect<RemoteLinux::RemoteLinuxEnvironmentAspect>(target);
@@ -103,15 +99,15 @@ QdbRunConfiguration::QdbRunConfiguration(Target *target, Id id)
connect(target, &Target::deploymentDataChanged, this, &RunConfiguration::update); connect(target, &Target::deploymentDataChanged, this, &RunConfiguration::update);
connect(target, &Target::kitChanged, this, &RunConfiguration::update); connect(target, &Target::kitChanged, this, &RunConfiguration::update);
setDefaultDisplayName(tr("Run on Boot2Qt Device")); setDefaultDisplayName(Tr::tr("Run on Boot2Qt Device"));
} }
Tasks QdbRunConfiguration::checkForIssues() const Tasks QdbRunConfiguration::checkForIssues() const
{ {
Tasks tasks; Tasks tasks;
if (aspect<ExecutableAspect>()->executable().toString().isEmpty()) { if (aspect<ExecutableAspect>()->executable().toString().isEmpty()) {
tasks << BuildSystemTask(Task::Warning, tr("The remote executable must be set " tasks << BuildSystemTask(Task::Warning, Tr::tr("The remote executable must be set "
"in order to run on a Boot2Qt device.")); "in order to run on a Boot2Qt device."));
} }
return tasks; return tasks;
} }
@@ -129,5 +125,4 @@ QdbRunConfigurationFactory::QdbRunConfigurationFactory()
addSupportedTargetDeviceType(Constants::QdbLinuxOsType); addSupportedTargetDeviceType(Constants::QdbLinuxOsType);
} }
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -5,8 +5,7 @@
#include <projectexplorer/runconfigurationaspects.h> #include <projectexplorer/runconfigurationaspects.h>
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
class QdbRunConfigurationFactory : public ProjectExplorer::RunConfigurationFactory class QdbRunConfigurationFactory : public ProjectExplorer::RunConfigurationFactory
{ {
@@ -14,5 +13,4 @@ public:
QdbRunConfigurationFactory(); QdbRunConfigurationFactory();
}; };
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -4,6 +4,7 @@
#include "qdbstopapplicationstep.h" #include "qdbstopapplicationstep.h"
#include "qdbconstants.h" #include "qdbconstants.h"
#include "qdbtr.h"
#include <projectexplorer/devicesupport/idevice.h> #include <projectexplorer/devicesupport/idevice.h>
#include <projectexplorer/kitinformation.h> #include <projectexplorer/kitinformation.h>
@@ -19,15 +20,12 @@ using namespace ProjectExplorer;
using namespace Utils; using namespace Utils;
using namespace Utils::Tasking; using namespace Utils::Tasking;
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
// QdbStopApplicationService // QdbStopApplicationService
class QdbStopApplicationService : public RemoteLinux::AbstractRemoteLinuxDeployService class QdbStopApplicationService : public RemoteLinux::AbstractRemoteLinuxDeployService
{ {
Q_DECLARE_TR_FUNCTIONS(Qdb::Internal::QdbStopApplicationService)
private: private:
bool isDeploymentNecessary() const final { return true; } bool isDeploymentNecessary() const final { return true; }
Group deployRecipe() final; Group deployRecipe() final;
@@ -46,17 +44,17 @@ Group QdbStopApplicationService::deployRecipe()
}); });
}; };
const auto doneHandler = [this](const QtcProcess &) { const auto doneHandler = [this](const QtcProcess &) {
emit progressMessage(tr("Stopped the running application.")); emit progressMessage(Tr::tr("Stopped the running application."));
}; };
const auto errorHandler = [this](const QtcProcess &process) { const auto errorHandler = [this](const QtcProcess &process) {
const QString errorOutput = process.cleanedStdErr(); const QString errorOutput = process.cleanedStdErr();
const QString failureMessage = tr("Could not check and possibly stop running application."); const QString failureMessage = Tr::tr("Could not check and possibly stop running application.");
if (process.exitStatus() == QProcess::CrashExit) { if (process.exitStatus() == QProcess::CrashExit) {
emit errorMessage(failureMessage); emit errorMessage(failureMessage);
} else if (process.result() != ProcessResult::FinishedWithSuccess) { } else if (process.result() != ProcessResult::FinishedWithSuccess) {
emit stdErrData(process.errorString()); emit stdErrData(process.errorString());
} else if (errorOutput.contains("Could not connect: Connection refused")) { } else if (errorOutput.contains("Could not connect: Connection refused")) {
emit progressMessage(tr("Checked that there is no running application.")); emit progressMessage(Tr::tr("Checked that there is no running application."));
} else if (!errorOutput.isEmpty()) { } else if (!errorOutput.isEmpty()) {
emit stdErrData(errorOutput); emit stdErrData(errorOutput);
emit errorMessage(failureMessage); emit errorMessage(failureMessage);
@@ -65,7 +63,7 @@ Group QdbStopApplicationService::deployRecipe()
const auto rootSetupHandler = [this] { const auto rootSetupHandler = [this] {
const auto device = DeviceKitAspect::device(target()->kit()); const auto device = DeviceKitAspect::device(target()->kit());
if (!device) { if (!device) {
emit errorMessage(tr("No device to stop the application on.")); emit errorMessage(Tr::tr("No device to stop the application on."));
return GroupConfig{GroupAction::StopWithError}; return GroupConfig{GroupAction::StopWithError};
} }
return GroupConfig(); return GroupConfig();
@@ -81,8 +79,6 @@ Group QdbStopApplicationService::deployRecipe()
class QdbStopApplicationStep final : public RemoteLinux::AbstractRemoteLinuxDeployStep class QdbStopApplicationStep final : public RemoteLinux::AbstractRemoteLinuxDeployStep
{ {
Q_DECLARE_TR_FUNCTIONS(Qdb::Internal::QdbStopApplicationStep)
public: public:
QdbStopApplicationStep(BuildStepList *bsl, Id id) QdbStopApplicationStep(BuildStepList *bsl, Id id)
: AbstractRemoteLinuxDeployStep(bsl, id) : AbstractRemoteLinuxDeployStep(bsl, id)
@@ -102,10 +98,9 @@ public:
QdbStopApplicationStepFactory::QdbStopApplicationStepFactory() QdbStopApplicationStepFactory::QdbStopApplicationStepFactory()
{ {
registerStep<QdbStopApplicationStep>(Constants::QdbStopApplicationStepId); registerStep<QdbStopApplicationStep>(Constants::QdbStopApplicationStepId);
setDisplayName(QdbStopApplicationStep::tr("Stop already running application")); setDisplayName(Tr::tr("Stop already running application"));
setSupportedDeviceType(Constants::QdbLinuxOsType); setSupportedDeviceType(Constants::QdbLinuxOsType);
setSupportedStepList(ProjectExplorer::Constants::BUILDSTEPS_DEPLOY); setSupportedStepList(ProjectExplorer::Constants::BUILDSTEPS_DEPLOY);
} }
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -5,8 +5,7 @@
#include <projectexplorer/buildstep.h> #include <projectexplorer/buildstep.h>
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
class QdbStopApplicationStepFactory final : public ProjectExplorer::BuildStepFactory class QdbStopApplicationStepFactory final : public ProjectExplorer::BuildStepFactory
{ {
@@ -14,5 +13,4 @@ public:
QdbStopApplicationStepFactory(); QdbStopApplicationStepFactory();
}; };
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -5,11 +5,11 @@
#include <QCoreApplication> #include <QCoreApplication>
namespace Boot2Qt { namespace Qdb {
struct Tr struct Tr
{ {
Q_DECLARE_TR_FUNCTIONS(::Boot2Qt) Q_DECLARE_TR_FUNCTIONS(::Qdb)
}; };
} // namespace Boot2Qt } // namespace Qdb

View File

@@ -3,8 +3,11 @@
#include "qdbutils.h" #include "qdbutils.h"
#include "qdbtr.h"
#include <coreplugin/icore.h> #include <coreplugin/icore.h>
#include <coreplugin/messagemanager.h> #include <coreplugin/messagemanager.h>
#include <utils/environment.h> #include <utils/environment.h>
#include <utils/filepath.h> #include <utils/filepath.h>
#include <utils/hostosinfo.h> #include <utils/hostosinfo.h>
@@ -12,8 +15,7 @@
using namespace Utils; using namespace Utils;
namespace Qdb { namespace Qdb::Internal {
namespace Internal {
static QString executableBaseName(QdbTool tool) static QString executableBaseName(QdbTool tool)
{ {
@@ -63,7 +65,7 @@ QString overridingEnvironmentVariable(QdbTool tool)
void showMessage(const QString &message, bool important) void showMessage(const QString &message, bool important)
{ {
const QString fullMessage = QCoreApplication::translate("::Boot2Qt", "Boot2Qt: %1").arg(message); const QString fullMessage = Tr::tr("Boot2Qt: %1").arg(message);
if (important) if (important)
Core::MessageManager::writeFlashing(fullMessage); Core::MessageManager::writeFlashing(fullMessage);
else else
@@ -86,5 +88,4 @@ QString settingsKey(QdbTool tool)
QTC_ASSERT(false, return QString()); QTC_ASSERT(false, return QString());
} }
} // namespace Internal } // Qdb::Internal
} // namespace Qdb

View File

@@ -3,12 +3,9 @@
#pragma once #pragma once
#include <utils/fileutils.h> #include <utils/filepath.h>
#include <qglobal.h> namespace Qdb::Internal {
namespace Qdb {
namespace Internal {
enum class QdbTool { enum class QdbTool {
FlashingWizard, FlashingWizard,
@@ -21,5 +18,4 @@ void showMessage(const QString &message, bool important = false);
QString settingsGroupKey(); QString settingsGroupKey();
QString settingsKey(QdbTool tool); QString settingsKey(QdbTool tool);
} // namespace Internal } // Qdb::Internal
} // namespace Qdb