void QWebView::linkClicked ( const QUrl & url ) [signal]
This signal is emitted whenever the user clicks on a link and the page's linkDelegationPolicy property is set to delegate the link handling for the specified url.
linkDelegationPolicy : LinkDelegationPolicy
This property holds how QWebPage should delegate the handling of links through the linkClicked() signal.
The default is to delegate no links.
the handling of 处理
使用linkclicked()信号
AuthHtmlWidget::AuthHtmlWidget(QWidget *parent)
: QWebView(parent)
{
page()->setLinkDelegationPolicy(QWebPage::DelegateAllLinks);
connect(this, SIGNAL(linkClicked(const QUrl&)), this, SLOT(OnAuthClicked(const QUrl&)));
}