Skip to content

Commit

Permalink
Fixed #519: Activity Manager - Missing an empty Promagation Mode
Browse files Browse the repository at this point in the history
  • Loading branch information
foldynl committed Nov 26, 2024
1 parent e0a78ca commit 082ca7d
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 11 deletions.
8 changes: 4 additions & 4 deletions data/Data.h
Original file line number Diff line number Diff line change
Expand Up @@ -119,10 +119,10 @@ class Data : public QObject

DxccStatus dxccStatus(int dxcc, const QString &band, const QString &mode);
QStringList contestList();
QStringList propagationModesList() { return propagationModes.values(); }
QStringList propagationModesIDList() { return propagationModes.keys(); }
QString propagationModeTextToID(const QString &propagationText) { return propagationModes.key(propagationText);}
QString propagationModeIDToText(const QString &propagationID) { return propagationModes.value(propagationID);}
QStringList propagationModesList() const { return QStringList{""} + propagationModes.values(); }
QStringList propagationModesIDList() const { return QStringList{""} + propagationModes.keys(); }
QString propagationModeTextToID(const QString &propagationText) const { return propagationModes.key(propagationText);}
QString propagationModeIDToText(const QString &propagationID) const { return propagationModes.value(propagationID);}
DxccEntity lookupDxcc(const QString &callsign);
DxccEntity lookupDxccID(const int dxccID);
SOTAEntity lookupSOTA(const QString &SOTACode);
Expand Down
2 changes: 1 addition & 1 deletion ui/LogbookWidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ LogbookWidget::LogbookWidget(QWidget *parent) :
ui->contactTable->setItemDelegateForColumn(LogbookModel::COLUMN_NR_PINGS, new UnitFormatDelegate("", 0, 1, ui->contactTable));
ui->contactTable->setItemDelegateForColumn(LogbookModel::COLUMN_NOTES_INTL, new TextBoxDelegate(this));
ui->contactTable->setItemDelegateForColumn(LogbookModel::COLUMN_NOTES, new TextBoxDelegate(this));
ui->contactTable->setItemDelegateForColumn(LogbookModel::COLUMN_PROP_MODE, new ComboFormatDelegate(QStringList()<<" "<< Data::instance()->propagationModesIDList(), ui->contactTable));
ui->contactTable->setItemDelegateForColumn(LogbookModel::COLUMN_PROP_MODE, new ComboFormatDelegate(Data::instance()->propagationModesIDList(), ui->contactTable));
ui->contactTable->setItemDelegateForColumn(LogbookModel::COLUMN_QRZCOM_QSO_UPLOAD_DATE, new DateFormatDelegate());
ui->contactTable->setItemDelegateForColumn(LogbookModel::COLUMN_QRZCOM_QSO_UPLOAD_STATUS, new ComboFormatDelegate(Data::instance()->uploadStatusEnum, ui->contactTable));
ui->contactTable->setItemDelegateForColumn(LogbookModel::COLUMN_QSO_COMPLETE, new ComboFormatDelegate(Data::instance()->qsoCompleteEnum, ui->contactTable));
Expand Down
4 changes: 1 addition & 3 deletions ui/NewContactWidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -172,9 +172,7 @@ NewContactWidget::NewContactWidget(QWidget *parent) :
/**********************/
/* Propagation Combo */
/**********************/
QStringList propagationModeList = Data::instance()->propagationModesList();
propagationModeList.prepend("");
QStringListModel* propagationModeModel = new QStringListModel(propagationModeList, this);
QStringListModel* propagationModeModel = new QStringListModel(Data::instance()->propagationModesList(), this);
ui->propagationModeEdit->setModel(propagationModeModel);

/***************/
Expand Down
4 changes: 1 addition & 3 deletions ui/QSODetailDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -242,9 +242,7 @@ QSODetailDialog::QSODetailDialog(const QSqlRecord &qso,
ui->qslSentViaBox->addItem(tr("Electronic"), QVariant("E"));

/* Propagation */
QStringList propagationModeList = Data::instance()->propagationModesList();
propagationModeList.prepend("");
QStringListModel* propagationModeModel = new QStringListModel(propagationModeList, this);
QStringListModel* propagationModeModel = new QStringListModel(Data::instance()->propagationModesList(), this);
ui->propagationModeEdit->setModel(propagationModeModel);

/* Sat Modes & sat names */
Expand Down

0 comments on commit 082ca7d

Please sign in to comment.