Check USB device path access when prompting users to select a device.
[chromium-blink-merge.git] / chrome / renderer / worker_content_settings_client_proxy.h
blob588444254e6b251259851c1496fcd08e0e2e7b9d
1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CHROME_RENDERER_WORKER_CONTENT_SETTINGS_CLIENT_PROXY_H_
6 #define CHROME_RENDERER_WORKER_CONTENT_SETTINGS_CLIENT_PROXY_H_
8 #include "base/basictypes.h"
9 #include "base/memory/ref_counted.h"
10 #include "third_party/WebKit/public/web/WebWorkerContentSettingsClientProxy.h"
11 #include "url/gurl.h"
13 namespace IPC {
14 class SyncMessageFilter;
17 namespace content {
18 class RenderFrame;
21 namespace blink {
22 class WebFrame;
25 // This proxy is created on the main renderer thread then passed onto
26 // the blink's worker thread.
27 class WorkerContentSettingsClientProxy
28 : public blink::WebWorkerContentSettingsClientProxy {
29 public:
30 WorkerContentSettingsClientProxy(content::RenderFrame* render_frame,
31 blink::WebFrame* frame);
32 virtual ~WorkerContentSettingsClientProxy();
34 // WebWorkerContentSettingsClientProxy overrides.
35 virtual bool allowDatabase(const blink::WebString& name,
36 const blink::WebString& display_name,
37 unsigned long estimated_size);
38 virtual bool requestFileSystemAccessSync();
39 virtual bool allowIndexedDB(const blink::WebString& name);
41 private:
42 // Loading document context for this worker.
43 const int routing_id_;
44 bool is_unique_origin_;
45 GURL document_origin_url_;
46 GURL top_frame_origin_url_;
47 scoped_refptr<IPC::SyncMessageFilter> sync_message_filter_;
49 DISALLOW_COPY_AND_ASSIGN(WorkerContentSettingsClientProxy);
52 #endif // CHROME_RENDERER_WORKER_CONTENT_SETTINGS_CLIENT_PROXY_H_