summaryrefslogtreecommitdiffstats
path: root/src/core/content_browser_client_qt.cpp
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@theqtcompany.com>2015-07-29 11:04:20 +0200
committerJoerg Bornemann <joerg.bornemann@theqtcompany.com>2015-08-04 09:42:01 +0000
commit2a56ec7ce4713711b55bb1dfc86a4320d943f606 (patch)
treeaa7edd2223e443384e157aaa367795aaec4e8a37 /src/core/content_browser_client_qt.cpp
parente11cd75ff506e8dcbfc990d70baeec821f1f0563 (diff)
add API to set the Accept-Language HTTP request-header field
Add methods to set the Accept-Language field in QWebEngineProfile and QQuickWebEngineProfile. Task-number: QTBUG-47412 Change-Id: Ifa376bb3551fdc1fb3d68279d734b7f7735782fc Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com> Reviewed-by: Andras Becsi <andras.becsi@theqtcompany.com>
Diffstat (limited to 'src/core/content_browser_client_qt.cpp')
-rw-r--r--src/core/content_browser_client_qt.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/core/content_browser_client_qt.cpp b/src/core/content_browser_client_qt.cpp
index f38451901..a8cb54c0c 100644
--- a/src/core/content_browser_client_qt.cpp
+++ b/src/core/content_browser_client_qt.cpp
@@ -422,6 +422,11 @@ std::string ContentBrowserClientQt::GetApplicationLocale()
return WebEngineLibraryInfo::getApplicationLocale();
}
+std::string ContentBrowserClientQt::GetAcceptLangs(content::BrowserContext *context)
+{
+ return static_cast<BrowserContextQt*>(context)->adapter()->httpAcceptLanguage().toStdString();
+}
+
void ContentBrowserClientQt::AppendExtraCommandLineSwitches(base::CommandLine* command_line, int child_process_id)
{
Q_UNUSED(child_process_id);