From c18cd85cf5c1f8a489b613112b111aa911886587 Mon Sep 17 00:00:00 2001 From: Corvus Corax Date: Tue, 25 Jun 2013 22:31:10 +0200 Subject: [PATCH] uncrustification --- .../src/plugins/config/configstabilizationwidget.cpp | 7 +++---- .../src/plugins/config/configstabilizationwidget.h | 3 +-- .../src/plugins/uavobjectwidgetutils/configtaskwidget.h | 2 +- .../src/plugins/uavobjectwidgetutils/smartsavebutton.cpp | 8 ++++---- 4 files changed, 9 insertions(+), 11 deletions(-) diff --git a/ground/openpilotgcs/src/plugins/config/configstabilizationwidget.cpp b/ground/openpilotgcs/src/plugins/config/configstabilizationwidget.cpp index f0312a35a..69df7ccc5 100644 --- a/ground/openpilotgcs/src/plugins/config/configstabilizationwidget.cpp +++ b/ground/openpilotgcs/src/plugins/config/configstabilizationwidget.cpp @@ -208,10 +208,9 @@ void ConfigStabilizationWidget::onBoardConnected() bool ConfigStabilizationWidget::shouldObjectBeSaved(UAVObject *object) { // AltitudeHoldSettings should only be saved for Revolution board to avoid error. - if((boardModel & 0xff00) != 0x0900) { - return dynamic_cast(object) == 0; - } - else { + if ((boardModel & 0xff00) != 0x0900) { + return dynamic_cast(object) == 0; + } else { return true; } } diff --git a/ground/openpilotgcs/src/plugins/config/configstabilizationwidget.h b/ground/openpilotgcs/src/plugins/config/configstabilizationwidget.h index 6d3b500ef..c13448078 100644 --- a/ground/openpilotgcs/src/plugins/config/configstabilizationwidget.h +++ b/ground/openpilotgcs/src/plugins/config/configstabilizationwidget.h @@ -43,7 +43,7 @@ class ConfigStabilizationWidget : public ConfigTaskWidget { public: ConfigStabilizationWidget(QWidget *parent = 0); ~ConfigStabilizationWidget(); - bool shouldObjectBeSaved(UAVObject * object); + bool shouldObjectBeSaved(UAVObject *object); private: Ui_StabilizationWidget *ui; @@ -62,7 +62,6 @@ private slots: void linkCheckBoxes(bool value); void processLinkedWidgets(QWidget *); void onBoardConnected(); - }; #endif // ConfigStabilizationWidget_H diff --git a/ground/openpilotgcs/src/plugins/uavobjectwidgetutils/configtaskwidget.h b/ground/openpilotgcs/src/plugins/uavobjectwidgetutils/configtaskwidget.h index 25ea31a47..191647fac 100644 --- a/ground/openpilotgcs/src/plugins/uavobjectwidgetutils/configtaskwidget.h +++ b/ground/openpilotgcs/src/plugins/uavobjectwidgetutils/configtaskwidget.h @@ -144,7 +144,7 @@ public: void addHelpButton(QPushButton *button, QString url); void forceShadowUpdates(); void forceConnectedState(); - virtual bool shouldObjectBeSaved(UAVObject * object); + virtual bool shouldObjectBeSaved(UAVObject *object); public slots: void onAutopilotDisconnect(); void onAutopilotConnect(); diff --git a/ground/openpilotgcs/src/plugins/uavobjectwidgetutils/smartsavebutton.cpp b/ground/openpilotgcs/src/plugins/uavobjectwidgetutils/smartsavebutton.cpp index 9d0ff284f..0165c32bb 100644 --- a/ground/openpilotgcs/src/plugins/uavobjectwidgetutils/smartsavebutton.cpp +++ b/ground/openpilotgcs/src/plugins/uavobjectwidgetutils/smartsavebutton.cpp @@ -78,7 +78,7 @@ void smartSaveButton::processOperation(QPushButton *button, bool save) foreach(UAVDataObject * obj, objects) { UAVObject::Metadata mdata = obj->getMetadata(); - //Should we really save this object to the board? + // Should we really save this object to the board? if (!configWidget->shouldObjectBeSaved(obj) || UAVObject::GetGcsAccess(mdata) == UAVObject::ACCESS_READONLY) { qDebug() << obj->getName() << "was skipped."; continue; @@ -95,7 +95,7 @@ void smartSaveButton::processOperation(QPushButton *button, bool save) timer.start(3000); loop.exec(); if (!timer.isActive()) { - qDebug() << "Upload of" << obj->getName() << "timed out." ; + qDebug() << "Upload of" << obj->getName() << "timed out."; } timer.stop(); @@ -116,7 +116,7 @@ void smartSaveButton::processOperation(QPushButton *button, bool save) current_objectID = obj->getObjID(); if (save && (obj->isSettings())) { for (int i = 0; i < 3; ++i) { - qDebug() << "Saving" << obj->getName() << "to board."; + qDebug() << "Saving" << obj->getName() << "to board."; connect(utilMngr, SIGNAL(saveCompleted(int, bool)), this, SLOT(saving_finished(int, bool))); connect(&timer, SIGNAL(timeout()), &loop, SLOT(quit())); utilMngr->saveObjectToSD(obj); @@ -208,7 +208,7 @@ void smartSaveButton::enableControls(bool value) void smartSaveButton::resetIcons() { foreach(QPushButton * button, buttonList.keys()) - button->setIcon(QIcon()); + button->setIcon(QIcon()); } void smartSaveButton::apply()