OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef WEBKIT_GLUE_WEBKIT_GLUE_H_ | 5 #ifndef WEBKIT_GLUE_WEBKIT_GLUE_H_ |
6 #define WEBKIT_GLUE_WEBKIT_GLUE_H_ | 6 #define WEBKIT_GLUE_WEBKIT_GLUE_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 | 9 |
10 #if defined(OS_WIN) | 10 #if defined(OS_WIN) |
11 #include <windows.h> | 11 #include <windows.h> |
12 #endif | 12 #endif |
13 | 13 |
14 #include <string> | 14 #include <string> |
15 #include <vector> | 15 #include <vector> |
16 | 16 |
17 #include "base/file_path.h" | 17 #include "base/file_path.h" |
18 #include "base/platform_file.h" | 18 #include "base/platform_file.h" |
19 #include "base/string16.h" | 19 #include "base/string16.h" |
20 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebCanvas.h" | 20 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebCanvas.h" |
21 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebReferrerP
olicy.h" | 21 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebReferrerP
olicy.h" |
22 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFileError.h" | |
23 #include "webkit/glue/webkit_glue_export.h" | 22 #include "webkit/glue/webkit_glue_export.h" |
24 | 23 |
25 class GURL; | 24 class GURL; |
26 class SkBitmap; | 25 class SkBitmap; |
27 | 26 |
28 namespace net { | 27 namespace net { |
29 class URLRequest; | 28 class URLRequest; |
30 } | 29 } |
31 | 30 |
32 namespace skia { | 31 namespace skia { |
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
134 | 133 |
135 // File path string conversions. | 134 // File path string conversions. |
136 WEBKIT_GLUE_EXPORT FilePath::StringType WebStringToFilePathString( | 135 WEBKIT_GLUE_EXPORT FilePath::StringType WebStringToFilePathString( |
137 const WebKit::WebString& str); | 136 const WebKit::WebString& str); |
138 WEBKIT_GLUE_EXPORT WebKit::WebString FilePathStringToWebString( | 137 WEBKIT_GLUE_EXPORT WebKit::WebString FilePathStringToWebString( |
139 const FilePath::StringType& str); | 138 const FilePath::StringType& str); |
140 WEBKIT_GLUE_EXPORT FilePath WebStringToFilePath(const WebKit::WebString& str); | 139 WEBKIT_GLUE_EXPORT FilePath WebStringToFilePath(const WebKit::WebString& str); |
141 WEBKIT_GLUE_EXPORT WebKit::WebString FilePathToWebString( | 140 WEBKIT_GLUE_EXPORT WebKit::WebString FilePathToWebString( |
142 const FilePath& file_path); | 141 const FilePath& file_path); |
143 | 142 |
144 // File error conversion | |
145 WEBKIT_GLUE_EXPORT WebKit::WebFileError PlatformFileErrorToWebFileError( | |
146 base::PlatformFileError error_code); | |
147 | |
148 // File info conversion | 143 // File info conversion |
149 WEBKIT_GLUE_EXPORT void PlatformFileInfoToWebFileInfo( | 144 WEBKIT_GLUE_EXPORT void PlatformFileInfoToWebFileInfo( |
150 const base::PlatformFileInfo& file_info, | 145 const base::PlatformFileInfo& file_info, |
151 WebKit::WebFileInfo* web_file_info); | 146 WebKit::WebFileInfo* web_file_info); |
152 | 147 |
153 // Returns a WebCanvas pointer associated with the given Skia canvas. | 148 // Returns a WebCanvas pointer associated with the given Skia canvas. |
154 WEBKIT_GLUE_EXPORT WebKit::WebCanvas* ToWebCanvas(skia::PlatformCanvas*); | 149 WEBKIT_GLUE_EXPORT WebKit::WebCanvas* ToWebCanvas(skia::PlatformCanvas*); |
155 | 150 |
156 // Returns the number of currently-active glyph pages this process is using. | 151 // Returns the number of currently-active glyph pages this process is using. |
157 // There can be many such pages (maps of 256 character -> glyph) so this is | 152 // There can be many such pages (maps of 256 character -> glyph) so this is |
158 // used to get memory usage statistics. | 153 // used to get memory usage statistics. |
159 WEBKIT_GLUE_EXPORT int GetGlyphPageCount(); | 154 WEBKIT_GLUE_EXPORT int GetGlyphPageCount(); |
160 | 155 |
161 // Returns WebKit Web Inspector protocol version. | 156 // Returns WebKit Web Inspector protocol version. |
162 std::string GetInspectorProtocolVersion(); | 157 std::string GetInspectorProtocolVersion(); |
163 | 158 |
164 // Tells caller whether the given protocol version is supported by the. | 159 // Tells caller whether the given protocol version is supported by the. |
165 WEBKIT_GLUE_EXPORT bool IsInspectorProtocolVersionSupported( | 160 WEBKIT_GLUE_EXPORT bool IsInspectorProtocolVersionSupported( |
166 const std::string& version); | 161 const std::string& version); |
167 | 162 |
168 // Configures the URLRequest according to the referrer policy. | 163 // Configures the URLRequest according to the referrer policy. |
169 WEBKIT_GLUE_EXPORT void ConfigureURLRequestForReferrerPolicy( | 164 WEBKIT_GLUE_EXPORT void ConfigureURLRequestForReferrerPolicy( |
170 net::URLRequest* request, WebKit::WebReferrerPolicy referrer_policy); | 165 net::URLRequest* request, WebKit::WebReferrerPolicy referrer_policy); |
171 | 166 |
172 } // namespace webkit_glue | 167 } // namespace webkit_glue |
173 | 168 |
174 #endif // WEBKIT_GLUE_WEBKIT_GLUE_H_ | 169 #endif // WEBKIT_GLUE_WEBKIT_GLUE_H_ |
OLD | NEW |