Skip to content
Snippets Groups Projects
Commit fc1bb93b authored by lat9nq's avatar lat9nq
Browse files

shared_widget: Use QRegularExpression

parent fb7da1fa
No related branches found
No related tags found
No related merge requests found
......@@ -23,7 +23,7 @@
#include <QLineEdit>
#include <QObject>
#include <QPushButton>
#include <QRegExp>
#include <QRegularExpression>
#include <QSizePolicy>
#include <QSlider>
#include <QSpinBox>
......@@ -295,8 +295,8 @@ QWidget* Widget::CreateHexEdit(std::function<std::string()>& serializer,
return QString::fromStdString(fmt::format("{:08x}", std::stoul(input)));
};
QRegExpValidator* regex =
new QRegExpValidator{QRegExp{QStringLiteral("^[0-9a-fA-F]{0,8}$")}, line_edit};
QRegularExpressionValidator* regex = new QRegularExpressionValidator(
QRegularExpression{QStringLiteral("^[0-9a-fA-F]{0,8}$")}, line_edit);
const QString default_val = to_hex(setting.ToString());
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment