mirror of
https://github.com/ea4k/klog.git
synced 2024-09-21 18:38:19 +00:00
DXCluster and DXMarathon improvement
This commit is contained in:
parent
69aa242491
commit
0f711f40f7
@ -13,6 +13,7 @@
|
||||
- KLog offers the user a default value if RST_TX or RST_RX field is not present when importing.
|
||||
- GUI: Added some shortcuts in the preference widget.
|
||||
- GUI: DXCluster: Add a suggestion to hit enter if no password is expected for the cluster. (tnx AA5VI)
|
||||
- GUI: DXCluster: Warns you if the spot is needed for the current year DX-Marathon
|
||||
- Support of realtime upload, modification & removal of a single QSO to/from ClubLog.org.
|
||||
- Updated the DB with the PROP_MODE options.
|
||||
- Improved the way KLog manages & shows the bands & modes.
|
||||
|
1
TODO
1
TODO
@ -42,7 +42,6 @@ TODO: Define a maximum QSO upload rate to clublog to avoid excesive API usage.
|
||||
</CLUBLOG>
|
||||
|
||||
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 an option to auto-complete info (QTH, Locator, Name, QSL Manager(qsl_via), IOTA, AWARD, Entity...) from previously worked QSO.
|
||||
|
11
awards.cpp
11
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;
|
||||
|
||||
@ -347,7 +347,7 @@ int Awards::getDXStatus (const QStringList _qs)
|
||||
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
|
||||
|
||||
@ -615,12 +615,15 @@ int Awards::dxccStatus(const int _ent, const int _logNumber)
|
||||
|
||||
QColor Awards::getQRZDXStatusColor(const QStringList _qs)
|
||||
{
|
||||
//qs << dxCall << spotBand << "-1" << QString::number(currentLog) ;
|
||||
|
||||
|
||||
//qDebug() << "Awards::getQRZDXStatusColor qs.length: " << QString::number(_qs.length()) << endl;
|
||||
|
||||
//From Search QSO to QSL: q << _call << bandid << _mode << QString::number(currentLog);
|
||||
|
||||
|
||||
//qDebug() << "Awards::getQRZDXStatusColor: " << _qs.at(0) << "/" << _qs.at(1) << "/" << _qs.at(2) << _qs.at(3) << endl;
|
||||
//qDebug() << "Awards::getQRZDXStatusColor: " << _qs.at(0) << "/" << _qs.at(1) << "/" << _qs.at(2) << _qs.at(3) << endl;
|
||||
// Receives: QStringList _qs;
|
||||
//_qs << QRZ << BandID << ModeId << lognumber;
|
||||
|
||||
@ -635,7 +638,7 @@ QColor Awards::getQRZDXStatusColor(const QStringList _qs)
|
||||
|
||||
int status = getDXStatus(_qs);
|
||||
|
||||
//qDebug() << "Awards::getQRZDXStatusColor: status: " << QString::number(status) << "/" << getDXStatusString(status) << endl;
|
||||
//qDebug() << "Awards::getQRZDXStatusColor: status: " << QString::number(status) << "/" << getDXStatusString(status) << endl;
|
||||
|
||||
//qDebug() << "Awards::getQRZDXStatusColor: status: " << QString::number(status) << endl;
|
||||
switch (status) {
|
||||
|
@ -210,50 +210,50 @@ bool DXClusterWidget::checkIfNeedsToBePrinted(const QString _dxCall, int const _
|
||||
bool isConfirmed = false;
|
||||
bool status = awards->isThisSpotConfirmed (qs);
|
||||
|
||||
qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: Status: " << _dxCall << "/" << QString::number(status);
|
||||
//qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: Status: " << _dxCall << "/" << QString::number(status);
|
||||
|
||||
if (!showconfirmed)
|
||||
{
|
||||
qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: is confirmed? ("<< QString::number(status)<< ")" << endl;
|
||||
//qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: is confirmed? ("<< QString::number(status)<< ")" << endl;
|
||||
if (status)
|
||||
{
|
||||
qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: It is confirmed: DON'T' print: " << _dxCall <<"/" << dataProxy->getNameFromBandId(_band) << endl;
|
||||
//qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: It is confirmed: DON'T' print: " << _dxCall <<"/" << dataProxy->getNameFromBandId(_band) << endl;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (!showhf)
|
||||
{
|
||||
qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: is HF?" << endl;
|
||||
//qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: is HF?" << endl;
|
||||
if (dataProxy->isHF(_band))
|
||||
{
|
||||
qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: Not showing HF but... is it WARC?" << endl;
|
||||
//qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: Not showing HF but... is it WARC?" << endl;
|
||||
if ( (showwarc) && dataProxy->isWARC(_band) )
|
||||
{
|
||||
qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: Not showing HF but... is WARC, print!" << endl;
|
||||
//qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: Not showing HF but... is WARC, print!" << endl;
|
||||
return true;
|
||||
}
|
||||
|
||||
qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: is HF: DON'T print: "<< _dxCall << "/" << dataProxy->getNameFromBandId(_band) << QString::number(_mode)<< endl;
|
||||
//qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: is HF: DON'T print: "<< _dxCall << "/" << dataProxy->getNameFromBandId(_band) << QString::number(_mode)<< endl;
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: is NOT HF" << endl;
|
||||
//qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: is NOT HF" << endl;
|
||||
}
|
||||
}
|
||||
|
||||
if (!showwarc)
|
||||
{
|
||||
qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: is WARC?" << endl;
|
||||
//qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: is WARC?" << endl;
|
||||
if (dataProxy->isWARC(_band))
|
||||
{
|
||||
qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: is WARC, DON'T print: "<< _dxCall << "/" << dataProxy->getNameFromBandId(_band) << QString::number(_mode)<< endl;
|
||||
//qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: is WARC, DON'T print: "<< _dxCall << "/" << dataProxy->getNameFromBandId(_band) << QString::number(_mode)<< endl;
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: is NOT WARC" << endl;
|
||||
//qDebug() << "DXClusterWidget::checkIfNeedsToBePrinted: is NOT WARC" << endl;
|
||||
|
||||
}
|
||||
|
||||
@ -286,7 +286,7 @@ void DXClusterWidget::setCurrentLog(const int _log)
|
||||
|
||||
void DXClusterWidget::slotClusterDataArrived()
|
||||
{
|
||||
qDebug() << "DXClusterWidget::slotClusterDataArrived" << endl;
|
||||
//qDebug() << "DXClusterWidget::slotClusterDataArrived" << endl;
|
||||
QStringList qs;
|
||||
QString dxClusterString;
|
||||
QString dxCall;
|
||||
@ -305,11 +305,11 @@ void DXClusterWidget::slotClusterDataArrived()
|
||||
}
|
||||
// It is a "DX de SP0TTER FREC DXCALL"
|
||||
//0 = DX, 1 = de, 2 = spotter, 3 = Freq, 4 = dxcall, 5 = comment
|
||||
qDebug() << "DXClusterWidget::slotClusterDataArrived: " << "DXCLUSTER->" << dxClusterString << "\nTOKENS: " << tokens << endl;
|
||||
//qDebug() << "DXClusterWidget::slotClusterDataArrived: " << "DXCLUSTER->" << dxClusterString << "\nTOKENS: " << tokens << endl;
|
||||
|
||||
if ((tokens[0] == "DX") && (tokens[1] == "de"))
|
||||
{
|
||||
qDebug() << "******************** DXClusterWidget::slotClusterDataArrived: DX DE" << endl;
|
||||
//qDebug() << "******************** DXClusterWidget::slotClusterDataArrived: DX DE" << endl;
|
||||
isADXSpot = true;
|
||||
QString spotter = tokens[2];
|
||||
spotter.truncate(spotter.size() - 1);
|
||||
@ -333,18 +333,20 @@ void DXClusterWidget::slotClusterDataArrived()
|
||||
dxClusterString = dxClusterString + " ### Needed for DXMarathon - " + QString::number(QDateTime::currentDateTime().date().year()) + " ###";
|
||||
}
|
||||
|
||||
qDebug() << "DX de ->" << "Spotter: " << spotter << "Freq: "<< dxFrequency << "DX: " << dxCall << endl;
|
||||
//qDebug() << "DX de ->" << "Spotter: " << spotter << "Freq: "<< dxFrequency << "DX: " << dxCall << endl;
|
||||
|
||||
}
|
||||
else if ((tokens[0] == "To") && (tokens[1] == "ALL"))
|
||||
{
|
||||
qDebug() << "DXClusterWidget::slotClusterDataArrived: TO ALL" << endl;
|
||||
//qDebug() << "DXClusterWidget::slotClusterDataArrived: TO ALL" << endl;
|
||||
dxSpotColor = awards->getDefaultColor();
|
||||
}
|
||||
else if ( (dxClusterString.length()>=5) && (world->checkQRZValidFormat(tokens[1])) )
|
||||
else if ( (dxClusterString.length()>=5) && (world->checkQRZValidFormat(tokens[1])) && (tokens[0]!="login:"))
|
||||
{ // Freq / DXCall / Date // time
|
||||
//_qs << QRZ << Freq in MHz << lognumber;
|
||||
qDebug() << "DXClusterWidget::slotClusterDataArrived: LENGTH >= 5" << endl;
|
||||
//qDebug() << "DXClusterWidget::slotClusterDataArrived: LENGTH >= 5" << endl;
|
||||
//qDebug() << "DXClusterWidget::slotClusterDataArrived: token0=" << tokens[0] << " / token1=" << tokens[1] << endl;
|
||||
|
||||
isADXSpot = true;
|
||||
dxCall = tokens[1];
|
||||
dxFrequency = tokens[0];
|
||||
@ -377,7 +379,7 @@ void DXClusterWidget::slotClusterDataArrived()
|
||||
//TODO: Change the "-1" by the mode
|
||||
if (!checkIfNeedsToBePrinted(dxCall, spotBand.toInt(), -1))
|
||||
{
|
||||
qDebug() << "DXClusterWidget::slotClusterDataArrived - Not to be printed!: " << dxCall << endl;
|
||||
//qDebug() << "DXClusterWidget::slotClusterDataArrived - Not to be printed!: " << dxCall << endl;
|
||||
return;
|
||||
}
|
||||
|
||||
@ -395,7 +397,7 @@ void DXClusterWidget::slotClusterDataArrived()
|
||||
|
||||
//qDebug() << "--------------------- DXClusterWidget::slotClusterDataArrived: " << dxClusterString << endl;
|
||||
|
||||
qDebug() << "DXClusterWidget::slotClusterDataArrived: " << dxClusterString << endl;
|
||||
//qDebug() << "DXClusterWidget::slotClusterDataArrived: " << dxClusterString << endl;
|
||||
|
||||
}
|
||||
|
||||
|
@ -429,7 +429,7 @@ MainWindow::MainWindow(const QString _kontestDir, const QString tversion)
|
||||
|
||||
// CLUSTER
|
||||
dxClusterWidget = new DXClusterWidget(dxclusterServerToConnect , dxclusterServerPort, this);
|
||||
dxClusterWidget->setCurrentLog(currentLog);
|
||||
|
||||
|
||||
// </CLUSTER>
|
||||
|
||||
@ -504,6 +504,7 @@ MainWindow::MainWindow(const QString _kontestDir, const QString tversion)
|
||||
updateQSLRecAndSent();
|
||||
awards->recalculateAwards();
|
||||
showAwards();
|
||||
dxClusterWidget->setCurrentLog(currentLog);
|
||||
}
|
||||
|
||||
|
||||
@ -5079,6 +5080,7 @@ bool MainWindow::processConfigLine(const QString _line){
|
||||
}else if(field=="SELECTEDLOG")
|
||||
{
|
||||
currentLog = value.toInt();
|
||||
dxClusterWidget->setCurrentLog(currentLog);
|
||||
//qDebug() << "MainWindow::processConfigLine: currentLog: " << value << endl;
|
||||
}else if(field=="CLUBLOGACTIVE")
|
||||
{
|
||||
@ -8070,14 +8072,14 @@ bool MainWindow::downloadCtyDatFile()
|
||||
request.setUrl(url);
|
||||
QNetworkReply *reply= manager.get(request);
|
||||
|
||||
//qDebug() << "MainWindow::downloadCtyDatFile - END" << endl;
|
||||
qDebug() << "MainWindow::downloadCtyDatFile - END" << endl;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void MainWindow::slotDownloadFinished(QNetworkReply *reply)
|
||||
{
|
||||
//qDebug() << "MainWindow::downloadFinished" << endl;
|
||||
qDebug() << "MainWindow::downloadFinished" << endl;
|
||||
QMessageBox::StandardButton ret;
|
||||
|
||||
//QMessageBox msgBox;
|
||||
|
@ -490,7 +490,7 @@ void SetupPageLogs::updateSelectedLogs()
|
||||
|
||||
int SetupPageLogs::getSelectedLog()
|
||||
{
|
||||
//qDebug() << "SetupPageLogs::getSelectedLog: " << currentLogs->currentText() << endl;
|
||||
qDebug() << "SetupPageLogs::getSelectedLog: " << currentLogs->currentText() << endl;
|
||||
QString selectedLog = currentLogs->currentText();
|
||||
int i = 0;
|
||||
QStringList qs;
|
||||
|
Loading…
Reference in New Issue
Block a user