FactSystem.cc 1.1 KB
Newer Older
1 2
/****************************************************************************
 *
Gus Grubba's avatar
Gus Grubba committed
3
 * (c) 2009-2020 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
4 5 6 7 8 9
 *
 * QGroundControl is licensed according to the terms in the file
 * COPYING.md in the root of the source code directory.
 *
 ****************************************************************************/

Don Gagne's avatar
Don Gagne committed
10 11 12 13 14

/// @file
///     @author Don Gagne <don@thegagnes.com>

#include "FactSystem.h"
Don Gagne's avatar
Don Gagne committed
15
#include "FactGroup.h"
16
#include "FactPanelController.h"
Don Gagne's avatar
Don Gagne committed
17 18 19

#include <QtQml>

Don Gagne's avatar
Don Gagne committed
20
const char* FactSystem::_factSystemQmlUri = "QGroundControl.FactSystem";
Don Gagne's avatar
Don Gagne committed
21

22 23
FactSystem::FactSystem(QGCApplication* app, QGCToolbox* toolbox)
    : QGCTool(app, toolbox)
Don Gagne's avatar
Don Gagne committed
24
{
25

Don Gagne's avatar
Don Gagne committed
26 27
}

28
void FactSystem::setToolbox(QGCToolbox *toolbox)
Don Gagne's avatar
Don Gagne committed
29
{
30
    QGCTool::setToolbox(toolbox);
Don Gagne's avatar
Don Gagne committed
31

Don Gagne's avatar
Don Gagne committed
32
    qmlRegisterType<Fact>               (_factSystemQmlUri, 1, 0, "Fact");
Don Gagne's avatar
Don Gagne committed
33
    qmlRegisterType<FactMetaData>       (_factSystemQmlUri, 1, 0, "FactMetaData");
34
    qmlRegisterType<FactPanelController>(_factSystemQmlUri, 1, 0, "FactPanelController");
35 36

    qmlRegisterUncreatableType<FactGroup>(_factSystemQmlUri, 1, 0, "FactGroup", "ReferenceOnly");
Don Gagne's avatar
Don Gagne committed
37
}