summaryrefslogtreecommitdiffstats
path: root/src/core/content_browser_client_qt.cpp
diff options
context:
space:
mode:
authorSzabolcs David <davidsz@inf.u-szeged.hu>2016-10-17 07:00:26 -0700
committerSzabolcs David <davidsz@inf.u-szeged.hu>2017-09-13 13:34:31 +0000
commit7b365eb352780dc0d939e918b0aa58d0458fd9da (patch)
tree6453e84f62bcbe92f9149a486fc83dbdf09cdb4c /src/core/content_browser_client_qt.cpp
parent98bdf56f7428094c2d197fff72422d301470fbcb (diff)
Support Quota Management API
Expose navigator.webkitPersistentStorage.requestQuota() calls to the API layer as a permission API. It allows the users to accept these requests and specify a quota for persistent storage. https://developer.chrome.com/apps/offline_storage#managing_quota [ChangeLog] navigator.webkitPersistentStorage.requestQuota() calls were rejected by default and now they will emit signal quotaPermissionRequested in both WebEngineView and QWebEnginePage. Task-number: QTBUG-56354 Change-Id: Id192577ffb403694d3051414744ded89bbfd2aa8 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'src/core/content_browser_client_qt.cpp')
-rw-r--r--src/core/content_browser_client_qt.cpp12
1 files changed, 1 insertions, 11 deletions
diff --git a/src/core/content_browser_client_qt.cpp b/src/core/content_browser_client_qt.cpp
index 5bce81f25..42c3f8951 100644
--- a/src/core/content_browser_client_qt.cpp
+++ b/src/core/content_browser_client_qt.cpp
@@ -54,7 +54,6 @@
#include "content/public/browser/child_process_security_policy.h"
#include "content/public/browser/client_certificate_delegate.h"
#include "content/public/browser/media_observer.h"
-#include "content/public/browser/quota_permission_context.h"
#include "content/public/browser/render_frame_host.h"
#include "content/public/browser/render_process_host.h"
#include "content/public/browser/render_view_host.h"
@@ -97,6 +96,7 @@
#include "printing_message_filter_qt.h"
#endif // BUILDFLAG(ENABLE_BASIC_PRINTING)
#include "qrc_protocol_handler_qt.h"
+#include "quota_permission_context_qt.h"
#include "renderer_host/resource_dispatcher_host_delegate_qt.h"
#include "renderer_host/user_resource_controller_host.h"
#include "web_contents_delegate_qt.h"
@@ -374,16 +374,6 @@ void ShareGroupQtQuick::AboutToAddFirstContext()
#endif
}
-class QuotaPermissionContextQt : public content::QuotaPermissionContext {
-public:
- void RequestQuotaPermission(const content::StorageQuotaParams &params, int render_process_id, const PermissionCallback &callback) override
- {
- Q_UNUSED(params);
- Q_UNUSED(render_process_id);
- callback.Run(QUOTA_PERMISSION_RESPONSE_DISALLOW);
- }
-};
-
ContentBrowserClientQt::ContentBrowserClientQt()
: m_browserMainParts(0)
{