Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qgroundcontrol
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Valentin Platzgummer
qgroundcontrol
Commits
daba18b5
Commit
daba18b5
authored
Jun 27, 2019
by
Patrick José Pereira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Vehicle: Remove QString constructor with tr
Signed-off-by:
Patrick José Pereira
<
patrickelectric@gmail.com
>
parent
de64c327
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
Vehicle.cc
src/Vehicle/Vehicle.cc
+4
-4
No files found.
src/Vehicle/Vehicle.cc
View file @
daba18b5
...
...
@@ -1539,7 +1539,7 @@ void Vehicle::_handleSysStatus(mavlink_message_t& message)
if
(
sysStatus
.
battery_remaining
>
0
)
{
if
(
sysStatus
.
battery_remaining
<
_settingsManager
->
appSettings
()
->
batteryPercentRemainingAnnounce
()
->
rawValue
().
toInt
()
&&
sysStatus
.
battery_remaining
<
_lastAnnouncedLowBatteryPercent
)
{
_say
(
QString
(
tr
(
"%1 low battery: %2 percent remaining"
)
).
arg
(
_vehicleIdSpeech
()).
arg
(
sysStatus
.
battery_remaining
));
_say
(
tr
(
"%1 low battery: %2 percent remaining"
).
arg
(
_vehicleIdSpeech
()).
arg
(
sysStatus
.
battery_remaining
));
}
_lastAnnouncedLowBatteryPercent
=
sysStatus
.
battery_remaining
;
}
...
...
@@ -2934,7 +2934,7 @@ QString Vehicle::vehicleTypeName() const {
QString
Vehicle
::
_vehicleIdSpeech
(
void
)
{
if
(
_toolbox
->
multiVehicleManager
()
->
vehicles
()
->
count
()
>
1
)
{
return
QString
(
tr
(
"vehicle %1"
)
).
arg
(
id
());
return
tr
(
"vehicle %1"
).
arg
(
id
());
}
else
{
return
QString
();
}
...
...
@@ -2942,13 +2942,13 @@ QString Vehicle::_vehicleIdSpeech(void)
void
Vehicle
::
_handleFlightModeChanged
(
const
QString
&
flightMode
)
{
_say
(
QString
(
tr
(
"%1 %2 flight mode"
)
).
arg
(
_vehicleIdSpeech
()).
arg
(
flightMode
));
_say
(
tr
(
"%1 %2 flight mode"
).
arg
(
_vehicleIdSpeech
()).
arg
(
flightMode
));
emit
guidedModeChanged
(
_firmwarePlugin
->
isGuidedMode
(
this
));
}
void
Vehicle
::
_announceArmedChanged
(
bool
armed
)
{
_say
(
QString
(
"%1 %2"
).
arg
(
_vehicleIdSpeech
()).
arg
(
armed
?
QString
(
tr
(
"armed"
))
:
QString
(
tr
(
"disarmed"
)
)));
_say
(
QString
(
"%1 %2"
).
arg
(
_vehicleIdSpeech
()).
arg
(
armed
?
tr
(
"armed"
)
:
tr
(
"disarmed"
)));
}
void
Vehicle
::
_setFlying
(
bool
flying
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment