mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2024-12-02 10:24:11 +01:00
OP-803 remove spurious commit
This commit is contained in:
parent
3e9c819850
commit
d03db9c6d1
@ -239,9 +239,8 @@ void UAVGadgetInstanceManager::createOptionsPages()
|
|||||||
m_pm->removeObject(m_optionsPages.takeLast());
|
m_pm->removeObject(m_optionsPages.takeLast());
|
||||||
}
|
}
|
||||||
|
|
||||||
QMutableListIterator<IUAVGadgetConfiguration*> ite(m_configurations);
|
foreach (IUAVGadgetConfiguration *config, m_configurations)
|
||||||
while (ite.hasNext()) {
|
{
|
||||||
IUAVGadgetConfiguration *config = ite.next();
|
|
||||||
IUAVGadgetFactory *f = factory(config->classId());
|
IUAVGadgetFactory *f = factory(config->classId());
|
||||||
IOptionsPage *p = f->createOptionsPage(config);
|
IOptionsPage *p = f->createOptionsPage(config);
|
||||||
if (p) {
|
if (p) {
|
||||||
@ -250,14 +249,6 @@ void UAVGadgetInstanceManager::createOptionsPages()
|
|||||||
m_optionsPages.append(page);
|
m_optionsPages.append(page);
|
||||||
m_pm->addObject(page);
|
m_pm->addObject(page);
|
||||||
}
|
}
|
||||||
else {
|
|
||||||
qWarning()
|
|
||||||
<< "UAVGadgetInstanceManager::createOptionsPages - failed to create options page for configuration "
|
|
||||||
+ config->classId() + ":" + config->name() + ", configuration will be removed.";
|
|
||||||
// The m_optionsPages list and m_configurations list must be in synch otherwise nasty issues happen later
|
|
||||||
// so if we fail to create an options page we must remove the associated configuration
|
|
||||||
ite.remove();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user