mirror of
https://github.com/ea4k/klog.git
synced 2024-09-21 18:38:19 +00:00
Mode and band shown improvement
This commit is contained in:
parent
a012a6bc2e
commit
69aa242491
4
TODO
4
TODO
@ -45,7 +45,6 @@ KLog 0.9.2
|
||||
TODO: Add a message to show if a Spot/QSO is valid for the current year DX-Marathon
|
||||
TODO: When importing an ADIF file with several logs, create automatically the logs as detected.
|
||||
TODO: Remove all not needed fields from SetupPageLogNew::gatherAndSend() the type is enough
|
||||
TODO: Add another tab in the botton to list the DXCC status.
|
||||
TODO: Add an option to auto-complete info (QTH, Locator, Name, QSL Manager(qsl_via), IOTA, AWARD, Entity...) from previously worked QSO.
|
||||
TODO: Run in memory
|
||||
TODO: Keep adapting to ADIF 3.0.4
|
||||
@ -54,6 +53,9 @@ NEXT:
|
||||
TODO: Some Entities have more than one CQ zone. Create a way to manage it and allow the user to select (combobox?)
|
||||
TODO: Some Entities are not recognized by ARRL (I, IG9, IT9 are the same ARRL id entities but different ones). Maybe I should not be working
|
||||
with ARRLid or maybe I should detect special ones and "id+10000" so >10000 ids are special ones.
|
||||
TODO: Add a Default band & mode in the setup dialog (MainWindow::slotClearButtonClicked, ...)
|
||||
TODO: Add another tab in the botton to list the DXCC status.
|
||||
TODO: checkIfNewBandOrMode() is not being used. Code should be removed...
|
||||
|
||||
|
||||
KLog 0.9.3
|
||||
|
108
awards.cpp
108
awards.cpp
@ -292,7 +292,7 @@ bool Awards::isThisSpotConfirmed(const QStringList _qs)
|
||||
int Awards::getDXStatus (const QStringList _qs)
|
||||
{
|
||||
|
||||
qDebug() << "Awards::getDXStatus: Call: " << _qs.at(0) << "/ Band: " << _qs.at(1) << "/ Mode: " << _qs.at(2) << "/ Log: " << _qs.at(3) << endl;
|
||||
////qDebug() << "Awards::getDXStatus: Call: " << _qs.at(0) << "/ Band: " << _qs.at(1) << "/ Mode: " << _qs.at(2) << "/ Log: " << _qs.at(3) << endl;
|
||||
// Receives: QStringList _qs;
|
||||
//_qs << QRZ << BandId << << ModeId << lognumber;
|
||||
|
||||
@ -340,14 +340,14 @@ int Awards::getDXStatus (const QStringList _qs)
|
||||
return -1;
|
||||
}
|
||||
|
||||
qDebug() << "Awards::getDXStatus: dxccEntity: " << QString::number(dxccEntity) << endl;
|
||||
//qDebug() << "Awards::getDXStatus: dxccEntity: " << QString::number(dxccEntity) << endl;
|
||||
|
||||
|
||||
bool checkingMode = true;
|
||||
if (_mode==-1)
|
||||
{
|
||||
checkingMode = false;
|
||||
//qDebug() << "Awards::getDXStatus: checkingMode = FALSE" << endl;
|
||||
////qDebug() << "Awards::getDXStatus: checkingMode = FALSE" << endl;
|
||||
}
|
||||
// dxccStatusMode(const int _ent, const int _mode, const int _logNumber) //-1 error / 0 Not worked / 1 worked / 2 confirmed
|
||||
|
||||
@ -359,12 +359,12 @@ int Awards::getDXStatus (const QStringList _qs)
|
||||
checkingMode = false;
|
||||
}
|
||||
|
||||
qDebug() << "Awards::getDXStatus: wb=" << QString::number(wb) << " - wm=" << QString::number(wm) << endl;
|
||||
//qDebug() << "Awards::getDXStatus: wb=" << QString::number(wb) << " - wm=" << QString::number(wm) << endl;
|
||||
|
||||
switch(dxccStatus(dxccEntity, _logNumber))
|
||||
{
|
||||
case 0:
|
||||
qDebug() << "Awards::getDXStatus: return 0" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 0" << endl;
|
||||
return 0; // ATNO
|
||||
break;
|
||||
case 1: // Worked, not confirmed
|
||||
@ -375,18 +375,18 @@ int Awards::getDXStatus (const QStringList _qs)
|
||||
{
|
||||
if (wm==1)
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 4" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 4" << endl;
|
||||
return 4;
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 1" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 1" << endl;
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 4 nc" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 4 nc" << endl;
|
||||
return 4;
|
||||
}
|
||||
break;
|
||||
@ -395,24 +395,24 @@ int Awards::getDXStatus (const QStringList _qs)
|
||||
{
|
||||
if (wm==1)
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 3" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 3" << endl;
|
||||
return 3;
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 2" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 2" << endl;
|
||||
return 2;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 3 nc" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 3 nc" << endl;
|
||||
return 3;
|
||||
}
|
||||
|
||||
break;
|
||||
default: // ERROR
|
||||
qDebug() << "Awards::getDXStatus: return -1 - 1" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return -1 - 1" << endl;
|
||||
return -1;
|
||||
break;
|
||||
}
|
||||
@ -425,23 +425,23 @@ int Awards::getDXStatus (const QStringList _qs)
|
||||
{
|
||||
if (wm==2)
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 13" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 13" << endl;
|
||||
return 13;
|
||||
}
|
||||
else if (wm==1)
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 12" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 12" << endl;
|
||||
return 12;
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 11" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 11" << endl;
|
||||
return 11;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 13 nc" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 13 nc" << endl;
|
||||
return 13;
|
||||
}
|
||||
|
||||
@ -454,12 +454,12 @@ int Awards::getDXStatus (const QStringList _qs)
|
||||
{
|
||||
if (wm==1)
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 8" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 8" << endl;
|
||||
return 8;
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 6" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 6" << endl;
|
||||
return 6;
|
||||
}
|
||||
}
|
||||
@ -467,12 +467,12 @@ int Awards::getDXStatus (const QStringList _qs)
|
||||
{
|
||||
if (wm==1)
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 7" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 7" << endl;
|
||||
return 7;
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 5" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return 5" << endl;
|
||||
return 5;
|
||||
}
|
||||
}
|
||||
@ -480,18 +480,26 @@ int Awards::getDXStatus (const QStringList _qs)
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return 8 nc" << endl;
|
||||
return 8;
|
||||
if (wb==0)
|
||||
{
|
||||
//qDebug() << "Awards::getDXStatus: return 7 nc" << endl;
|
||||
return 7;
|
||||
}
|
||||
else
|
||||
{
|
||||
//qDebug() << "Awards::getDXStatus: return 8 nc" << endl;
|
||||
return 8;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "Awards::getDXStatus: return -1 - 2" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return -1 - 2" << endl;
|
||||
return -1;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
qDebug() << "Awards::getDXStatus: return -1 default" << endl;
|
||||
//qDebug() << "Awards::getDXStatus: return -1 default" << endl;
|
||||
return -1;
|
||||
break;
|
||||
|
||||
@ -504,7 +512,7 @@ int Awards::getDXStatus (const QStringList _qs)
|
||||
|
||||
int Awards::dxccStatusBandMode(const int _ent, const int _band, const int _mode, const int _logNumber, bool _checkingMode)
|
||||
{//-1 error / 0 Not worked / 1 worked / 2 confirmed
|
||||
qDebug() << "Awards::dxccStatusBandMode: " << QString::number(_ent) << "/" << QString::number(_band) << "/" << QString::number(_mode) << endl;
|
||||
//qDebug() << "Awards::dxccStatusBandMode: " << QString::number(_ent) << "/" << QString::number(_band) << "/" << QString::number(_mode) << endl;
|
||||
QSqlQuery query = QSqlQuery();
|
||||
QString queryString = QString();
|
||||
|
||||
@ -528,29 +536,29 @@ int Awards::dxccStatusBandMode(const int _ent, const int _band, const int _mode,
|
||||
{
|
||||
if(query.value(0).toInt() == 1)
|
||||
{
|
||||
qDebug() << "Awards::dxccStatusBandMode: return - 2" << endl;
|
||||
//qDebug() << "Awards::dxccStatusBandMode: return - 2" << endl;
|
||||
return 2;
|
||||
}
|
||||
else if(query.value(0).toInt() == 0)
|
||||
{
|
||||
qDebug() << "Awards::dxccStatusBandMode: return - 1" << endl;
|
||||
//qDebug() << "Awards::dxccStatusBandMode: return - 1" << endl;
|
||||
return 1;
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "Awards::dxccStatusBandMode: return - 0-1" << endl;
|
||||
//qDebug() << "Awards::dxccStatusBandMode: return - 0-1" << endl;
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "Awards::dxccStatusBandMode: return - 0-2" << endl;
|
||||
//qDebug() << "Awards::dxccStatusBandMode: return - 0-2" << endl;
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{ // No value => Not Worked
|
||||
qDebug() << "Awards::dxccStatusBandMode: return - 0-3" << endl;
|
||||
//qDebug() << "Awards::dxccStatusBandMode: return - 0-3" << endl;
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -558,7 +566,7 @@ int Awards::dxccStatusBandMode(const int _ent, const int _band, const int _mode,
|
||||
else
|
||||
{ // The query fails...
|
||||
//TODO: Manage the query error
|
||||
qDebug() << "Awards::dxccStatusBandMode: return - -1" << endl;
|
||||
//qDebug() << "Awards::dxccStatusBandMode: return - -1" << endl;
|
||||
return -1;
|
||||
}
|
||||
qDebug() << "Awards::dxccStatusBandMode: return - 0-4" << endl;
|
||||
@ -568,7 +576,7 @@ qDebug() << "Awards::dxccStatusBandMode: return - 0-4" << endl;
|
||||
|
||||
int Awards::dxccStatus(const int _ent, const int _logNumber)
|
||||
{//-1 error / 0 Not worked / 1 worked / 2 confirmed
|
||||
qDebug() << "Awards::dxccStatus: " << QString::number(_ent) << endl;
|
||||
//qDebug() << "Awards::dxccStatus: " << QString::number(_ent) << endl;
|
||||
QSqlQuery query = QSqlQuery();
|
||||
QString queryString = QString();
|
||||
int worked = 0;
|
||||
@ -591,17 +599,17 @@ int Awards::dxccStatus(const int _ent, const int _logNumber)
|
||||
}
|
||||
}
|
||||
}
|
||||
qDebug() << "Awards::dxccStatus: return "<< QString::number(worked) << endl;
|
||||
//qDebug() << "Awards::dxccStatus: return "<< QString::number(worked) << endl;
|
||||
return worked;
|
||||
|
||||
}
|
||||
else
|
||||
{ // The query fails...
|
||||
//TODO: Manage the query error
|
||||
qDebug() << "Awards::dxccStatus: return -1" << endl;
|
||||
//qDebug() << "Awards::dxccStatus: return -1" << endl;
|
||||
return -1;
|
||||
}
|
||||
qDebug() << "Awards::dxccStatus: return 0" << endl;
|
||||
//qDebug() << "Awards::dxccStatus: return 0" << endl;
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -685,7 +693,7 @@ QColor Awards::getQRZDXStatusColor(const QStringList _qs)
|
||||
QString Awards::getDXStatusString (const int _status)
|
||||
{
|
||||
|
||||
qDebug() << "Awards::getDXStatusString: " << QString::number(_status) << endl;
|
||||
//qDebug() << "Awards::getDXStatusString: " << QString::number(_status) << endl;
|
||||
|
||||
QString message = QString();
|
||||
|
||||
@ -1897,29 +1905,29 @@ int Awards::dxccStatusBand(const int _ent, const int _band, const int _logNumber
|
||||
{
|
||||
if(query.value(0).toInt() == 1) // Confirmed
|
||||
{
|
||||
qDebug() << "Awards::dxccStatusBand: return - 2" << endl;
|
||||
//qDebug() << "Awards::dxccStatusBand: return - 2" << endl;
|
||||
return 2;
|
||||
}
|
||||
else if(query.value(0).toInt() == 0) // Worked
|
||||
{
|
||||
qDebug() << "Awards::dxccStatusBand: return - 1" << endl;
|
||||
//qDebug() << "Awards::dxccStatusBand: return - 1" << endl;
|
||||
return 1;
|
||||
}
|
||||
else // Not worked
|
||||
{
|
||||
qDebug() << "Awards::dxccStatusBand: return - 0" << endl;
|
||||
//qDebug() << "Awards::dxccStatusBand: return - 0" << endl;
|
||||
return 0;
|
||||
}
|
||||
} // Not present => Not worked
|
||||
else
|
||||
{
|
||||
qDebug() << "Awards::dxccStatusBand: return - 0.1" << endl;
|
||||
//qDebug() << "Awards::dxccStatusBand: return - 0.1" << endl;
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
else // Not present => Not worked
|
||||
{ // No value => Not Worked
|
||||
qDebug() << "Awards::dxccStatusBand: return - 0.2" << endl;
|
||||
//qDebug() << "Awards::dxccStatusBand: return - 0.2" << endl;
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -1927,7 +1935,7 @@ int Awards::dxccStatusBand(const int _ent, const int _band, const int _logNumber
|
||||
else
|
||||
{ // The query fails...
|
||||
//TODO: Manage the query error
|
||||
qDebug() << "Awards::dxccStatusBand: return - -1" << endl;
|
||||
//qDebug() << "Awards::dxccStatusBand: return - -1" << endl;
|
||||
return -1;
|
||||
}
|
||||
qDebug() << "Awards::dxccStatusBand: return - 0.3" << endl;
|
||||
@ -1937,13 +1945,13 @@ qDebug() << "Awards::dxccStatusBand: return - 0.3" << endl;
|
||||
int Awards::dxccStatusMode(const int _ent, const int _mode, const int _logNumber) //-1 error / 0 Not worked / 1 worked / 2 confirmed
|
||||
{
|
||||
//-1 error / 0 Not worked / 1 worked / 2 confirmed
|
||||
qDebug() << "Awards::dxccStatusMode: " << QString::number(_ent) << "/" << QString::number(_mode) << endl;
|
||||
//qDebug() << "Awards::dxccStatusMode: " << QString::number(_ent) << "/" << QString::number(_mode) << endl;
|
||||
|
||||
QSqlQuery query = QSqlQuery();
|
||||
QString queryString = QString();
|
||||
if (_mode == -1)
|
||||
{
|
||||
qDebug() << "Awards::dxccStatusMode: return - -1" << endl;
|
||||
//qDebug() << "Awards::dxccStatusMode: return - -1" << endl;
|
||||
return -1;
|
||||
}
|
||||
|
||||
@ -1958,29 +1966,29 @@ int Awards::dxccStatusMode(const int _ent, const int _mode, const int _logNumber
|
||||
{
|
||||
if(query.value(0).toInt() == 1) // Confirmed
|
||||
{
|
||||
qDebug() << "Awards::dxccStatusMode: return - 2" << endl;
|
||||
//qDebug() << "Awards::dxccStatusMode: return - 2" << endl;
|
||||
return 2;
|
||||
}
|
||||
else if(query.value(0).toInt() == 0) // Worked
|
||||
{
|
||||
qDebug() << "Awards::dxccStatusMode: return - 1" << endl;
|
||||
//qDebug() << "Awards::dxccStatusMode: return - 1" << endl;
|
||||
return 1;
|
||||
}
|
||||
else // Not worked
|
||||
{
|
||||
qDebug() << "Awards::dxccStatusMode: return - 0" << endl;
|
||||
//qDebug() << "Awards::dxccStatusMode: return - 0" << endl;
|
||||
return 0;
|
||||
}
|
||||
} // Not present => Not worked
|
||||
else
|
||||
{
|
||||
qDebug() << "Awards::dxccStatusMode: return - 0.1" << endl;
|
||||
//qDebug() << "Awards::dxccStatusMode: return - 0.1" << endl;
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
else // Not present => Not worked
|
||||
{ // No value => Not Worked
|
||||
qDebug() << "Awards::dxccStatusMode: return - 0.2" << endl;
|
||||
//qDebug() << "Awards::dxccStatusMode: return - 0.2" << endl;
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -1988,7 +1996,7 @@ int Awards::dxccStatusMode(const int _ent, const int _mode, const int _logNumber
|
||||
else
|
||||
{ // The query fails...
|
||||
//TODO: Manage the query error
|
||||
qDebug() << "Awards::dxccStatusMode: return - -1" << endl;
|
||||
//qDebug() << "Awards::dxccStatusMode: return - -1" << endl;
|
||||
return -1;
|
||||
}
|
||||
qDebug() << "Awards::dxccStatusMode: return - 0.3" << endl;
|
||||
|
@ -279,7 +279,16 @@ QStringList DataProxy_SQLite::getModes()
|
||||
QStringList DataProxy_SQLite::getBandsInLog(const int _log)
|
||||
{
|
||||
QStringList bands = QStringList();
|
||||
QString stringQuery = QString("SELECT DISTINCT band.name FROM log, band WHERE band.id = log.bandid AND log.lognumber='%1'").arg(_log);
|
||||
QString stringQuery = QString();
|
||||
if (_log <= 0)
|
||||
{
|
||||
stringQuery = QString("SELECT DISTINCT band.name FROM log, band WHERE band.id = log.bandid ORDER BY band.id DESC");
|
||||
}
|
||||
else
|
||||
{
|
||||
stringQuery = QString("SELECT DISTINCT band.name FROM log, band WHERE band.id = log.bandid AND log.lognumber='%1' ORDER BY band.id DESC").arg(_log);
|
||||
}
|
||||
|
||||
QSqlQuery query(stringQuery);
|
||||
while (query.next()) {
|
||||
if (query.isValid()){
|
||||
@ -292,13 +301,24 @@ QStringList DataProxy_SQLite::getBandsInLog(const int _log)
|
||||
QStringList DataProxy_SQLite::getModesInLog(const int _log)
|
||||
{
|
||||
QStringList modes = QStringList();
|
||||
QString stringQuery = QString("SELECT DISTINCT mode.submode FROM log, mode WHERE mode.id = log.modeid AND log.lognumber='%1'").arg(_log);
|
||||
QString stringQuery = QString();
|
||||
if (_log <=0 )
|
||||
{
|
||||
stringQuery = QString("SELECT mode.id, mode.submode, COUNT (mode.submode) FROM log, mode WHERE mode.id = log.modeid GROUP BY mode.submode ORDER BY count (mode.submode) DESC");
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
stringQuery = QString("SELECT mode.id, mode.submode, COUNT (mode.submode) FROM log, mode WHERE mode.id = log.modeid AND log.lognumber='%1' GROUP BY mode.submode ORDER BY count (mode.submode) DESC").arg(_log);
|
||||
}
|
||||
|
||||
QSqlQuery query(stringQuery);
|
||||
while (query.next()) {
|
||||
if (query.isValid()){
|
||||
modes << query.value(0).toString();
|
||||
modes << query.value(1).toString();
|
||||
}
|
||||
}
|
||||
//qDebug() << "DataProxy_SQLite::getModesInLog: " << modes.join(" - ") << endl;
|
||||
return modes;
|
||||
}
|
||||
|
||||
@ -1188,7 +1208,7 @@ int DataProxy_SQLite::getCQzonYear(const int _year, const int _logNumber)
|
||||
|
||||
bool DataProxy_SQLite::newDXMarathon(const int _dxcc, const int _cq, const int _year, const int _logNumber)
|
||||
{
|
||||
qDebug() << "DataProxy_SQLite::newDXMarathon" << endl;
|
||||
//qDebug() << "DataProxy_SQLite::newDXMarathon" << endl;
|
||||
QSqlQuery query;
|
||||
QString stringQuery;
|
||||
bool sqlOK;
|
||||
@ -1206,12 +1226,12 @@ bool DataProxy_SQLite::newDXMarathon(const int _dxcc, const int _cq, const int _
|
||||
{
|
||||
if ( (query.value(0)).toInt() == _dxcc)
|
||||
{
|
||||
qDebug() << "DataProxy_SQLite::newDXMarathon - Existing DXCC" << endl;
|
||||
//qDebug() << "DataProxy_SQLite::newDXMarathon - Existing DXCC" << endl;
|
||||
existingDXCC = true;
|
||||
}
|
||||
if ( (query.value(1)).toInt() == _cq)
|
||||
{
|
||||
qDebug() << "DataProxy_SQLite::newDXMarathon - Existing CQz" << endl;
|
||||
//qDebug() << "DataProxy_SQLite::newDXMarathon - Existing CQz" << endl;
|
||||
existingCQz = true;
|
||||
}
|
||||
|
||||
@ -1220,21 +1240,21 @@ bool DataProxy_SQLite::newDXMarathon(const int _dxcc, const int _cq, const int _
|
||||
|
||||
if (existingDXCC && existingCQz)
|
||||
{
|
||||
qDebug() << "DataProxy_SQLite::newDXMarathon - FALSE" << endl;
|
||||
//qDebug() << "DataProxy_SQLite::newDXMarathon - FALSE" << endl;
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "DataProxy_SQLite::newDXMarathon - TRUE1" << endl;
|
||||
//qDebug() << "DataProxy_SQLite::newDXMarathon - TRUE1" << endl;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "DataProxy_SQLite::newDXMarathon - TRUE2" << endl;
|
||||
//qDebug() << "DataProxy_SQLite::newDXMarathon - TRUE2" << endl;
|
||||
return true; // It is an error inthe query but Work First Worry Later, let us work that QSO.
|
||||
}
|
||||
qDebug() << "DataProxy_SQLite::newDXMarathon - TRUE3" << endl;
|
||||
//qDebug() << "DataProxy_SQLite::newDXMarathon - TRUE3" << endl;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -327,6 +327,12 @@ void DXClusterWidget::slotClusterDataArrived()
|
||||
qs << dxCall << spotBand << "-1" << QString::number(currentLog) ;
|
||||
|
||||
dxSpotColor = awards->getQRZDXStatusColor(qs);
|
||||
|
||||
if (awards->isDXMarathonNeed(world->getQRZARRLId(dxCall), world->getQRZCqz(dxCall), QDateTime::currentDateTime().date().year(), currentLog))
|
||||
{
|
||||
dxClusterString = dxClusterString + " ### Needed for DXMarathon - " + QString::number(QDateTime::currentDateTime().date().year()) + " ###";
|
||||
}
|
||||
|
||||
qDebug() << "DX de ->" << "Spotter: " << spotter << "Freq: "<< dxFrequency << "DX: " << dxCall << endl;
|
||||
|
||||
}
|
||||
@ -350,6 +356,10 @@ void DXClusterWidget::slotClusterDataArrived()
|
||||
|
||||
|
||||
dxSpotColor = awards->getQRZDXStatusColor(qs);
|
||||
if (awards->isDXMarathonNeed(world->getQRZARRLId(dxCall), world->getQRZCqz(dxCall), QDateTime::currentDateTime().date().year(), currentLog))
|
||||
{
|
||||
dxClusterString = dxClusterString + " ### Needed for DXMarathon - " + QString::number(QDateTime::currentDateTime().date().year()) + " ###";
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -9,7 +9,7 @@
|
||||
|
||||
eLogClubLog::eLogClubLog() : QObject(0)
|
||||
{
|
||||
qDebug() << "eLogClubLog::eLogClubLog" << endl;
|
||||
//qDebug() << "eLogClubLog::eLogClubLog" << endl;
|
||||
call= QString();
|
||||
email = QString();
|
||||
pass = QString();
|
||||
@ -21,13 +21,13 @@ eLogClubLog::eLogClubLog() : QObject(0)
|
||||
|
||||
eLogClubLog::~eLogClubLog()
|
||||
{
|
||||
qDebug() << "eLogClubLog::~eLogClubLog" << endl;
|
||||
//qDebug() << "eLogClubLog::~eLogClubLog" << endl;
|
||||
}
|
||||
|
||||
|
||||
void eLogClubLog::slotQsoUploadFinished(QNetworkReply *data)
|
||||
{
|
||||
qDebug() << "eLogClubLog::slotQsoUploadFinished" << endl;
|
||||
//qDebug() << "eLogClubLog::slotQsoUploadFinished" << endl;
|
||||
|
||||
result = data->error();
|
||||
//qDebug() << "eLogClubLog::slotQsoUploadFinished - Result = " << QString::number(result) << endl;
|
||||
@ -47,25 +47,25 @@ eLogClubLog::~eLogClubLog()
|
||||
{
|
||||
|
||||
text = "ClubLog: " + prepareToTranslate(sdata);
|
||||
qDebug() << sdata;
|
||||
//qDebug() << sdata;
|
||||
|
||||
|
||||
}
|
||||
else if (result == QNetworkReply::HostNotFoundError)
|
||||
{
|
||||
qDebug() << "eLogClubLog::slotQsoUploadFinished - Result = Host Not found! = " << QString::number(result) << endl;
|
||||
//qDebug() << "eLogClubLog::slotQsoUploadFinished - Result = Host Not found! = " << QString::number(result) << endl;
|
||||
text = "ClubLog: " + tr("Host not found!");
|
||||
//TODO: Mark the previous QSO as not sent to clublog
|
||||
}
|
||||
else if (result == QNetworkReply::TimeoutError)
|
||||
{
|
||||
qDebug() << "eLogClubLog::slotQsoUploadFinished - Result = Time out error! = " << QString::number(result) << endl;
|
||||
//qDebug() << "eLogClubLog::slotQsoUploadFinished - Result = Time out error! = " << QString::number(result) << endl;
|
||||
text = "ClubLog: " + tr("Timeout error!");
|
||||
//TODO: Mark the previous QSO as not sent to clublog
|
||||
}
|
||||
else if (result == 202)
|
||||
{
|
||||
qDebug() << "eLogClubLog::slotQsoUploadFinished - Result = Password Error! = " << QString::number(result) << endl;
|
||||
//qDebug() << "eLogClubLog::slotQsoUploadFinished - Result = Password Error! = " << QString::number(result) << endl;
|
||||
text = "ClubLog: " + tr("It seems to be a PASSWORD ERROR, check your password");
|
||||
|
||||
int ret = QMessageBox::warning(0, tr("KLog - clublog"),
|
||||
@ -79,7 +79,7 @@ eLogClubLog::~eLogClubLog()
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "eLogClubLog::slotQsoUploadFinished - Result = UNDEFINED = " << QString::number(result) << endl;
|
||||
//qDebug() << "eLogClubLog::slotQsoUploadFinished - Result = UNDEFINED = " << QString::number(result) << endl;
|
||||
text = "ClubLog: " + tr("Undefined error...");
|
||||
//TODO: Mark the previous QSO as not sent to clublog
|
||||
}
|
||||
@ -92,7 +92,7 @@ eLogClubLog::~eLogClubLog()
|
||||
|
||||
void eLogClubLog::slotFileUploadFinished(QNetworkReply *data)
|
||||
{
|
||||
qDebug() << "eLogClubLog::slotFileUploadFinished" << endl;
|
||||
//qDebug() << "eLogClubLog::slotFileUploadFinished" << endl;
|
||||
|
||||
result = data->error();
|
||||
//qDebug() << "eLogClubLog::slotFileUploadFinished - Result = " << QString::number(result) << endl;
|
||||
@ -106,24 +106,24 @@ void eLogClubLog::slotFileUploadFinished(QNetworkReply *data)
|
||||
{
|
||||
|
||||
text = "ClubLog: " + prepareToTranslate(sdata);
|
||||
qDebug() << "eLogClubLog::slotFileUploadFinished - Result = NoError = " << QString::number(result) << endl;
|
||||
qDebug() << sdata;
|
||||
//qDebug() << "eLogClubLog::slotFileUploadFinished - Result = NoError = " << QString::number(result) << endl;
|
||||
//qDebug() << sdata;
|
||||
|
||||
|
||||
}
|
||||
else if (result == QNetworkReply::HostNotFoundError)
|
||||
{
|
||||
qDebug() << "eLogClubLog::slotFileUploadFinished - Result = Host Not found! = " << QString::number(result) << endl;
|
||||
//qDebug() << "eLogClubLog::slotFileUploadFinished - Result = Host Not found! = " << QString::number(result) << endl;
|
||||
text = "ClubLog: " + tr("Host not found!");
|
||||
}
|
||||
else if (result == QNetworkReply::TimeoutError)
|
||||
{
|
||||
qDebug() << "eLogClubLog::slotFileUploadFinished - Result = Time out error! = " << QString::number(result) << endl;
|
||||
//qDebug() << "eLogClubLog::slotFileUploadFinished - Result = Time out error! = " << QString::number(result) << endl;
|
||||
text = "ClubLog: " + tr("Timeout error!");
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "eLogClubLog::slotFileUploadFinished - Result = UNDEFINED = " << QString::number(result) << endl;
|
||||
//qDebug() << "eLogClubLog::slotFileUploadFinished - Result = UNDEFINED = " << QString::number(result) << endl;
|
||||
text = "ClubLog: " + tr("Undefined error...");
|
||||
}
|
||||
|
||||
@ -133,15 +133,15 @@ void eLogClubLog::slotFileUploadFinished(QNetworkReply *data)
|
||||
}
|
||||
|
||||
void eLogClubLog::downloadProgress(qint64 received, qint64 total) {
|
||||
qDebug() << "eLogClubLog::downloadProgress: " << QString::number(received) << "/" << QString::number(total) << endl;
|
||||
//qDebug() << "eLogClubLog::downloadProgress: " << QString::number(received) << "/" << QString::number(total) << endl;
|
||||
|
||||
qDebug() << received << total;
|
||||
//qDebug() << received << total;
|
||||
emit actionShowProgres(received, total);
|
||||
}
|
||||
|
||||
void eLogClubLog::slotErrorManagement(QNetworkReply::NetworkError networkError)
|
||||
{
|
||||
qDebug() << "eLogClubLog::slotErrorManagement: " << QString::number(networkError) << endl;
|
||||
//qDebug() << "eLogClubLog::slotErrorManagement: " << QString::number(networkError) << endl;
|
||||
result = networkError;
|
||||
|
||||
if (result == QNetworkReply::NoError)
|
||||
@ -162,7 +162,7 @@ void eLogClubLog::slotErrorManagement(QNetworkReply::NetworkError networkError)
|
||||
|
||||
int eLogClubLog::sendQSO(QStringList _qso)
|
||||
{
|
||||
qDebug() << "eLogClubLog::sendQSO: " << call <<"/"<< email << "/" << pass << "/" << api << endl;
|
||||
//qDebug() << "eLogClubLog::sendQSO: " << call <<"/"<< email << "/" << pass << "/" << api << endl;
|
||||
//qDebug() << "eLogClubLog::sendQSO:: length = " << QString::number(_qso.length()) << endl;
|
||||
// First Data in the QStringList is the QSO id, not to be sent to clublog but used in the signal actionReturnDownload(const int _i, const int _qsoId);
|
||||
|
||||
@ -179,11 +179,11 @@ int eLogClubLog::sendQSO(QStringList _qso)
|
||||
{
|
||||
stationCallsign = _qso.last();
|
||||
}
|
||||
qDebug() << "eLogClubLog::sendQSO (stationCallsign = " << _qso.last() << ")" << endl;
|
||||
//qDebug() << "eLogClubLog::sendQSO (stationCallsign = " << _qso.last() << ")" << endl;
|
||||
_qso.removeLast();
|
||||
|
||||
QString qso = getClubLogAdif(_qso);
|
||||
qDebug() << "eLogClubLog::sendQSO: " << qso << endl;
|
||||
//qDebug() << "eLogClubLog::sendQSO: " << qso << endl;
|
||||
return sendData(qso);
|
||||
|
||||
}
|
||||
@ -191,7 +191,7 @@ int eLogClubLog::sendQSO(QStringList _qso)
|
||||
|
||||
int eLogClubLog::sendData(const QString _q)
|
||||
{
|
||||
qDebug() << "eLogClubLog::sendData: " << _q << endl;
|
||||
//qDebug() << "eLogClubLog::sendData: " << _q << endl;
|
||||
|
||||
QUrl serviceUrl = QUrl("https://secure.clublog.org/realtime.php");
|
||||
QByteArray postData;
|
||||
@ -204,12 +204,12 @@ int eLogClubLog::sendData(const QString _q)
|
||||
if ((useQSOStationCallsign) && (stationCallsign.length()>2))
|
||||
{
|
||||
params.addQueryItem("callsign",stationCallsign);
|
||||
qDebug() << "eLogClubLog::sendData - callsign 1: " << stationCallsign << endl;
|
||||
//qDebug() << "eLogClubLog::sendData - callsign 1: " << stationCallsign << endl;
|
||||
}
|
||||
else
|
||||
{
|
||||
params.addQueryItem("callsign",call);
|
||||
qDebug() << "eLogClubLog::sendData - callsign 2: " << call << endl;
|
||||
//qDebug() << "eLogClubLog::sendData - callsign 2: " << call << endl;
|
||||
}
|
||||
|
||||
params.addQueryItem("api",api);
|
||||
@ -325,7 +325,7 @@ ClubLog only accepts the following ADIF fields:
|
||||
|
||||
void eLogClubLog::setCredentials(const QString _call, const QString _email, const QString _pass, const bool _useQSOStationCall)
|
||||
{
|
||||
qDebug() << "eLogClubLog::setCredentials" << endl;
|
||||
//qDebug() << "eLogClubLog::setCredentials" << endl;
|
||||
call = _call;
|
||||
email = _email;
|
||||
pass = _pass;
|
||||
@ -336,7 +336,7 @@ void eLogClubLog::setCredentials(const QString _call, const QString _email, cons
|
||||
|
||||
int eLogClubLog::deleteQSO(QStringList _qso)
|
||||
{
|
||||
qDebug() << "eLogClubLog::deleteQSO: length = " << QString::number(_qso.length()) << endl;
|
||||
//qDebug() << "eLogClubLog::deleteQSO: length = " << QString::number(_qso.length()) << endl;
|
||||
if (_qso.length()!=17)
|
||||
{
|
||||
return -1;
|
||||
@ -352,7 +352,7 @@ int eLogClubLog::deleteQSO(QStringList _qso)
|
||||
QString qso = getClubLogAdif(_qso);
|
||||
qso.replace("<EOR>", replaceCall);
|
||||
|
||||
qDebug() << "eLogClubLog::deleteQSO: ready to send = " << qso << endl;
|
||||
//qDebug() << "eLogClubLog::deleteQSO: ready to send = " << qso << endl;
|
||||
|
||||
return sendData(qso);
|
||||
|
||||
@ -361,7 +361,7 @@ int eLogClubLog::deleteQSO(QStringList _qso)
|
||||
|
||||
QString eLogClubLog::prepareToTranslate(const QString _m)
|
||||
{
|
||||
qDebug() << "eLogClubLog:: = prepareToTranslate" << _m << endl;
|
||||
//qDebug() << "eLogClubLog:: = prepareToTranslate" << _m << endl;
|
||||
if (_m == "Callsign missing")
|
||||
{
|
||||
return tr("Callsign missing");
|
||||
|
@ -262,7 +262,7 @@ MainWindow::MainWindow(const QString _kontestDir, const QString tversion)
|
||||
timer = new QTimer(this);
|
||||
connect(timer, SIGNAL(timeout()), this, SLOT(slotUpdateTime()) );
|
||||
timer->start(1000);
|
||||
qDebug() << "MainWindow::MainWindow: 9" << endl;
|
||||
|
||||
previousQrz = "";
|
||||
qrzLineEdit = new QLineEdit;
|
||||
nameLineEdit = new QLineEdit;
|
||||
@ -481,7 +481,7 @@ MainWindow::MainWindow(const QString _kontestDir, const QString tversion)
|
||||
//qDebug() << "MainWindow::MainWindow: 16.2" << endl;
|
||||
}
|
||||
//qDebug() << "MainWindow::MainWindow: 17" << endl;
|
||||
checkIfNewBandOrMode();
|
||||
//checkIfNewBandOrMode();
|
||||
|
||||
if ( (contestMode == CQ_WW_SSB) || (contestMode == CQ_WW_CW) )
|
||||
{
|
||||
@ -506,9 +506,18 @@ MainWindow::MainWindow(const QString _kontestDir, const QString tversion)
|
||||
showAwards();
|
||||
}
|
||||
|
||||
|
||||
//bandComboBox->setCurrentIndex(bandComboBox->findText(_aux));
|
||||
currentBandShown = dataProxy->getIdFromBandName(bandComboBox->currentText());
|
||||
currentModeShown = dataProxy->getIdFromModeName(modeComboBox->currentText());
|
||||
currentBand = currentBandShown;
|
||||
currentMode = currentModeShown;
|
||||
|
||||
|
||||
slotClearButtonClicked();
|
||||
//logModel->select();
|
||||
|
||||
|
||||
upAndRunning = true;
|
||||
//qDebug() << "MainWindow::MainWindow: END" << endl;
|
||||
|
||||
@ -596,6 +605,8 @@ void MainWindow::slotBandComboBoxChanged(){
|
||||
|
||||
currentBandShown = dataProxy->getIdFromBandName(bandComboBox->currentText());
|
||||
currentModeShown = dataProxy->getIdFromModeName(modeComboBox->currentText());
|
||||
currentBand = currentBandShown;
|
||||
currentMode = currentModeShown;
|
||||
//currentModeShown = modeComboBox->currentIndex();
|
||||
i = checkIfWorkedB4(currentQrz);
|
||||
|
||||
@ -2783,7 +2794,7 @@ bool MainWindow::validCharactersInCall(const QString _qrz)
|
||||
}
|
||||
void MainWindow::slotQRZTextChanged()
|
||||
{
|
||||
qDebug() << "MainWindow::slotQRZTextChanged: " << qrzLineEdit->text() << " / Length: " << QString::number((qrzLineEdit->text()).size()) << endl;
|
||||
//qDebug()() << "MainWindow::slotQRZTextChanged: " << qrzLineEdit->text() << " / Length: " << QString::number((qrzLineEdit->text()).size()) << endl;
|
||||
if (cleaning)
|
||||
{
|
||||
return;
|
||||
@ -2801,7 +2812,7 @@ void MainWindow::slotQRZTextChanged()
|
||||
}
|
||||
//if (!world->checkQRZValidFormat(qrzLineEdit->text()))
|
||||
//{
|
||||
// qDebug() << "MainWindow::slotQRZTextChanged: NOT valid QRZ Format" << endl;
|
||||
//qDebug() << "MainWindow::slotQRZTextChanged: NOT valid QRZ Format" << endl;
|
||||
// return;
|
||||
//}
|
||||
|
||||
@ -3375,7 +3386,7 @@ void MainWindow::slotSpotItButtonClicked()
|
||||
|
||||
void MainWindow::slotClearButtonClicked()
|
||||
{
|
||||
qDebug() << "MainWindow::slotClearButtonClicked" << endl;
|
||||
//qDebug()() << "MainWindow::slotClearButtonClicked" << endl;
|
||||
cleaning = true;
|
||||
modify = false;
|
||||
OKButton->setText(tr("&Add"));
|
||||
@ -3387,8 +3398,11 @@ void MainWindow::slotClearButtonClicked()
|
||||
rstRXLineEdit->setText("59");
|
||||
qthLineEdit->clear();
|
||||
|
||||
bandComboBox->setCurrentIndex(currentBandShown);
|
||||
modeComboBox->setCurrentIndex(defaultMode);
|
||||
//qDebug() << "MainWindow::slotClearButtonClicked: " << QString::number(currentBand) << endl;
|
||||
bandComboBox->setCurrentIndex(bandComboBox->findText(dataProxy->getNameFromBandId(currentBand)));
|
||||
modeComboBox->setCurrentIndex(modeComboBox->findText(dataProxy->getNameFromModeId(currentMode)));
|
||||
//bandComboBox->setCurrentIndex(currentBand);
|
||||
//modeComboBox->setCurrentIndex(currentMode);
|
||||
|
||||
qsoPoints = 0;
|
||||
qsoMultiplier = 0;
|
||||
@ -3827,7 +3841,7 @@ void MainWindow::slotSetup(const int _page)
|
||||
|
||||
}
|
||||
defineStationCallsign();
|
||||
checkIfNewBandOrMode();
|
||||
//checkIfNewBandOrMode();
|
||||
}
|
||||
|
||||
void MainWindow::openFile()
|
||||
@ -5131,17 +5145,23 @@ void MainWindow::checkIfNewBandOrMode()
|
||||
bands.clear();
|
||||
bands << set.toList();
|
||||
|
||||
qDebug() << "MainWindow::checkIfNewBandOrMode: Modes1: " << modes.join(" - ") << endl;
|
||||
set.clear();
|
||||
modes << modesInLog;
|
||||
set = modes.toSet();
|
||||
|
||||
|
||||
modes.clear();
|
||||
modes << set.toList();
|
||||
|
||||
modes.sort();
|
||||
qDebug() << "MainWindow::checkIfNewBandOrMode: Modes2: " << modes.join(" - ") << endl;
|
||||
bandComboBox->clear();
|
||||
bandComboBox->addItems(bands);
|
||||
modeComboBox->clear();
|
||||
modeComboBox->addItems(modes);
|
||||
|
||||
qDebug() << "MainWindow::checkIfNewBandOrMode: Bands: " << bands.join(" - ") << endl;
|
||||
qDebug() << "MainWindow::checkIfNewBandOrMode: Modes: " << modes.join(" - ") << endl;
|
||||
//qDebug() << "MainWindow::checkIfNewBandOrMode-END" << endl;
|
||||
}
|
||||
|
||||
@ -6375,7 +6395,7 @@ void MainWindow::slotADIFImport(){
|
||||
filemanager->adifReadLog(fileName, currentLog);
|
||||
logModel->select();
|
||||
|
||||
checkIfNewBandOrMode();
|
||||
//checkIfNewBandOrMode();
|
||||
|
||||
switch (contestMode) {
|
||||
|
||||
@ -6512,7 +6532,8 @@ void MainWindow::qsoToEdit (const int _qso)
|
||||
}
|
||||
else
|
||||
{
|
||||
bandComboBox->setCurrentIndex(defaultBand);
|
||||
bandComboBox->setCurrentIndex(bandComboBox->findText(dataProxy->getNameFromBandId(defaultBand)));
|
||||
//bandComboBox->setCurrentIndex(defaultBand);
|
||||
}
|
||||
|
||||
nameCol = rec.indexOf("modeid");
|
||||
@ -6528,7 +6549,8 @@ void MainWindow::qsoToEdit (const int _qso)
|
||||
}
|
||||
else
|
||||
{
|
||||
modeComboBox->setCurrentIndex(defaultMode);
|
||||
modeComboBox->setCurrentIndex(modeComboBox->findText(dataProxy->getNameFromModeId(defaultMode)));
|
||||
//modeComboBox->setCurrentIndex(defaultMode);
|
||||
}
|
||||
|
||||
nameCol = rec.indexOf("rst_sent");
|
||||
@ -7471,7 +7493,7 @@ void MainWindow::clearInfoFromLocators()
|
||||
|
||||
void MainWindow::showEntityInfo(const int _enti)
|
||||
{
|
||||
qDebug() << "MainWindow::showEntityInfo" << QString::number(_enti) << endl;
|
||||
//qDebug()() << "MainWindow::showEntityInfo" << QString::number(_enti) << endl;
|
||||
|
||||
if (_enti<=0)
|
||||
{
|
||||
@ -7543,7 +7565,7 @@ void MainWindow::showStatusOfDXCC(const QStringList _qs)
|
||||
int status = awards->getDXStatus (_qs);
|
||||
QString message = QString();
|
||||
|
||||
qDebug() << "MainWindow::showStatusOfDXC: " << QString::number(status) << endl;
|
||||
//qDebug() << "MainWindow::showStatusOfDXC: " << QString::number(status) << endl;
|
||||
|
||||
message = awards->getDXStatusString(status);
|
||||
infoLabel1->setText(message);
|
||||
@ -7579,7 +7601,7 @@ QString MainWindow::getStyleColorToLabelFromBand(const QString _b, const QString
|
||||
|
||||
void MainWindow::showDXMarathonNeeded(const int _dxcc, const int _cqz, const int _year, const int _log)
|
||||
{
|
||||
qDebug() << "MainWindow::showDXMarathonNeeded" << endl;
|
||||
//qDebug()() << "MainWindow::showDXMarathonNeeded" << endl;
|
||||
if ((_dxcc<=0) || (_cqz<=0))
|
||||
{
|
||||
return;
|
||||
@ -8567,7 +8589,8 @@ void MainWindow::clusterSpotToLog(const QString _call, const QString _freq)
|
||||
}
|
||||
else
|
||||
{
|
||||
bandComboBox->setCurrentIndex(defaultBand);
|
||||
bandComboBox->setCurrentIndex(bandComboBox->findText(dataProxy->getNameFromBandId(defaultBand)));
|
||||
//bandComboBox->setCurrentIndex(defaultBand);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -33,7 +33,7 @@
|
||||
|
||||
#include <QNetworkRequest>
|
||||
#include <QNetworkReply>
|
||||
|
||||
#include <QtAlgorithms>
|
||||
|
||||
#include "database.h"
|
||||
#include "setupdialog.h"
|
||||
|
@ -747,6 +747,7 @@ void SetupDialog::readActiveBands (const QString actives)
|
||||
bool atLeastOne = false;
|
||||
|
||||
QStringList values = actives.split(", ", QString::SkipEmptyParts);
|
||||
QStringList _abands;
|
||||
|
||||
for (int i = 0; i < values.count() ; i++)
|
||||
{
|
||||
@ -756,14 +757,18 @@ void SetupDialog::readActiveBands (const QString actives)
|
||||
{
|
||||
//qDebug() << "SetupDialog::readActiveBands (at least One!): " << values.at(i) << endl;
|
||||
atLeastOne = true;
|
||||
bands.clear();
|
||||
_abands.clear();
|
||||
}
|
||||
|
||||
bands << values.at(i);
|
||||
_abands << values.at(i);
|
||||
//qDebug() << "SetupDialog::readActiveBands: " << values.at(i) << endl;
|
||||
}
|
||||
|
||||
}
|
||||
bands.clear();
|
||||
bands << dataProxy->getBandsInLog(-1);
|
||||
bands << _abands;
|
||||
bands.removeDuplicates();
|
||||
}
|
||||
|
||||
void SetupDialog::readActiveModes (const QString actives)
|
||||
@ -771,7 +776,7 @@ void SetupDialog::readActiveModes (const QString actives)
|
||||
//qDebug() << "SetupDialog::readActiveModes: " << actives << endl;
|
||||
|
||||
bool atLeastOne = false;
|
||||
|
||||
QStringList _amodes;
|
||||
QStringList values = actives.split(", ", QString::SkipEmptyParts);
|
||||
|
||||
for (int i = 0; i < values.count() ; i++)
|
||||
@ -781,14 +786,21 @@ void SetupDialog::readActiveModes (const QString actives)
|
||||
if (!atLeastOne)
|
||||
{
|
||||
atLeastOne = true;
|
||||
modes.clear();
|
||||
_amodes.clear();
|
||||
}
|
||||
|
||||
modes << values.at(i);
|
||||
_amodes << values.at(i);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
modes.clear();
|
||||
modes << dataProxy->getModesInLog(-1);
|
||||
modes << _amodes;
|
||||
modes.removeDuplicates();
|
||||
//qDebug() << "SetupDialog::readActiveModes: " << modes.join(" / ") << endl;
|
||||
|
||||
|
||||
}
|
||||
|
||||
bool SetupDialog::isValidBand (const QString b)
|
||||
|
@ -202,7 +202,7 @@ void SetupPageClubLog::setClubLog(const QString _s)
|
||||
|
||||
void SetupPageClubLog::slotUseStationCall(bool _s)
|
||||
{
|
||||
qDebug() << "SetupPageClubLog::slotUseStationCall" << endl;
|
||||
//qDebug() << "SetupPageClubLog::slotUseStationCall" << endl;
|
||||
if (useQSOStationCallCheckBox->isChecked())
|
||||
{
|
||||
callLineEdit->setEnabled(false);
|
||||
@ -218,10 +218,10 @@ void SetupPageClubLog::slotUseStationCall(bool _s)
|
||||
|
||||
void SetupPageClubLog::slotClubLogActive(bool _s)
|
||||
{
|
||||
qDebug() << "SetupPageClubLog::slotClubLogActive" << endl;
|
||||
//qDebug() << "SetupPageClubLog::slotClubLogActive" << endl;
|
||||
if (_s)
|
||||
{
|
||||
qDebug() << "SetupPageClubLog::slotClubLogActive TRUE" << endl;
|
||||
//qDebug() << "SetupPageClubLog::slotClubLogActive TRUE" << endl;
|
||||
callLabel->setEnabled(true);
|
||||
emailLabel->setEnabled(true);
|
||||
passwordLabel->setEnabled(true);
|
||||
@ -234,7 +234,7 @@ void SetupPageClubLog::slotClubLogActive(bool _s)
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "SetupPageClubLog::slotClubLogActive FALSE" << endl;
|
||||
//qDebug() << "SetupPageClubLog::slotClubLogActive FALSE" << endl;
|
||||
callLabel->setEnabled(false);
|
||||
emailLabel->setEnabled(false);
|
||||
passwordLabel->setEnabled(false);
|
||||
|
Loading…
Reference in New Issue
Block a user