Browse Source

Unused formal parameter, unused local variable and a couple unreachable code changes

QGC4.4
Don Gagne 12 years ago
parent
commit
ff390617b5
  1. 5
      src/uas/UAS.cc
  2. 12
      src/ui/HUD.cc
  3. 1
      src/ui/MainWindow.cc
  4. 2
      src/ui/PrimaryFlightDisplay.cc
  5. 2
      src/ui/QGCHilConfiguration.cc
  6. 2
      src/ui/QGCPX4VehicleConfig.cc
  7. 1
      src/ui/UASRawStatusView.cpp
  8. 5
      src/ui/configuration/AP2ConfigWidget.cc
  9. 5
      src/ui/configuration/AccelCalibrationConfig.cc
  10. 4
      src/ui/configuration/AdvParameterList.cc
  11. 3
      src/ui/configuration/AdvancedParamConfig.cc
  12. 3
      src/ui/configuration/AirspeedConfig.cc
  13. 1
      src/ui/configuration/ApmFirmwareConfig.cc
  14. 3
      src/ui/configuration/ApmPlaneLevel.cc
  15. 3
      src/ui/configuration/ArduCopterPidConfig.cc
  16. 3
      src/ui/configuration/ArduPlanePidConfig.cc
  17. 3
      src/ui/configuration/ArduRoverPidConfig.cc
  18. 9
      src/ui/configuration/BatteryMonitorConfig.cc
  19. 3
      src/ui/configuration/CameraGimbalConfig.cc
  20. 3
      src/ui/configuration/CompassConfig.cc
  21. 7
      src/ui/configuration/FailSafeConfig.cc
  22. 3
      src/ui/configuration/FrameTypeConfig.cc
  23. 3
      src/ui/configuration/OpticalFlowConfig.cc
  24. 4
      src/ui/configuration/ParamWidget.cc
  25. 7
      src/ui/configuration/RadioCalibrationConfig.cc
  26. 5
      src/ui/configuration/SonarConfig.cc
  27. 3
      src/ui/configuration/StandardParamConfig.cc
  28. 1
      src/ui/configuration/terminalconsole.cpp
  29. 2
      src/ui/designer/QGCRadioChannelDisplay.cpp
  30. 4
      src/ui/designer/QGCToolWidget.cc
  31. 2
      src/ui/linechart/IncrementalPlot.h
  32. 3
      src/ui/uas/UASQuickView.cc
  33. 2
      src/ui/uas/UASQuickViewGaugeItem.cc
  34. 2
      src/ui/uas/UASQuickViewItemSelect.cc
  35. 4
      src/ui/uas/UASQuickViewTextItem.cc
  36. 1
      src/ui/uas/UASQuickViewTextItem.h

5
src/uas/UAS.cc

@ -3070,6 +3070,11 @@ void UAS::sendHilGroundTruth(quint64 time_us, float roll, float pitch, float yaw @@ -3070,6 +3070,11 @@ void UAS::sendHilGroundTruth(quint64 time_us, float roll, float pitch, float yaw
float pitchspeed, float yawspeed, double lat, double lon, double alt,
float vx, float vy, float vz, float ind_airspeed, float true_airspeed, float xacc, float yacc, float zacc)
{
Q_UNUSED(time_us);
Q_UNUSED(xacc);
Q_UNUSED(yacc);
Q_UNUSED(zacc);
float q[4];
double cosPhi_2 = cos(double(roll) / 2.0);

12
src/ui/HUD.cc

@ -117,6 +117,9 @@ HUD::HUD(int width, int height, QWidget* parent) @@ -117,6 +117,9 @@ HUD::HUD(int width, int height, QWidget* parent)
imageRequested(false),
image(NULL)
{
Q_UNUSED(width);
Q_UNUSED(height);
// Set auto fill to false
setAutoFillBackground(false);
@ -501,11 +504,18 @@ void HUD::paintText(QString text, QColor color, float fontSize, float refX, floa @@ -501,11 +504,18 @@ void HUD::paintText(QString text, QColor color, float fontSize, float refX, floa
*/
void HUD::setupGLView(float referencePositionX, float referencePositionY, float referenceWidth, float referenceHeight)
{
Q_UNUSED(referencePositionX);
Q_UNUSED(referencePositionY);
Q_UNUSED(referenceWidth);
Q_UNUSED(referenceHeight);
#if 0
// code ifdef'ed out but left in to silence warnings
int pixelWidth = (int)(referenceWidth * scalingFactor);
int pixelHeight = (int)(referenceHeight * scalingFactor);
// Translate and scale the GL view in the virtual reference coordinate units on the screen
int pixelPositionX = (int)((referencePositionX * scalingFactor) + xCenterOffset);
int pixelPositionY = this->height() - (referencePositionY * scalingFactor) + yCenterOffset - pixelHeight;
#endif
}
void HUD::paintRollPitchStrips()
@ -515,7 +525,7 @@ void HUD::paintRollPitchStrips() @@ -515,7 +525,7 @@ void HUD::paintRollPitchStrips()
void HUD::paintEvent(QPaintEvent *event)
{
Q_UNUSED(event);
paintHUD();
}

1
src/ui/MainWindow.cc

@ -800,6 +800,7 @@ void MainWindow::loadDockWidget(const QString& name) @@ -800,6 +800,7 @@ void MainWindow::loadDockWidget(const QString& name)
void MainWindow::addToCentralStackedWidget(QWidget* widget, VIEW_SECTIONS viewSection, const QString& title)
{
Q_UNUSED(viewSection);
Q_UNUSED(title);
Q_ASSERT(widget->objectName().length() != 0);

2
src/ui/PrimaryFlightDisplay.cc

@ -606,6 +606,8 @@ void PrimaryFlightDisplay::drawPitchScale( @@ -606,6 +606,8 @@ void PrimaryFlightDisplay::drawPitchScale(
bool drawNumbersRight
) {
Q_UNUSED(intrusion);
float displayPitch = this->pitch;
if (isnan(displayPitch))
displayPitch = 0;

2
src/ui/QGCHilConfiguration.cc

@ -48,7 +48,7 @@ QGCHilConfiguration::~QGCHilConfiguration() @@ -48,7 +48,7 @@ QGCHilConfiguration::~QGCHilConfiguration()
void QGCHilConfiguration::setVersion(QString version)
{
Q_UNUSED(version);
}
void QGCHilConfiguration::on_simComboBox_currentIndexChanged(int index)

2
src/ui/QGCPX4VehicleConfig.cc

@ -355,6 +355,8 @@ void QGCPX4VehicleConfig::toggleCalibrationRC(bool enabled) @@ -355,6 +355,8 @@ void QGCPX4VehicleConfig::toggleCalibrationRC(bool enabled)
void QGCPX4VehicleConfig::toggleSpektrumPairing(bool enabled)
{
Q_UNUSED(enabled);
if (!ui->dsm2RadioButton->isChecked() && !ui->dsmxRadioButton && !ui->dsmx8RadioButton) {
// Reject
QMessageBox warnMsgBox;

1
src/ui/UASRawStatusView.cpp

@ -47,6 +47,7 @@ void UASRawStatusView::valueChanged(const int uasId, const QString& name, const @@ -47,6 +47,7 @@ void UASRawStatusView::valueChanged(const int uasId, const QString& name, const
}
void UASRawStatusView::resizeEvent(QResizeEvent *event)
{
Q_UNUSED(event);
m_tableDirty = true;
}

5
src/ui/configuration/AP2ConfigWidget.cc

@ -25,7 +25,10 @@ void AP2ConfigWidget::activeUASSet(UASInterface *uas) @@ -25,7 +25,10 @@ void AP2ConfigWidget::activeUASSet(UASInterface *uas)
void AP2ConfigWidget::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
Q_UNUSED(parameterName);
Q_UNUSED(value);
}
void AP2ConfigWidget::showNullMAVErrorMessageBox()
{

5
src/ui/configuration/AccelCalibrationConfig.cc

@ -71,6 +71,8 @@ void AccelCalibrationConfig::calibrateButtonClicked() @@ -71,6 +71,8 @@ void AccelCalibrationConfig::calibrateButtonClicked()
}
void AccelCalibrationConfig::hideEvent(QHideEvent *evt)
{
Q_UNUSED(evt);
if (!m_uas || !m_accelAckCount)
{
return;
@ -82,6 +84,9 @@ void AccelCalibrationConfig::hideEvent(QHideEvent *evt) @@ -82,6 +84,9 @@ void AccelCalibrationConfig::hideEvent(QHideEvent *evt)
}
void AccelCalibrationConfig::uasTextMessageReceived(int uasid, int componentid, int severity, QString text)
{
Q_UNUSED(uasid);
Q_UNUSED(componentid);
//command received: " Severity 1
//Place APM Level and press any key" severity 5
if (severity == 5)

4
src/ui/configuration/AdvParameterList.cc

@ -25,7 +25,9 @@ void AdvParameterList::setParameterMetaData(QString name,QString humanname,QStri @@ -25,7 +25,9 @@ void AdvParameterList::setParameterMetaData(QString name,QString humanname,QStri
void AdvParameterList::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
if (!m_paramValueMap.contains(parameterName))
{
ui.tableWidget->setRowCount(ui.tableWidget->rowCount()+1);

3
src/ui/configuration/AdvancedParamConfig.cc

@ -33,6 +33,9 @@ void AdvancedParamConfig::addCombo(QString title,QString description,QString par @@ -33,6 +33,9 @@ void AdvancedParamConfig::addCombo(QString title,QString description,QString par
}
void AdvancedParamConfig::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
if (m_paramToWidgetMap.contains(parameterName))
{
if (value.type() == QVariant::Double)

3
src/ui/configuration/AirspeedConfig.cc

@ -14,6 +14,9 @@ AirspeedConfig::~AirspeedConfig() @@ -14,6 +14,9 @@ AirspeedConfig::~AirspeedConfig()
}
void AirspeedConfig::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
if (parameterName == "ARSPD_ENABLE")
{
if (value.toInt() == 0)

1
src/ui/configuration/ApmFirmwareConfig.cc

@ -387,6 +387,7 @@ void ApmFirmwareConfig::flashButtonClicked() @@ -387,6 +387,7 @@ void ApmFirmwareConfig::flashButtonClicked()
void ApmFirmwareConfig::firmwareListError(QNetworkReply::NetworkError error)
{
Q_UNUSED(error);
QNetworkReply *reply = qobject_cast<QNetworkReply*>(sender());
qDebug() << "Error!" << reply->errorString();
}

3
src/ui/configuration/ApmPlaneLevel.cc

@ -52,6 +52,9 @@ void ApmPlaneLevel::manualCheckBoxToggled(bool checked) @@ -52,6 +52,9 @@ void ApmPlaneLevel::manualCheckBoxToggled(bool checked)
}
void ApmPlaneLevel::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
if (parameterName == "MANUAL_LEVEL")
{
if (value.toInt() == 1)

3
src/ui/configuration/ArduCopterPidConfig.cc

@ -139,6 +139,9 @@ ArduCopterPidConfig::~ArduCopterPidConfig() @@ -139,6 +139,9 @@ ArduCopterPidConfig::~ArduCopterPidConfig()
}
void ArduCopterPidConfig::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
if (m_nameToBoxMap.contains(parameterName))
{
m_nameToBoxMap[parameterName]->setValue(value.toDouble());

3
src/ui/configuration/ArduPlanePidConfig.cc

@ -66,6 +66,9 @@ ArduPlanePidConfig::~ArduPlanePidConfig() @@ -66,6 +66,9 @@ ArduPlanePidConfig::~ArduPlanePidConfig()
}
void ArduPlanePidConfig::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
if (m_nameToBoxMap.contains(parameterName))
{
m_nameToBoxMap[parameterName]->setValue(value.toDouble());

3
src/ui/configuration/ArduRoverPidConfig.cc

@ -73,6 +73,9 @@ void ArduRoverPidConfig::refreshButtonClicked() @@ -73,6 +73,9 @@ void ArduRoverPidConfig::refreshButtonClicked()
void ArduRoverPidConfig::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
if (nameToBoxMap.contains(parameterName))
{
nameToBoxMap[parameterName]->setValue(value.toFloat());

9
src/ui/configuration/BatteryMonitorConfig.cc

@ -49,6 +49,7 @@ void BatteryMonitorConfig::activeUASSet(UASInterface *uas) @@ -49,6 +49,7 @@ void BatteryMonitorConfig::activeUASSet(UASInterface *uas)
}
void BatteryMonitorConfig::alertOnLowClicked(bool checked)
{
Q_UNUSED(checked);
}
void BatteryMonitorConfig::calcDividerSet()
@ -246,6 +247,11 @@ BatteryMonitorConfig::~BatteryMonitorConfig() @@ -246,6 +247,11 @@ BatteryMonitorConfig::~BatteryMonitorConfig()
}
void BatteryMonitorConfig::batteryChanged(UASInterface* uas, double voltage, double current, double percent, int seconds)
{
Q_UNUSED(uas);
Q_UNUSED(current);
Q_UNUSED(percent);
Q_UNUSED(seconds);
ui.calcVoltsLineEdit->setText(QString::number(voltage,'f',2));
if (ui.measuredVoltsLineEdit->text() == "")
{
@ -255,6 +261,9 @@ void BatteryMonitorConfig::batteryChanged(UASInterface* uas, double voltage, dou @@ -255,6 +261,9 @@ void BatteryMonitorConfig::batteryChanged(UASInterface* uas, double voltage, dou
void BatteryMonitorConfig::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
if (parameterName == "VOLT_DIVIDER")
{
ui.calcDividerLineEdit->setText(QString::number(value.toFloat(),'f',4));

3
src/ui/configuration/CameraGimbalConfig.cc

@ -265,6 +265,9 @@ CameraGimbalConfig::~CameraGimbalConfig() @@ -265,6 +265,9 @@ CameraGimbalConfig::~CameraGimbalConfig()
void CameraGimbalConfig::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
if (parameterName == "MNT_ANGMIN_TIL") //TILT
{
ui.tiltAngleMinSpinBox->setValue(value.toInt() / 100.0);

3
src/ui/configuration/CompassConfig.cc

@ -46,6 +46,9 @@ CompassConfig::~CompassConfig() @@ -46,6 +46,9 @@ CompassConfig::~CompassConfig()
}
void CompassConfig::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
if (parameterName == "MAG_ENABLE")
{
if (value.toInt() == 0)

7
src/ui/configuration/FailSafeConfig.cc

@ -278,6 +278,9 @@ void FailSafeConfig::activeUASSet(UASInterface *uas) @@ -278,6 +278,9 @@ void FailSafeConfig::activeUASSet(UASInterface *uas)
}
void FailSafeConfig::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
//Arducopter
if (parameterName == "FS_THR_ENABLE")
{
@ -414,6 +417,8 @@ void FailSafeConfig::remoteControlChannelRawChanges(int chan,float value) @@ -414,6 +417,8 @@ void FailSafeConfig::remoteControlChannelRawChanges(int chan,float value)
}
void FailSafeConfig::hilActuatorsChanged(uint64_t time, float act1, float act2, float act3, float act4, float act5, float act6, float act7, float act8)
{
Q_UNUSED(time);
ui.radio1Out->setValue(act1);
ui.radio2Out->setValue(act2);
ui.radio3Out->setValue(act3);
@ -425,6 +430,8 @@ void FailSafeConfig::hilActuatorsChanged(uint64_t time, float act1, float act2, @@ -425,6 +430,8 @@ void FailSafeConfig::hilActuatorsChanged(uint64_t time, float act1, float act2,
}
void FailSafeConfig::gpsStatusChanged(UASInterface* uas,int fixtype)
{
Q_UNUSED(uas);
if (fixtype == 0 || fixtype == 1)
{
ui.gpsLabel->setText("<h1>None</h1>");

3
src/ui/configuration/FrameTypeConfig.cc

@ -52,6 +52,9 @@ FrameTypeConfig::~FrameTypeConfig() @@ -52,6 +52,9 @@ FrameTypeConfig::~FrameTypeConfig()
}
void FrameTypeConfig::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
if (parameterName == "FRAME")
{
ui.xRadioButton->setEnabled(true);

3
src/ui/configuration/OpticalFlowConfig.cc

@ -13,6 +13,9 @@ OpticalFlowConfig::~OpticalFlowConfig() @@ -13,6 +13,9 @@ OpticalFlowConfig::~OpticalFlowConfig()
}
void OpticalFlowConfig::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
if (parameterName == "FLOW_ENABLE")
{
if (value.toInt() == 0)

4
src/ui/configuration/ParamWidget.cc

@ -48,6 +48,8 @@ ParamWidget::~ParamWidget() @@ -48,6 +48,8 @@ ParamWidget::~ParamWidget()
void ParamWidget::setupInt(QString title,QString description,int value,int min,int max)
{
Q_UNUSED(value);
type = INT;
ui.titleLabel->setText("<h3>" + title + "</h3>");
ui.descriptionLabel->setText(description);
@ -71,6 +73,8 @@ void ParamWidget::setupInt(QString title,QString description,int value,int min,i @@ -71,6 +73,8 @@ void ParamWidget::setupInt(QString title,QString description,int value,int min,i
void ParamWidget::setupDouble(QString title,QString description,double value,double min,double max)
{
Q_UNUSED(value);
type = DOUBLE;
ui.titleLabel->setText("<h3>" + title + "</h3>");
ui.descriptionLabel->setText(description);

7
src/ui/configuration/RadioCalibrationConfig.cc

@ -119,7 +119,10 @@ void RadioCalibrationConfig::remoteControlChannelRawChanged(int chan,float val) @@ -119,7 +119,10 @@ void RadioCalibrationConfig::remoteControlChannelRawChanged(int chan,float val)
void RadioCalibrationConfig::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
Q_UNUSED(parameterName);
Q_UNUSED(value);
}
void RadioCalibrationConfig::guiUpdateTimerTick()
{
@ -153,10 +156,12 @@ void RadioCalibrationConfig::guiUpdateTimerTick() @@ -153,10 +156,12 @@ void RadioCalibrationConfig::guiUpdateTimerTick()
}
void RadioCalibrationConfig::showEvent(QShowEvent *event)
{
Q_UNUSED(event);
guiUpdateTimer->start(100);
}
void RadioCalibrationConfig::hideEvent(QHideEvent *event)
{
Q_UNUSED(event);
guiUpdateTimer->stop();
}
void RadioCalibrationConfig::calibrateButtonClicked()

5
src/ui/configuration/SonarConfig.cc

@ -32,6 +32,8 @@ void SonarConfig::checkBoxToggled(bool enabled) @@ -32,6 +32,8 @@ void SonarConfig::checkBoxToggled(bool enabled)
}
void SonarConfig::sonarTypeChanged(int index)
{
Q_UNUSED(index);
if (!m_uas)
{
QMessageBox::information(0,tr("Error"),tr("Please connect to a MAV before attempting to set configuration"));
@ -42,6 +44,9 @@ void SonarConfig::sonarTypeChanged(int index) @@ -42,6 +44,9 @@ void SonarConfig::sonarTypeChanged(int index)
void SonarConfig::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
if (parameterName == "SONAR_ENABLE")
{
if (value.toInt() == 0)

3
src/ui/configuration/StandardParamConfig.cc

@ -31,6 +31,9 @@ void StandardParamConfig::addCombo(QString title,QString description,QString par @@ -31,6 +31,9 @@ void StandardParamConfig::addCombo(QString title,QString description,QString par
}
void StandardParamConfig::parameterChanged(int uas, int component, QString parameterName, QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
if (paramToWidgetMap.contains(parameterName))
{
if (value.type() == QVariant::Double)

1
src/ui/configuration/terminalconsole.cpp

@ -257,6 +257,7 @@ void TerminalConsole::setBaudRate(int index) @@ -257,6 +257,7 @@ void TerminalConsole::setBaudRate(int index)
void TerminalConsole::setLink(int index)
{
Q_UNUSED(index);
m_settings.name = ui->linkComboBox->currentText();
qDebug() << "Changed Link to:" << m_settings.name;

2
src/ui/designer/QGCRadioChannelDisplay.cpp

@ -34,6 +34,8 @@ void QGCRadioChannelDisplay::setOrientation(Qt::Orientation orient) @@ -34,6 +34,8 @@ void QGCRadioChannelDisplay::setOrientation(Qt::Orientation orient)
void QGCRadioChannelDisplay::paintEvent(QPaintEvent *event)
{
Q_UNUSED(event);
//Values range from 0-3000.
//1500 is the middle, static servo value.
QPainter painter(this);

4
src/ui/designer/QGCToolWidget.cc

@ -192,6 +192,10 @@ QList<QString> QGCToolWidget::getParamList() @@ -192,6 +192,10 @@ QList<QString> QGCToolWidget::getParamList()
}
void QGCToolWidget::setParameterValue(int uas, int component, QString parameterName, const QVariant value)
{
Q_UNUSED(uas);
Q_UNUSED(component);
Q_UNUSED(value);
QString widgetName = getTitle();
int size = settingsMap["count"].toInt();
if (paramToItemMap.contains(parameterName))

2
src/ui/linechart/IncrementalPlot.h

@ -61,8 +61,6 @@ private: @@ -61,8 +61,6 @@ private:
int d_count;
QwtArray<double> d_x;
QwtArray<double> d_y;
QTimer *d_timer;
int d_timerCount;
};
/**

3
src/ui/uas/UASQuickView.cc

@ -190,6 +190,7 @@ void UASQuickView::sortItems(int columncount) @@ -190,6 +190,7 @@ void UASQuickView::sortItems(int columncount)
}
void UASQuickView::resizeEvent(QResizeEvent *evt)
{
Q_UNUSED(evt);
recalculateItemTextSizing();
}
void UASQuickView::recalculateItemTextSizing()
@ -273,6 +274,8 @@ void UASQuickView::valueChanged(const int uasId, const QString& name, const QStr @@ -273,6 +274,8 @@ void UASQuickView::valueChanged(const int uasId, const QString& name, const QStr
{
Q_UNUSED(uasId);
Q_UNUSED(unit);
Q_UNUSED(msec);
bool ok;
double value = variant.toDouble(&ok);
QMetaType::Type metaType = static_cast<QMetaType::Type>(variant.type());

2
src/ui/uas/UASQuickViewGaugeItem.cc

@ -15,6 +15,8 @@ void UASQuickViewGaugeItem::setTitle(QString title) @@ -15,6 +15,8 @@ void UASQuickViewGaugeItem::setTitle(QString title)
}
void UASQuickViewGaugeItem::resizeEvent(QResizeEvent *event)
{
Q_UNUSED(event);
QFont valuefont = valueLabel->font();
QFont titlefont = titleLabel->font();
valuefont.setPixelSize(this->height() / 2.0);

2
src/ui/uas/UASQuickViewItemSelect.cc

@ -59,6 +59,8 @@ void UASQuickViewItemSelect::addItem(QString item,bool enabled) @@ -59,6 +59,8 @@ void UASQuickViewItemSelect::addItem(QString item,bool enabled)
}
void UASQuickViewItemSelect::resizeEvent(QResizeEvent *event)
{
Q_UNUSED(event);
/*for (int i=0;i<m_checkBoxList.size();i++)
{
ui.gridLayout->removeWidget(m_checkBoxList[i]);

4
src/ui/uas/UASQuickViewTextItem.cc

@ -119,7 +119,10 @@ void UASQuickViewTextItem::setValuePixelSize(int size) @@ -119,7 +119,10 @@ void UASQuickViewTextItem::setValuePixelSize(int size)
void UASQuickViewTextItem::resizeEvent(QResizeEvent *event)
{
Q_UNUSED(event);
return;
#if 0
// code ifdef'ed out to silence warnings
QFont valuefont = valueLabel->font();
QFont titlefont = titleLabel->font();
valuefont.setPixelSize(this->height());
@ -158,4 +161,5 @@ titlefont.setPixelSize(valuefont.pixelSize() / 2.0); @@ -158,4 +161,5 @@ titlefont.setPixelSize(valuefont.pixelSize() / 2.0);
valueLabel->setFont(valuefont);
titleLabel->setFont(titlefont);
update();
#endif
}

1
src/ui/uas/UASQuickViewTextItem.h

@ -17,7 +17,6 @@ protected: @@ -17,7 +17,6 @@ protected:
private:
QLabel *titleLabel;
QLabel *valueLabel;
QSpacerItem *spacerItem;
};
#endif // UASQUICKVIEWTEXTITEM_H

Loading…
Cancel
Save