OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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) |
(...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
264 | 264 |
265 // Returns true if the embedder is running in single process mode. | 265 // Returns true if the embedder is running in single process mode. |
266 bool IsSingleProcess(); | 266 bool IsSingleProcess(); |
267 | 267 |
268 // Enables/Disables Spdy for requests afterwards. Used for benchmarking. | 268 // Enables/Disables Spdy for requests afterwards. Used for benchmarking. |
269 void EnableSpdy(bool enable); | 269 void EnableSpdy(bool enable); |
270 | 270 |
271 // Notifies the browser that the given action has been performed. | 271 // Notifies the browser that the given action has been performed. |
272 void UserMetricsRecordAction(const std::string& action); | 272 void UserMetricsRecordAction(const std::string& action); |
273 | 273 |
| 274 #if !defined(DISABLE_NACL) |
| 275 // Launch NaCl's sel_ldr process. |
| 276 bool LaunchSelLdr(const char* alleged_url, int socket_count, void* imc_handles, |
| 277 void* nacl_process_handle, int* nacl_process_id); |
| 278 #endif |
| 279 |
274 #if defined(OS_LINUX) | 280 #if defined(OS_LINUX) |
275 // Return a read-only file descriptor to the font which best matches the given | 281 // Return a read-only file descriptor to the font which best matches the given |
276 // properties or -1 on failure. | 282 // properties or -1 on failure. |
277 // charset: specifies the language(s) that the font must cover. See | 283 // charset: specifies the language(s) that the font must cover. See |
278 // render_sandbox_host_linux.cc for more information. | 284 // render_sandbox_host_linux.cc for more information. |
279 int MatchFontWithFallback(const std::string& face, bool bold, | 285 int MatchFontWithFallback(const std::string& face, bool bold, |
280 bool italic, int charset); | 286 bool italic, int charset); |
281 | 287 |
282 // GetFontTable loads a specified font table from an open SFNT file. | 288 // GetFontTable loads a specified font table from an open SFNT file. |
283 // fd: a file descriptor to the SFNT file. The position doesn't matter. | 289 // fd: a file descriptor to the SFNT file. The position doesn't matter. |
284 // table: the table in *big-endian* format, or 0 for the whole font file. | 290 // table: the table in *big-endian* format, or 0 for the whole font file. |
285 // output: a buffer of size output_length that gets the data. can be 0, in | 291 // output: a buffer of size output_length that gets the data. can be 0, in |
286 // which case output_length will be set to the required size in bytes. | 292 // which case output_length will be set to the required size in bytes. |
287 // output_length: size of output, if it's not 0. | 293 // output_length: size of output, if it's not 0. |
288 // | 294 // |
289 // returns: true on success. | 295 // returns: true on success. |
290 bool GetFontTable(int fd, uint32_t table, uint8_t* output, | 296 bool GetFontTable(int fd, uint32_t table, uint8_t* output, |
291 size_t* output_length); | 297 size_t* output_length); |
292 #endif | 298 #endif |
293 | 299 |
294 // ---- END FUNCTIONS IMPLEMENTED BY EMBEDDER --------------------------------- | 300 // ---- END FUNCTIONS IMPLEMENTED BY EMBEDDER --------------------------------- |
295 | 301 |
296 | 302 |
297 } // namespace webkit_glue | 303 } // namespace webkit_glue |
298 | 304 |
299 #endif // WEBKIT_GLUE_WEBKIT_GLUE_H_ | 305 #endif // WEBKIT_GLUE_WEBKIT_GLUE_H_ |
OLD | NEW |