Verified Commit 5c15ea01 authored by Rinigus Saar's avatar Rinigus Saar Committed by Jonah Brüchert
Browse files

set userAgent according to the current tab

As profile is shared, unless specified separately, change the
current userAgent to reflect the current tab.

Fixes #10
parent e83473b6
......@@ -203,4 +203,12 @@ WebEngineView {
questionLoader.item.origin = securityOrigin
questionLoader.item.visible = true
onVisibleChanged: {
// set user agent to the current displayed tab
// this ensures that we follow mobile preference
// of the current webview
if (visible)
profile.httpUserAgent = Qt.binding(function() { return userAgent.userAgent; })
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment