Skip to content

Commit

Permalink
JoyStickButtonAssignment: Fix warning text
Browse files Browse the repository at this point in the history
As requested here: PX4/PX4-user_guide#2072 (comment)

Improves readability
  • Loading branch information
junwoo091400 authored and julianoes committed Apr 11, 2024
1 parent 60870df commit 1a3e35d
Show file tree
Hide file tree
Showing 21 changed files with 44 additions and 38 deletions.
12 changes: 9 additions & 3 deletions src/VehicleSetup/JoystickConfigButtons.qml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ import QGroundControl.FactControls 1.0
ColumnLayout {
width: availableWidth
height: (globals.activeVehicle.supportsJSButton ? buttonCol.height : flowColumn.height) + (ScreenTools.defaultFontPixelHeight * 2)
spacing: ScreenTools.defaultFontPixelHeight

Connections {
target: _activeJoystick
onRawButtonPressedChanged: {
Expand All @@ -34,16 +36,20 @@ ColumnLayout {
}
}
}

ColumnLayout {
id: flowColumn
y: ScreenTools.defaultFontPixelHeight / 2
width: parent.width
spacing: ScreenTools.defaultFontPixelHeight / 2
anchors.centerIn: parent
spacing: ScreenTools.defaultFontPixelHeight

// Note for reminding the use of multiple buttons for the same action
QGCLabel {
Layout.preferredWidth: parent.width
wrapMode: Text.WordWrap
text: qsTr("Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.")
text: qsTr(" Multiple buttons that have the same action must be pressed simultaneously to invoke the action.")
}

Flow {
id: buttonFlow
Layout.preferredWidth: parent.width
Expand Down
2 changes: 1 addition & 1 deletion translations/qgc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8447,7 +8447,7 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"></translation>
</message>
<message>
Expand Down
2 changes: 1 addition & 1 deletion translations/qgc_source_az_AZ.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8472,7 +8472,7 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation>Eyni hərəkəti bir neçə düyməyə təyin etmək, hərəkət üçün bütün bu düymələrin basılmasını tələb edir. Bu, Xodlama və ya Təcili Yardım kimi kritik hərəkətlər üçün təsadüfi düymələrin basılmasının qarşısını almaq üçün faydalıdır.</translation>
</message>
<message>
Expand Down
4 changes: 2 additions & 2 deletions translations/qgc_source_bg_BG.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8470,8 +8470,8 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<translation type="unfinished">Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</translation>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</translation>
</message>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="94"/>
Expand Down
4 changes: 2 additions & 2 deletions translations/qgc_source_de_DE.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8470,8 +8470,8 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<translation type="unfinished">Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</translation>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</translation>
</message>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="94"/>
Expand Down
4 changes: 2 additions & 2 deletions translations/qgc_source_el_GR.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8470,8 +8470,8 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<translation type="unfinished">Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</translation>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</translation>
</message>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="94"/>
Expand Down
4 changes: 2 additions & 2 deletions translations/qgc_source_es_ES.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8470,8 +8470,8 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<translation type="unfinished">Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</translation>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</translation>
</message>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="94"/>
Expand Down
4 changes: 2 additions & 2 deletions translations/qgc_source_fi_FI.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8470,8 +8470,8 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<translation type="unfinished">Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</translation>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</translation>
</message>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="94"/>
Expand Down
4 changes: 2 additions & 2 deletions translations/qgc_source_fr_FR.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8470,8 +8470,8 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<translation type="unfinished">Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</translation>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</translation>
</message>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="94"/>
Expand Down
4 changes: 2 additions & 2 deletions translations/qgc_source_he_IL.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8470,8 +8470,8 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<translation type="unfinished">Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</translation>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</translation>
</message>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="94"/>
Expand Down
4 changes: 2 additions & 2 deletions translations/qgc_source_it_IT.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8470,8 +8470,8 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<translation type="unfinished">Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</translation>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</translation>
</message>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="94"/>
Expand Down
2 changes: 1 addition & 1 deletion translations/qgc_source_ja_JP.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8463,7 +8463,7 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation>複数のボタンに同じアクションを割り当てる場合、アクションを実行するためには、それらのボタンすべてを押す必要があります。これはアームや緊急停止などの重大なアクションの際に、誤ってボタンを押してしまうことを防止するために有効です。</translation>
</message>
<message>
Expand Down
4 changes: 2 additions & 2 deletions translations/qgc_source_ko_KR.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8476,8 +8476,8 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<translation type="unfinished">Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</translation>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</translation>
</message>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="94"/>
Expand Down
4 changes: 2 additions & 2 deletions translations/qgc_source_nl_NL.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8470,8 +8470,8 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<translation type="unfinished">Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</translation>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</translation>
</message>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="94"/>
Expand Down
4 changes: 2 additions & 2 deletions translations/qgc_source_no_NO.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8470,8 +8470,8 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<translation type="unfinished">Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</translation>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</translation>
</message>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="94"/>
Expand Down
4 changes: 2 additions & 2 deletions translations/qgc_source_pl_PL.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8470,8 +8470,8 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<translation type="unfinished">Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</translation>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</translation>
</message>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="94"/>
Expand Down
2 changes: 1 addition & 1 deletion translations/qgc_source_pt_PT.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8469,7 +8469,7 @@ Clique em Ok para inciar o processo de auto-ajuste.</translation>
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation>A atribuição da mesma ação para vários botões requer que todos esses botões sejam pressionados para a ação ser tomada. Isso é útil para prevenir acidentes com ações críticas como Armar ou Parada de Emergência.</translation>
</message>
<message>
Expand Down
4 changes: 2 additions & 2 deletions translations/qgc_source_ru_RU.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8470,8 +8470,8 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<translation type="unfinished">Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</translation>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</translation>
</message>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="94"/>
Expand Down
4 changes: 2 additions & 2 deletions translations/qgc_source_sv_SE.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8470,8 +8470,8 @@ Click Ok to start the auto-tuning process.
<name>JoystickConfigButtons</name>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="45"/>
<source>Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</source>
<translation type="unfinished">Assigning the same action to multiple buttons requires the press of all those buttons for the action to be taken. This is useful to prevent accidental button presses for critical actions like Arm or Emergency Stop.</translation>
<source> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</source>
<translation type="unfinished"> Multiple buttons that have the same action must be pressed simultaneously to invoke the action.</translation>
</message>
<message>
<location filename="../src/VehicleSetup/JoystickConfigButtons.qml" line="94"/>
Expand Down
Loading

0 comments on commit 1a3e35d

Please sign in to comment.