20 const std::string &cashaddrprefixIn, QObject *parent)
21 : QValidator(parent), cashaddrprefix(cashaddrprefixIn) {}
28 if (input.isEmpty()) {
29 return QValidator::Intermediate;
33 for (
int idx = 0; idx < input.size();) {
34 bool removeChar =
false;
35 QChar ch = input.at(idx);
39 switch (ch.unicode()) {
63 QValidator::State state = QValidator::Acceptable;
64 for (
int idx = 0; idx < input.size(); ++idx) {
65 int ch = input.at(idx).unicode();
67 if ((ch >=
'0' && ch <=
'9') || (ch >=
'a' && ch <=
'z') ||
68 (ch >=
'A' && ch <=
'Z') || (ch ==
':')) {
72 return QValidator::Invalid;
80 : QValidator(parent) {}
89 return QValidator::Acceptable;
92 return QValidator::Invalid;
State validate(QString &input, int &pos) const override
BitcoinAddressCheckValidator(QObject *parent)
BitcoinAddressEntryValidator(const std::string &cashaddrprefixIn, QObject *parent)
State validate(QString &input, int &pos) const override
const Config & GetConfig()
bool IsValidDestinationString(const std::string &str, const CChainParams ¶ms)