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
d6801ac6
Commit
d6801ac6
authored
Aug 15, 2013
by
tstellanova
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix rendering of advanced parameters editors
parent
1b1e0f50
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
28 additions
and
24 deletions
+28
-24
QGCBaseParamWidget.cc
src/ui/QGCBaseParamWidget.cc
+18
-16
QGCPX4VehicleConfig.cc
src/ui/QGCPX4VehicleConfig.cc
+10
-8
No files found.
src/ui/QGCBaseParamWidget.cc
View file @
d6801ac6
...
@@ -25,22 +25,24 @@ QGCBaseParamWidget* QGCBaseParamWidget::initWithUAS(UASInterface *uas)
...
@@ -25,22 +25,24 @@ QGCBaseParamWidget* QGCBaseParamWidget::initWithUAS(UASInterface *uas)
void
QGCBaseParamWidget
::
setUAS
(
UASInterface
*
uas
)
void
QGCBaseParamWidget
::
setUAS
(
UASInterface
*
uas
)
{
{
if
(
mav
)
{
if
(
uas
!=
mav
)
{
//TODO disconnect any connections as needed
if
(
mav
)
{
disconnectViewSignalsAndSlots
();
//TODO disconnect any connections as needed
disconnectFromParamManager
();
disconnectViewSignalsAndSlots
();
clearOnboardParamDisplay
();
disconnectFromParamManager
();
clearPendingParamDisplay
();
clearOnboardParamDisplay
();
}
clearPendingParamDisplay
();
}
mav
=
uas
;
mav
=
uas
;
if
(
mav
)
{
connectToParamManager
();
if
(
mav
)
{
connectViewSignalsAndSlots
();
connectToParamManager
();
layoutWidget
();
connectViewSignalsAndSlots
();
layoutWidget
();
paramMgr
->
requestParameterListIfEmpty
();
paramMgr
->
requestParameterListIfEmpty
();
}
}
}
}
}
...
...
src/ui/QGCPX4VehicleConfig.cc
View file @
d6801ac6
...
@@ -84,15 +84,16 @@ QGCPX4VehicleConfig::QGCPX4VehicleConfig(QWidget *parent) :
...
@@ -84,15 +84,16 @@ QGCPX4VehicleConfig::QGCPX4VehicleConfig(QWidget *parent) :
//connect(ui->setTrimButton, SIGNAL(clicked()), this, SLOT(setTrimPositions()));
//connect(ui->setTrimButton, SIGNAL(clicked()), this, SLOT(setTrimPositions()));
//TODO connect buttons here to save/clear actions?
//TODO connect buttons here to save/clear actions?
mav
=
UASManager
::
instance
()
->
getActiveUAS
();
UASInterface
*
tmpMav
=
UASManager
::
instance
()
->
getActiveUAS
();
if
(
!
mav
)
{
if
(
tmpMav
)
{
qWarning
()
<<
"No active mav! "
;
ui
->
pendingCommitsWidget
->
initWithUAS
(
tmpMav
);
}
else
{
ui
->
pendingCommitsWidget
->
initWithUAS
(
mav
);
ui
->
pendingCommitsWidget
->
update
();
ui
->
pendingCommitsWidget
->
update
();
setActiveUAS
(
tmpMav
);
}
}
connect
(
UASManager
::
instance
(),
SIGNAL
(
activeUASSet
(
UASInterface
*
)),
this
,
SLOT
(
setActiveUAS
(
UASInterface
*
)));
//TODO the following methods are not yet implemented
//TODO the following methods are not yet implemented
// Connect RC mapping assignments
// Connect RC mapping assignments
...
@@ -115,9 +116,9 @@ QGCPX4VehicleConfig::QGCPX4VehicleConfig(QWidget *parent) :
...
@@ -115,9 +116,9 @@ QGCPX4VehicleConfig::QGCPX4VehicleConfig(QWidget *parent) :
// connect(ui->invertCheckBox_7, SIGNAL(clicked(bool)), this, SLOT(setAux2Inverted(bool)));
// connect(ui->invertCheckBox_7, SIGNAL(clicked(bool)), this, SLOT(setAux2Inverted(bool)));
// connect(ui->invertCheckBox_8, SIGNAL(clicked(bool)), this, SLOT(setAux3Inverted(bool)));
// connect(ui->invertCheckBox_8, SIGNAL(clicked(bool)), this, SLOT(setAux3Inverted(bool)));
connect
(
UASManager
::
instance
(),
SIGNAL
(
activeUASSet
(
UASInterface
*
)),
this
,
SLOT
(
setActiveUAS
(
UASInterface
*
)));
setActiveUAS
(
UASManager
::
instance
()
->
getActiveUAS
());
for
(
unsigned
int
i
=
0
;
i
<
chanMax
;
i
++
)
{
for
(
unsigned
int
i
=
0
;
i
<
chanMax
;
i
++
)
{
rcValue
[
i
]
=
UINT16_MAX
;
rcValue
[
i
]
=
UINT16_MAX
;
...
@@ -1248,6 +1249,7 @@ void QGCPX4VehicleConfig::parameterChanged(int uas, int component, QString param
...
@@ -1248,6 +1249,7 @@ void QGCPX4VehicleConfig::parameterChanged(int uas, int component, QString param
return
;
return
;
}
}
//TODO this may introduce a bug with param editor widgets not receiving param updates
if
(
parameterName
.
startsWith
(
"RC"
))
{
if
(
parameterName
.
startsWith
(
"RC"
))
{
handleRcParameterChange
(
parameterName
,
value
);
handleRcParameterChange
(
parameterName
,
value
);
return
;
return
;
...
...
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