mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2026-07-11 21:34:13 -04:00
Improve frequency input validation
Allow group separators as well as decimal points in MHz input fields git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@7462 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
+2
-1
@@ -17,6 +17,7 @@
|
||||
#include <QDebug>
|
||||
#include <QDebugStateSaver>
|
||||
|
||||
#include "Radio.hpp"
|
||||
#include "Bands.hpp"
|
||||
#include "pimpl_impl.hpp"
|
||||
|
||||
@@ -480,7 +481,7 @@ bool FrequencyList::impl::setData (QModelIndex const& model_index, QVariant cons
|
||||
case frequency_column:
|
||||
if (value.canConvert<Frequency> ())
|
||||
{
|
||||
auto frequency = value.value<Frequency> ();
|
||||
Radio::Frequency frequency {qvariant_cast <Radio::Frequency> (value)};
|
||||
if (frequency != item.frequency_)
|
||||
{
|
||||
item.frequency_ = frequency;
|
||||
|
||||
Reference in New Issue
Block a user