mirror of
https://github.com/amnezia-vpn/amnezia-client.git
synced 2026-06-21 02:01:03 +07:00
277b295fd8
* Feat: Add MtProxy (Telegram) * add path files * refactor: move logic from ui to core --------- Co-authored-by: vkamn <vk@amnezia.org>
21 lines
480 B
C++
21 lines
480 B
C++
#ifndef MTPROXY_PUBLIC_HOST_INPUT_H
|
|
#define MTPROXY_PUBLIC_HOST_INPUT_H
|
|
|
|
#include <QString>
|
|
|
|
#include <QValidator>
|
|
|
|
/// Shared rules for public host field (IPv4 dotted partial, IPv6 hex, FQDN ASCII).
|
|
bool mtproxyPublicHostInputAllowed(const QString &text);
|
|
|
|
class PublicHostInputValidator : public QValidator {
|
|
Q_OBJECT
|
|
|
|
public:
|
|
explicit PublicHostInputValidator(QObject *parent = nullptr);
|
|
|
|
QValidator::State validate(QString &input, int &pos) const override;
|
|
};
|
|
|
|
#endif
|