Skip to content

Commit 5a52fea

Browse files
committed
Распознавание https ссылок на rsdn внутри сообщений
1 parent 570bb93 commit 5a52fea

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/widgets/message_tree.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1542,7 +1542,7 @@ void AMessageTree::processUrl (const QString& url)
15421542
// проверка на то, что URL является ссылкой на сообщение RSDN
15431543
// TODO: дополнить регэксп на ссылку вида https://rsdn.ru/forum/Message.aspx?mid=3900833&only=1
15441544
// пример встречается по ссылке https://rsdn.ru/forum/unix/3901241.1
1545-
QRegExp rsdn_url("^(http://){0,1}((www|gzip)\\.){0,1}rsdn.ru/forum/.+/(\\d+)(\\.(1|flat|aspx)){0,1}", Qt::CaseInsensitive);
1545+
QRegExp rsdn_url("^(https?://){0,1}((www|gzip)\\.){0,1}rsdn.ru/forum/.+/(\\d+)(\\.(1|flat|aspx)){0,1}", Qt::CaseInsensitive);
15461546

15471547
if (rsdn_url.indexIn(external_url) == -1)
15481548
QDesktopServices::openUrl(external_url);

0 commit comments

Comments
 (0)