mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2024-11-29 07:24:13 +01:00
uncrustification
This commit is contained in:
parent
e8150399f6
commit
2f2cff3dc6
@ -77,12 +77,12 @@ AboutDialog::AboutDialog(QWidget *parent) :
|
||||
view->setResizeMode(QQuickView::SizeRootObjectToView);
|
||||
view->setSource(QUrl("qrc:/core/qml/AboutDialog.qml"));
|
||||
|
||||
QWidget * container = QWidget::createWindowContainer(view);
|
||||
QWidget *container = QWidget::createWindowContainer(view);
|
||||
container->setMinimumSize(600, 400);
|
||||
container->setMaximumSize(800, 600);
|
||||
container->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
|
||||
QVBoxLayout *lay = new QVBoxLayout();
|
||||
lay->setContentsMargins(0,0,0,0);
|
||||
lay->setContentsMargins(0, 0, 0, 0);
|
||||
setLayout(lay);
|
||||
layout()->addWidget(container);
|
||||
}
|
||||
@ -93,5 +93,4 @@ void AboutDialog::openUrl(const QString &url)
|
||||
}
|
||||
|
||||
AboutDialog::~AboutDialog()
|
||||
{
|
||||
}
|
||||
{}
|
||||
|
@ -26,8 +26,7 @@
|
||||
|
||||
#include <QDialog>
|
||||
|
||||
class AboutDialog : public QDialog
|
||||
{
|
||||
class AboutDialog : public QDialog {
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
@ -36,7 +35,6 @@ public:
|
||||
|
||||
public slots:
|
||||
void openUrl(const QString &url);
|
||||
|
||||
};
|
||||
|
||||
#endif // ABOUTDIALOG_H
|
||||
|
@ -35,7 +35,7 @@ public:
|
||||
|
||||
QWidget *widget()
|
||||
{
|
||||
if(!m_container){
|
||||
if (!m_container) {
|
||||
m_container = QWidget::createWindowContainer(m_widget, m_parent);
|
||||
m_container->setMinimumSize(64, 64);
|
||||
m_container->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::MinimumExpanding);
|
||||
|
@ -46,7 +46,7 @@ public:
|
||||
|
||||
QWidget *widget()
|
||||
{
|
||||
if(!m_container){
|
||||
if (!m_container) {
|
||||
m_container = QWidget::createWindowContainer(m_widget, m_parent);
|
||||
m_container->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::MinimumExpanding);
|
||||
m_container->setMinimumSize(64, 64);
|
||||
|
@ -114,6 +114,7 @@ public:
|
||||
QWidget *createEditor(QWidget *parent)
|
||||
{
|
||||
QComboBox *editor = new QComboBox(parent);
|
||||
|
||||
// Setting ClickFocus lets the ComboBox stay open on Mac OSX.
|
||||
editor->setFocusPolicy(Qt::ClickFocus);
|
||||
foreach(QString option, m_enumOptions)
|
||||
|
@ -100,7 +100,7 @@ int WelcomeMode::priority() const
|
||||
|
||||
QWidget *WelcomeMode::widget()
|
||||
{
|
||||
if(!m_container){
|
||||
if (!m_container) {
|
||||
m_container = QWidget::createWindowContainer(m_d->quickView);
|
||||
m_container->setMinimumSize(64, 64);
|
||||
m_container->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::MinimumExpanding);
|
||||
|
@ -127,9 +127,9 @@ bool UAVObjectGeneratorGCS::process_object(ObjectInfo *info)
|
||||
type = fieldTypeStrCPP[field->type];
|
||||
// Append field
|
||||
if (field->numElements > 1) {
|
||||
//add both field(elementIndex)/setField(elemntIndex,value) and field_element properties
|
||||
//field_element is more convenient if only certain element is used
|
||||
//and much easier to use from the qml side
|
||||
// add both field(elementIndex)/setField(elemntIndex,value) and field_element properties
|
||||
// field_element is more convenient if only certain element is used
|
||||
// and much easier to use from the qml side
|
||||
propertyGetters +=
|
||||
QString(" Q_INVOKABLE %1 get%2(quint32 index) const;\n")
|
||||
.arg(type).arg(field->name);
|
||||
@ -160,7 +160,7 @@ bool UAVObjectGeneratorGCS::process_object(ObjectInfo *info)
|
||||
for (int elementIndex = 0; elementIndex < field->numElements; elementIndex++) {
|
||||
QString elementName = field->elementNames[elementIndex];
|
||||
properties += QString(" Q_PROPERTY(%1 %2 READ get%2 WRITE set%2 NOTIFY %2Changed);\n")
|
||||
.arg(type).arg(field->name+"_"+elementName);
|
||||
.arg(type).arg(field->name + "_" + elementName);
|
||||
propertyGetters +=
|
||||
QString(" Q_INVOKABLE %1 get%2_%3() const;\n")
|
||||
.arg(type).arg(field->name).arg(elementName);
|
||||
|
Loading…
Reference in New Issue
Block a user