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
80f8aac3
Commit
80f8aac3
authored
May 25, 2013
by
Lorenz Meier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Only loading port names which still are available, fixed more compile errors
parent
b94f906c
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
4 deletions
+23
-4
SerialConfigurationWindow.cc
src/ui/SerialConfigurationWindow.cc
+9
-1
QGCGoogleEarthView.cc
src/ui/map3D/QGCGoogleEarthView.cc
+2
-2
WaypointGroupNode.cc
src/ui/map3D/WaypointGroupNode.cc
+12
-1
No files found.
src/ui/SerialConfigurationWindow.cc
View file @
80f8aac3
...
...
@@ -218,6 +218,9 @@ void SerialConfigurationWindow::setupPortList()
// Get the ports available on this system
QVector
<
QString
>*
ports
=
link
->
getCurrentPorts
();
QString
storedName
=
this
->
link
->
getPortName
();
bool
storedFound
=
false
;
// Add the ports in reverse order, because we prepend them to the list
for
(
int
i
=
ports
->
size
()
-
1
;
i
>=
0
;
--
i
)
{
...
...
@@ -227,9 +230,14 @@ void SerialConfigurationWindow::setupPortList()
ui
.
portName
->
insertItem
(
0
,
ports
->
at
(
i
));
if
(
!
userConfigured
)
ui
.
portName
->
setEditText
(
ports
->
at
(
i
));
}
// Check if the stored link name is still present
if
(
ports
->
at
(
i
).
contains
(
storedName
)
||
storedName
.
contains
(
ports
->
at
(
i
)))
storedFound
=
true
;
}
ui
.
portName
->
setEditText
(
this
->
link
->
getPortName
());
if
(
storedFound
)
ui
.
portName
->
setEditText
(
storedName
);
}
void
SerialConfigurationWindow
::
enableFlowControl
(
bool
flow
)
...
...
src/ui/map3D/QGCGoogleEarthView.cc
View file @
80f8aac3
...
...
@@ -265,7 +265,7 @@ void QGCGoogleEarthView::updateWaypointList(int uas)
if
(
uasInstance
)
{
// Get all waypoints, including non-global waypoints
Q
Vector
<
Waypoint
*>
wpList
=
uasInstance
->
getWaypointManager
()
->
getGlobalFrameAndNavTypeWaypointList
();
Q
List
<
Waypoint
*>
wpList
=
uasInstance
->
getWaypointManager
()
->
getGlobalFrameAndNavTypeWaypointList
();
// Trim internal list to number of global waypoints in the waypoint manager list
javaScript
(
QString
(
"updateWaypointListLength(%1,%2);"
).
arg
(
uas
).
arg
(
wpList
.
count
()));
...
...
@@ -712,7 +712,7 @@ void QGCGoogleEarthView::updateState()
// Update waypoint or symbol
if
(
mav
)
{
Q
Vector
<
Waypoint
*>
wps
=
mav
->
getWaypointManager
()
->
getGlobalFrameAndNavTypeWaypointList
();
Q
List
<
Waypoint
*>
wps
=
mav
->
getWaypointManager
()
->
getGlobalFrameAndNavTypeWaypointList
();
bool
ok
;
int
index
=
idText
.
toInt
(
&
ok
);
...
...
src/ui/map3D/WaypointGroupNode.cc
View file @
80f8aac3
...
...
@@ -36,6 +36,7 @@ This file is part of the QGROUNDCONTROL project
#include <osg/ShapeDrawable>
#include "Imagery.h"
#include "UASManager.h"
WaypointGroupNode
::
WaypointGroupNode
(
const
QColor
&
color
)
:
mColor
(
color
)
...
...
@@ -70,6 +71,16 @@ WaypointGroupNode::update(UASInterface* uas, MAV_FRAME frame)
Imagery
::
LLtoUTM
(
latitude
,
longitude
,
robotX
,
robotY
,
utmZone
);
robotZ
=
-
altitude
;
}
else
if
(
frame
==
MAV_FRAME_GLOBAL_RELATIVE_ALT
)
{
double
latitude
=
uas
->
getLatitude
();
double
longitude
=
uas
->
getLongitude
();
double
altitude
=
uas
->
getAltitude
()
+
UASManager
::
instance
()
->
getHomeAltitude
();
QString
utmZone
;
Imagery
::
LLtoUTM
(
latitude
,
longitude
,
robotX
,
robotY
,
utmZone
);
robotZ
=
-
altitude
;
}
else
if
(
frame
==
MAV_FRAME_LOCAL_NED
)
{
robotX
=
uas
->
getLocalX
();
...
...
@@ -82,7 +93,7 @@ WaypointGroupNode::update(UASInterface* uas, MAV_FRAME frame)
removeChild
(
0
,
getNumChildren
());
}
const
Q
Vector
<
Waypoint
*>&
list
=
uas
->
getWaypointManager
()
->
getWaypointEditableList
();
const
Q
List
<
Waypoint
*>&
list
=
uas
->
getWaypointManager
()
->
getWaypointEditableList
();
for
(
int
i
=
0
;
i
<
list
.
size
();
i
++
)
{
...
...
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