- add sources.
[platform/framework/web/crosswalk.git] / src / content / ppapi_plugin / ppapi_webkitplatformsupport_impl.h
1 // Copyright (c) 2012 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.
4
5 #ifndef CONTENT_PPAPI_PLUGIN_PPAPI_WEBKITPLATFORMSUPPORT_IMPL_H_
6 #define CONTENT_PPAPI_PLUGIN_PPAPI_WEBKITPLATFORMSUPPORT_IMPL_H_
7
8 #include "base/basictypes.h"
9 #include "base/memory/scoped_ptr.h"
10 #include "content/child/webkitplatformsupport_impl.h"
11
12 namespace content {
13
14 class PpapiWebKitPlatformSupportImpl : public WebKitPlatformSupportImpl {
15  public:
16   PpapiWebKitPlatformSupportImpl();
17   virtual ~PpapiWebKitPlatformSupportImpl();
18
19   // WebKitPlatformSupport methods:
20   virtual WebKit::WebClipboard* clipboard();
21   virtual WebKit::WebMimeRegistry* mimeRegistry();
22   virtual WebKit::WebFileUtilities* fileUtilities();
23   virtual WebKit::WebSandboxSupport* sandboxSupport();
24   virtual bool sandboxEnabled();
25   virtual unsigned long long visitedLinkHash(const char* canonicalURL,
26                                              size_t length);
27   virtual bool isLinkVisited(unsigned long long linkHash);
28   virtual WebKit::WebMessagePortChannel* createMessagePortChannel();
29   virtual void setCookies(const WebKit::WebURL& url,
30                           const WebKit::WebURL& first_party_for_cookies,
31                           const WebKit::WebString& value);
32   virtual WebKit::WebString cookies(
33       const WebKit::WebURL& url,
34       const WebKit::WebURL& first_party_for_cookies);
35   virtual WebKit::WebString defaultLocale();
36   virtual WebKit::WebThemeEngine* themeEngine();
37   virtual WebKit::WebURLLoader* createURLLoader();
38   virtual WebKit::WebSocketStreamHandle* createSocketStreamHandle();
39   virtual void getPluginList(bool refresh, WebKit::WebPluginListBuilder*);
40   virtual WebKit::WebData loadResource(const char* name);
41   virtual WebKit::WebStorageNamespace* createLocalStorageNamespace();
42   virtual void dispatchStorageEvent(const WebKit::WebString& key,
43       const WebKit::WebString& oldValue, const WebKit::WebString& newValue,
44       const WebKit::WebString& origin, const WebKit::WebURL& url,
45       bool isLocalStorage);
46   virtual int databaseDeleteFile(const WebKit::WebString& vfs_file_name,
47                                  bool sync_dir);
48
49  private:
50   class SandboxSupport;
51   scoped_ptr<SandboxSupport> sandbox_support_;
52
53   DISALLOW_COPY_AND_ASSIGN(PpapiWebKitPlatformSupportImpl);
54 };
55
56 }  // namespace content
57
58 #endif  // CONTENT_PPAPI_PLUGIN_PPAPI_WEBKITPLATFORMSUPPORT_IMPL_H_