mirror of
https://github.com/MatsuriDayo/nekoray.git
synced 2025-12-18 04:54:38 +03:00
system proxy format (windows)
This commit is contained in:
@@ -25,6 +25,8 @@ inline std::function<void(QString, QString)> dialog_message;
|
||||
#define QJSONOBJECT_COPY(src, dst, key) if (src.contains(key)) dst[key] = src[key];
|
||||
#define QJSONOBJECT_COPY2(src, dst, src_key, dst_key) if (src.contains(src_key)) dst[dst_key] = src[src_key];
|
||||
|
||||
#define Int2String(num) QString::number(num)
|
||||
|
||||
inline QString SubStrBefore(QString str, const QString &sub) {
|
||||
if (!str.contains(sub)) return str;
|
||||
return str.left(str.indexOf(sub));
|
||||
@@ -58,14 +60,6 @@ DecodeB64IfValid(const QString &input, QByteArray::Base64Option options = QByteA
|
||||
|
||||
QString GetQueryValue(const QUrlQuery &q, const QString &key, const QString &def = "");
|
||||
|
||||
inline QString Int2String(int i) {
|
||||
return QVariant(i).toString();
|
||||
}
|
||||
|
||||
inline QString Int2String(qint64 i) {
|
||||
return QVariant(i).toString();
|
||||
}
|
||||
|
||||
QString GetRandomString(int randomStringLength);
|
||||
|
||||
// QString >> QJson
|
||||
@@ -114,6 +108,8 @@ inline QStringList SplitLines(const QString &_string) {
|
||||
return _string.split(QRegularExpression("[\r\n]"), Qt::SplitBehaviorFlags::SkipEmptyParts);
|
||||
}
|
||||
|
||||
// Files
|
||||
|
||||
QByteArray ReadFile(const QString &path);
|
||||
|
||||
QString ReadFileText(const QString &path);
|
||||
|
||||
Reference in New Issue
Block a user