Merge pull request #4567 from jgkamat/jay/512-settings
Add setting for DnsPrefetchEnabled
This commit is contained in:
commit
bbfdf1f6fa
@ -25,6 +25,7 @@ Module attributes:
|
|||||||
"""
|
"""
|
||||||
|
|
||||||
import os
|
import os
|
||||||
|
import operator
|
||||||
|
|
||||||
from PyQt5.QtGui import QFont
|
from PyQt5.QtGui import QFont
|
||||||
from PyQt5.QtWebEngineWidgets import (QWebEngineSettings, QWebEngineProfile,
|
from PyQt5.QtWebEngineWidgets import (QWebEngineSettings, QWebEngineProfile,
|
||||||
@ -165,7 +166,11 @@ class WebEngineSettings(websettings.AbstractSettings):
|
|||||||
('PrintElementBackgrounds', None),
|
('PrintElementBackgrounds', None),
|
||||||
# Qt 5.11
|
# Qt 5.11
|
||||||
'content.autoplay':
|
'content.autoplay':
|
||||||
('PlaybackRequiresUserGesture', lambda val: not val),
|
('PlaybackRequiresUserGesture', operator.not_),
|
||||||
|
|
||||||
|
# Qt 5.12
|
||||||
|
'content.dns_prefetch':
|
||||||
|
('DnsPrefetchEnabled', None),
|
||||||
}
|
}
|
||||||
for name, (attribute, converter) in new_attributes.items():
|
for name, (attribute, converter) in new_attributes.items():
|
||||||
try:
|
try:
|
||||||
|
@ -164,6 +164,7 @@ def _parse_yaml_backends_dict(
|
|||||||
'Qt 5.9.2': qtutils.version_check('5.9.2'),
|
'Qt 5.9.2': qtutils.version_check('5.9.2'),
|
||||||
'Qt 5.10': qtutils.version_check('5.10'),
|
'Qt 5.10': qtutils.version_check('5.10'),
|
||||||
'Qt 5.11': qtutils.version_check('5.11'),
|
'Qt 5.11': qtutils.version_check('5.11'),
|
||||||
|
'Qt 5.12': qtutils.version_check('5.12'),
|
||||||
}
|
}
|
||||||
for key in sorted(node.keys()):
|
for key in sorted(node.keys()):
|
||||||
if conditionals[node[key]]:
|
if conditionals[node[key]]:
|
||||||
|
@ -379,7 +379,9 @@ content.developer_extras:
|
|||||||
content.dns_prefetch:
|
content.dns_prefetch:
|
||||||
default: true
|
default: true
|
||||||
type: Bool
|
type: Bool
|
||||||
backend: QtWebKit
|
backend:
|
||||||
|
QtWebKit: true
|
||||||
|
QtWebEngine: Qt 5.12
|
||||||
supports_pattern: true
|
supports_pattern: true
|
||||||
desc: Try to pre-fetch DNS entries to speed up browsing.
|
desc: Try to pre-fetch DNS entries to speed up browsing.
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user