From 059831534c7e884f0a607ed86b582fd00d821731 Mon Sep 17 00:00:00 2001 From: Christoph Berg Date: Sat, 26 Sep 2026 23:24:03 +0200 Subject: New upstream version 3.2.0~rc1+dfsg --- models/FrequencyList.cpp | 36 +++++++++++++++++++++++++----------- 1 file changed, 25 insertions(+), 11 deletions(-) (limited to 'models/FrequencyList.cpp') diff --git a/models/FrequencyList.cpp b/models/FrequencyList.cpp index a0d22942..cc6ed129 100644 --- a/models/FrequencyList.cpp +++ b/models/FrequencyList.cpp @@ -71,6 +71,7 @@ namespace {1839000, Modes::JT9, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, {1839000, Modes::FST4, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, {1840000, Modes::FT8, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, + {1838000, Modes::JTTY, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // conventional RTTY frequency // Band plans (all USB dial unless stated otherwise) // @@ -107,6 +108,7 @@ namespace {3568600, Modes::FST4W, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, // needs guard marker and lock out {3575000, Modes::FT4, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // provisional {3568000, Modes::FT4, IARURegions::R3, "","", QDateTime(), QDateTime(), false}, // provisional + {3575000, Modes::JTTY, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // stays under R3's narrow DM segment (documented above as ending at 3575-3580) even with the 1500 Hz audio offset added {5357000, Modes::JT65, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, // provisional {5357000, Modes::JT9, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, // provisional @@ -153,6 +155,7 @@ namespace {7047500, Modes::FT4, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // provisional - moved // up 500Hz to clear // W1AW code practice QRG + {7090000, Modes::JTTY, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // conventional RTTY freq + 10 kHz // Band plans (all USB dial unless stated otherwise) // @@ -187,6 +190,7 @@ namespace {10138700, Modes::FST4W, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, {10140000, Modes::JT9, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, {10140000, Modes::FT4, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // provisional + {10140000, Modes::JTTY, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // conventional RTTY frequency; band's upper edge (10150) leaves no room for the usual +10 kHz nudge // Band plans (all USB dial unless stated otherwise) // @@ -215,7 +219,7 @@ namespace // 14105.5 OLIVIA 1000 // 14106.5 OLIVIA 1000 (main QRG) // - // R3: 14070 - 14112 DM NB(<2000Hz) with ±500Hz IBP guard band at 14100 + // R3: 14070 - 14112 DM NB(<2000Hz) with +/-500 Hz IBP guard band at 14100 // // 14070 PSK31 // 14074.4 OLIVIA, Contestia, etc. @@ -232,6 +236,7 @@ namespace {14076000, Modes::JT65, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, {14078000, Modes::JT9, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, {14080000, Modes::FT4, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // provisional + {14090000, Modes::JTTY, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // conventional RTTY freq + 10 kHz // Band plans (all USB dial unless stated otherwise) @@ -254,7 +259,7 @@ namespace // 18105 - 18110 Packet // 18110 NCDXF beacons // - // R3: 18095 - 18120 DM NB(<2000Hz) with ±500Hz IBP guard band at 18110 + // R3: 18095 - 18120 DM NB(<2000Hz) with +/-500 Hz IBP guard band at 18110 // // 18100 PSK31 // 18103.4 OLIVIA, Contestia, etc. (main QRG) @@ -268,6 +273,7 @@ namespace {18104000, Modes::FT4, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // provisional {18104600, Modes::WSPR, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, {18104600, Modes::FST4W, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, + {18100000, Modes::JTTY, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // conventional RTTY frequency; +10 kHz would put the 1500 Hz-offset signal past the US data segment's 18110 kHz edge (and onto the NCDXF beacon frequency) {21074000, Modes::FT8, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, {21091000, Modes::FT8, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, // DXpedition @@ -276,6 +282,7 @@ namespace {21094600, Modes::WSPR, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, {21094600, Modes::FST4W, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, {21140000, Modes::FT4, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, + {21090000, Modes::JTTY, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // conventional RTTY freq + 10 kHz {24911000, Modes::FT8, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, // DXpedition {24915000, Modes::FT8, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, @@ -284,6 +291,7 @@ namespace {24919000, Modes::FT4, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // provisional {24924600, Modes::WSPR, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, {24924600, Modes::FST4W, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, + {24920000, Modes::JTTY, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // conventional RTTY frequency; the US narrow data segment (24920-24925) leaves no room for the usual +10 kHz nudge once the 1500 Hz audio offset is added {28074000, Modes::FT8, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, {28091000, Modes::FT8, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, // DXpedition @@ -292,6 +300,7 @@ namespace {28124600, Modes::WSPR, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, {28124600, Modes::FST4W, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, {28180000, Modes::FT4, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, + {28090000, Modes::JTTY, IARURegions::ALL, "","", QDateTime(), QDateTime(), true}, // conventional RTTY freq + 10 kHz {50200000, Modes::Echo, IARURegions::ALL, "","", QDateTime(), QDateTime(), false}, {50211000, Modes::Q65, IARURegions::ALL, "EME","", QDateTime(), QDateTime(), false}, @@ -1040,15 +1049,21 @@ void FrequencyList_v2_101::impl::unprefer_all_but(Item &item, int const item_row bool FrequencyList_v2_101::impl::setData (QModelIndex const& model_index, QVariant const& value, int role) { bool changed {false}; - auto const& row = model_index.row (); + auto const row = model_index.row (); + + if (!model_index.isValid () + || row < 0 + || row >= frequency_list_.size ()) + { + return false; + } + auto& item = frequency_list_[row]; QVector roles; roles << role; - if (model_index.isValid () - && Qt::CheckStateRole == role - && row < frequency_list_.size () + if (Qt::CheckStateRole == role && model_index.column () == preferred_column) { bool b_val = ((Qt::CheckState)value.toInt() == Qt::Checked); @@ -1064,9 +1079,7 @@ bool FrequencyList_v2_101::impl::setData (QModelIndex const& model_index, QVaria } } - if (model_index.isValid () - && Qt::EditRole == role - && row < frequency_list_.size ()) + if (Qt::EditRole == role) { switch (model_index.column()) { @@ -1096,9 +1109,10 @@ bool FrequencyList_v2_101::impl::setData (QModelIndex const& model_index, QVaria case frequency_column: { - if (value.canConvert()) + bool ok; + Radio::Frequency frequency{value.toULongLong (&ok)}; + if (ok && frequency) { - Radio::Frequency frequency{qvariant_cast(value)}; if (frequency != item.frequency_) { item.frequency_ = frequency; -- cgit v1.2.3