mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-31 14:45:14 +00:00
Support tg://proxy links.
This commit is contained in:
@@ -838,7 +838,11 @@ bool Messenger::openLocalUrl(const QString &url) {
|
||||
}
|
||||
} else if (auto socksMatch = regex_match(qsl("^socks/?\\?(.+)(#|$)"), command, matchOptions)) {
|
||||
auto params = url_parse_params(socksMatch->captured(1), UrlParamNameTransform::ToLower);
|
||||
ConnectionBox::ShowApplyProxyConfirmation(params);
|
||||
ConnectionBox::ShowApplyProxyConfirmation(ProxyData::Type::Socks5, params);
|
||||
return true;
|
||||
} else if (auto proxyMatch = regex_match(qsl("^proxy/?\\?(.+)(#|$)"), command, matchOptions)) {
|
||||
auto params = url_parse_params(proxyMatch->captured(1), UrlParamNameTransform::ToLower);
|
||||
ConnectionBox::ShowApplyProxyConfirmation(ProxyData::Type::Mtproto, params);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
Reference in New Issue
Block a user