Changeset View
Changeset View
Standalone View
Standalone View
webenginepart/src/webenginepage.cpp
Show First 20 Lines • Show All 183 Lines • ▼ Show 20 Line(s) | 169 | { | |||
---|---|---|---|---|---|
184 | 184 | | |||
185 | return (u1List == u2List); | 185 | return (u1List == u2List); | ||
186 | } | 186 | } | ||
187 | 187 | | |||
188 | bool WebEnginePage::acceptNavigationRequest(const QUrl& url, NavigationType type, bool isMainFrame) | 188 | bool WebEnginePage::acceptNavigationRequest(const QUrl& url, NavigationType type, bool isMainFrame) | ||
189 | { | 189 | { | ||
190 | if (m_urlLoadedByPart != url) { | 190 | if (m_urlLoadedByPart != url) { | ||
191 | m_urlLoadedByPart = QUrl(); | 191 | m_urlLoadedByPart = QUrl(); | ||
192 | | ||||
193 | //Don't open local files using WebEnginePart except if configured to do so by the user. For example | ||||
194 | //for example, this ensures that the "Home" link in the introduction page is opened in Dolphin part | ||||
195 | //(or whichever part the user has chosen to open directories instead of WebEnginePart | ||||
196 | if (url.isLocalFile()) { | ||||
dfaureUnsubmitted Not Done dfaure: if (url.isLocalFile()) { | |||||
197 | emit m_part->browserExtension()->openUrlRequest(url); | ||||
198 | return false; | ||||
199 | } | ||||
192 | } | 200 | } | ||
193 | // qCDebug(WEBENGINEPART_LOG) << url << "type=" << type; | 201 | // qCDebug(WEBENGINEPART_LOG) << url << "type=" << type; | ||
194 | QUrl reqUrl(url); | 202 | QUrl reqUrl(url); | ||
195 | 203 | | |||
196 | // Handle "mailto:" url here... | 204 | // Handle "mailto:" url here... | ||
197 | if (handleMailToUrl(reqUrl, type)) | 205 | if (handleMailToUrl(reqUrl, type)) | ||
198 | return false; | 206 | return false; | ||
199 | 207 | | |||
▲ Show 20 Lines • Show All 752 Lines • Show Last 20 Lines |