mirror of
https://invent.kde.org/network/falkon.git
synced 2024-12-20 02:36:34 +01:00
Make it possible for plugins to reimplement mailto scheme.
This commit is contained in:
parent
672c388407
commit
c073ce0094
@ -340,6 +340,11 @@ void WebPage::handleUnknownProtocol(const QUrl &url)
|
||||
{
|
||||
const QString &protocol = url.scheme();
|
||||
|
||||
if (protocol == QLatin1String("mailto")) {
|
||||
desktopServicesOpen(url);
|
||||
return;
|
||||
}
|
||||
|
||||
if (qzSettings->blockedProtocols.contains(protocol)) {
|
||||
qDebug() << "WebPage::handleUnknownProtocol Protocol" << protocol << "is blocked!";
|
||||
return;
|
||||
@ -508,13 +513,6 @@ bool WebPage::acceptNavigationRequest(QWebFrame* frame, const QNetworkRequest &r
|
||||
m_lastRequestType = type;
|
||||
m_lastRequestUrl = request.url();
|
||||
|
||||
const QString &scheme = request.url().scheme();
|
||||
|
||||
if (scheme == QLatin1String("mailto")) {
|
||||
desktopServicesOpen(request.url());
|
||||
return false;
|
||||
}
|
||||
|
||||
if (type == QWebPage::NavigationTypeFormResubmitted) {
|
||||
// Don't show this dialog if app is still starting
|
||||
if (!view() || !view()->isVisible()) {
|
||||
|
Loading…
Reference in New Issue
Block a user