diff --git a/qutebrowser/browser/shared.py b/qutebrowser/browser/shared.py index 1006907ea..6caeafb07 100644 --- a/qutebrowser/browser/shared.py +++ b/qutebrowser/browser/shared.py @@ -171,7 +171,7 @@ def feature_permission(url, option, msg, yes_action, no_action, abort_on): Args: url: The URL the request was done for. - option: A (section, option) tuple for the option to check. + option: An option name to check. msg: A string like "show notifications" yes_action: A callable to call if the request was approved no_action: A callable to call if the request was denied diff --git a/qutebrowser/browser/webengine/webview.py b/qutebrowser/browser/webengine/webview.py index f7221426c..1a115c9de 100644 --- a/qutebrowser/browser/webengine/webview.py +++ b/qutebrowser/browser/webengine/webview.py @@ -148,11 +148,10 @@ class WebEnginePage(QWebEnginePage): def _on_feature_permission_requested(self, url, feature): """Ask the user for approval for geolocation/media/etc..""" options = { - QWebEnginePage.Geolocation: ('content', 'geolocation'), - QWebEnginePage.MediaAudioCapture: ('content', 'media-capture'), - QWebEnginePage.MediaVideoCapture: ('content', 'media-capture'), - QWebEnginePage.MediaAudioVideoCapture: - ('content', 'media-capture'), + QWebEnginePage.Geolocation: 'content.geolocation', + QWebEnginePage.MediaAudioCapture: 'content.media_capture', + QWebEnginePage.MediaVideoCapture: 'content.media_capture', + QWebEnginePage.MediaAudioVideoCapture: 'content.media_capture', } messages = { QWebEnginePage.Geolocation: 'access your location', diff --git a/qutebrowser/browser/webkit/webpage.py b/qutebrowser/browser/webkit/webpage.py index ac156d12f..10ff1ba8a 100644 --- a/qutebrowser/browser/webkit/webpage.py +++ b/qutebrowser/browser/webkit/webpage.py @@ -304,8 +304,8 @@ class BrowserPage(QWebPage): return options = { - QWebPage.Notifications: ('content', 'notifications'), - QWebPage.Geolocation: ('content', 'geolocation'), + QWebPage.Notifications: 'content.notifications', + QWebPage.Geolocation: 'content.geolocation', } messages = { QWebPage.Notifications: 'show notifications',