Fix middle mouse button in help viewer

It didn't do anything on links though opening links in new pages was its
purpose.

Task-number: QTCREATORBUG-19344
Change-Id: I9560a59bd2ad4ec7179dce984cf3bc5160b84ff3
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
This commit is contained in:
Eike Ziller
2018-03-02 11:28:45 +01:00
parent e693c9a02e
commit 5f68209541

View File

@@ -432,7 +432,7 @@ void TextBrowserHelpWidget::mouseReleaseEvent(QMouseEvent *e)
bool controlPressed = e->modifiers() & Qt::ControlModifier;
const QString link = linkAt(e->pos());
if ((controlPressed || e->button() == Qt::MidButton) && link.isEmpty()) {
if ((controlPressed || e->button() == Qt::MidButton) && !link.isEmpty()) {
emit m_parent->newPageRequested(QUrl(link));
return;
}