mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2025-07-18 09:35:17 -04:00
Move asterisk; add "Ready on;y" checkbox; some code cleanup.
This commit is contained in:
parent
edd7fadd5a
commit
aa9cc8e885
@ -88,3 +88,8 @@ void ActiveStations::erase()
|
|||||||
{
|
{
|
||||||
ui->RecentStationsPlainTextEdit->clear();
|
ui->RecentStationsPlainTextEdit->clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool ActiveStations::readyOnly()
|
||||||
|
{
|
||||||
|
return ui->cbReadyOnly->isChecked();
|
||||||
|
}
|
||||||
|
@ -25,6 +25,7 @@ public:
|
|||||||
int maxAge();
|
int maxAge();
|
||||||
void setClickOK(bool b);
|
void setClickOK(bool b);
|
||||||
void erase();
|
void erase();
|
||||||
|
bool readyOnly();
|
||||||
Q_SLOT void select();
|
Q_SLOT void select();
|
||||||
|
|
||||||
bool m_clickOK=false;
|
bool m_clickOK=false;
|
||||||
|
@ -18,6 +18,44 @@
|
|||||||
<layout class="QGridLayout" name="gridLayout">
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
<item row="2" column="0">
|
<item row="2" column="0">
|
||||||
<layout class="QGridLayout" name="gridLayout_2">
|
<layout class="QGridLayout" name="gridLayout_2">
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QSpinBox" name="sbMaxRecent">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>100</width>
|
||||||
|
<height>0</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="prefix">
|
||||||
|
<string>Max N </string>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>50</number>
|
||||||
|
</property>
|
||||||
|
<property name="value">
|
||||||
|
<number>10</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="3">
|
||||||
|
<spacer name="horizontalSpacer">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" stdset="0">
|
||||||
|
<size>
|
||||||
|
<width>40</width>
|
||||||
|
<height>20</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
|
</item>
|
||||||
<item row="0" column="1">
|
<item row="0" column="1">
|
||||||
<widget class="QSpinBox" name="sbMaxAge">
|
<widget class="QSpinBox" name="sbMaxAge">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
@ -46,44 +84,13 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="0" column="0">
|
<item row="0" column="2">
|
||||||
<widget class="QSpinBox" name="sbMaxRecent">
|
<widget class="QCheckBox" name="cbReadyOnly">
|
||||||
<property name="sizePolicy">
|
<property name="text">
|
||||||
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
<string>Ready only</string>
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>100</width>
|
|
||||||
<height>0</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="prefix">
|
|
||||||
<string>Max Recent </string>
|
|
||||||
</property>
|
|
||||||
<property name="maximum">
|
|
||||||
<number>50</number>
|
|
||||||
</property>
|
|
||||||
<property name="value">
|
|
||||||
<number>10</number>
|
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="0" column="2">
|
|
||||||
<spacer name="horizontalSpacer">
|
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Horizontal</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeHint" stdset="0">
|
|
||||||
<size>
|
|
||||||
<width>40</width>
|
|
||||||
<height>20</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</spacer>
|
|
||||||
</item>
|
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="0">
|
<item row="1" column="0">
|
||||||
|
@ -3445,6 +3445,9 @@ void MainWindow::ARRL_Digi_Display()
|
|||||||
if(age>maxAge) {
|
if(age>maxAge) {
|
||||||
icall.remove();
|
icall.remove();
|
||||||
} else {
|
} else {
|
||||||
|
bool bReady=false;
|
||||||
|
if(age==0 and m_recentCall.value(deCall).ready2call) bReady=true;
|
||||||
|
if(bReady or !m_ActiveStationsWidget->readyOnly()) {
|
||||||
i++;
|
i++;
|
||||||
int az=m_activeCall[deCall].az;
|
int az=m_activeCall[deCall].az;
|
||||||
deGrid=m_activeCall[deCall].grid4;
|
deGrid=m_activeCall[deCall].grid4;
|
||||||
@ -3454,14 +3457,14 @@ void MainWindow::ARRL_Digi_Display()
|
|||||||
float x=float(age)/(maxAge+1);
|
float x=float(age)/(maxAge+1);
|
||||||
if(x>1.0) x=0;
|
if(x>1.0) x=0;
|
||||||
pts[i-1]=points - x;
|
pts[i-1]=points - x;
|
||||||
QString t0=" ";
|
|
||||||
if(age==0 and m_recentCall.value(deCall).ready2call) t0="* ";
|
|
||||||
QString t1;
|
QString t1;
|
||||||
t1 = t1.asprintf(" %3d %+2.2d %4d %1d %2d %4d",az,snr,freq,itx,age,points);
|
if(!bReady) t1 = t1.asprintf(" %3d %+2.2d %4d %1d %2d %4d",az,snr,freq,itx,age,points);
|
||||||
t1 = t0 + (deCall + " ").left(6) + " " + m_activeCall[deCall].grid4 + t1 + " " + bands;
|
if(bReady) t1 = t1.asprintf(" %3d %+2.2d %4d %1d %2d*%4d",az,snr,freq,itx,age,points);
|
||||||
|
t1 = (deCall + " ").left(6) + " " + m_activeCall[deCall].grid4 + t1 + " " + bands;
|
||||||
list.append(t1);
|
list.append(t1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
if(i==0) return;
|
if(i==0) return;
|
||||||
int jz=i;
|
int jz=i;
|
||||||
m_ActiveStationsWidget->setClickOK(false);
|
m_ActiveStationsWidget->setClickOK(false);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user