mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2024-10-31 15:47:10 -04:00
873b1d1c43
Includes a new settings facility with the highlighting being contrled by a new model class and a modified QListView to display the data for editing. Edits include enable and disable check boxes, a contextual pop-up menu to adjust backkground and foreground colours. Still to be implemented are priorities for highlighting categories. This will be adjustable by drag and drop in the Colors settings panel, it is already implemented by the priority order has no effect on highlighting of decodes yet. The LotW users data file fetch and time since user's last upload is now controled from the settings dialog. This change also drops support for Qt versions before 5.5 so that many workarounds for earlier versions can be removed. Debug trace is slightly modified to make better use of the Qt built in facilities to format and synchronize cross thread messaging.
36 lines
1.1 KiB
C++
36 lines
1.1 KiB
C++
#include "Transceiver.hpp"
|
|
|
|
#include "moc_Transceiver.cpp"
|
|
|
|
#if !defined (QT_NO_DEBUG_STREAM)
|
|
QDebug operator << (QDebug d, Transceiver::TransceiverState const& s)
|
|
{
|
|
d.nospace ()
|
|
<< "Transceiver::TransceiverState(online: " << (s.online_ ? "yes" : "no")
|
|
<< " Frequency {" << s.rx_frequency_ << "Hz, " << s.tx_frequency_ << "Hz} " << s.mode_
|
|
<< "; SPLIT: " << (Transceiver::TransceiverState::Split::on == s.split_ ? "on" : Transceiver::TransceiverState::Split::off == s.split_ ? "off" : "unknown")
|
|
<< "; PTT: " << (s.ptt_ ? "on" : "off")
|
|
<< ')';
|
|
return d.space ();
|
|
}
|
|
#endif
|
|
|
|
ENUM_QDATASTREAM_OPS_IMPL (Transceiver, MODE);
|
|
|
|
ENUM_CONVERSION_OPS_IMPL (Transceiver, MODE);
|
|
|
|
bool operator != (Transceiver::TransceiverState const& lhs, Transceiver::TransceiverState const& rhs)
|
|
{
|
|
return lhs.online_ != rhs.online_
|
|
|| lhs.rx_frequency_ != rhs.rx_frequency_
|
|
|| lhs.tx_frequency_ != rhs.tx_frequency_
|
|
|| lhs.mode_ != rhs.mode_
|
|
|| lhs.split_ != rhs.split_
|
|
|| lhs.ptt_ != rhs.ptt_;
|
|
}
|
|
|
|
bool operator == (Transceiver::TransceiverState const& lhs, Transceiver::TransceiverState const& rhs)
|
|
{
|
|
return !(lhs != rhs);
|
|
}
|