home *** CD-ROM | disk | FTP | other *** search
/ Freelog 115 / FreelogNo115-MaiJuin2013.iso / Internet / AvantBrowser / asetup.exe / _data / webkit / chrome.dll / 0 / BINDATA / 26532 < prev    next >
Encoding:
Text File  |  2013-04-03  |  1.9 KB  |  51 lines

  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. [
  6.   {
  7.     "namespace": "i18n",
  8.     "types": [],
  9.     "functions": [
  10.       {
  11.         "name": "getAcceptLanguages",
  12.         "type": "function",
  13.         "description": "Gets the accept-languages of the browser. This is different from the locale used by the browser; to get the locale, use <code>window.navigator.language</code>.",
  14.         "parameters": [
  15.           {
  16.             "type": "function",
  17.             "name": "callback",
  18.             "parameters": [
  19.               {"name": "languages", "type": "array", "items": {"type": "string"}, "description": "Array of the accept languages of the browser, such as en-US,en,zh-CN"}
  20.             ]
  21.           }
  22.         ]
  23.       },
  24.       {
  25.         "name": "getMessage",
  26.         "type": "function",
  27.         "unprivileged": true,
  28.         "description": "Gets the localized string for the specified message. If the message is missing, this method returns an empty string (''). If the format of the <code>getMessage()</code> call is wrong — for example, <em>messageName</em> is not a string or the <em>substitutions</em> array has more than 9 elements — this method returns <code>undefined</code>.",
  29.         "parameters": [
  30.           {
  31.             "type": "string",
  32.             "name": "messageName",
  33.             "description": "The name of the message, as specified in the <a href='i18n-messages.html'><code>messages.json</code></a> file."
  34.           },
  35.           {
  36.             "type": "any",
  37.             "name": "substitutions",
  38.             "optional": true,
  39.             "description": "Up to 9 substitution strings, if the message requires any."
  40.           }
  41.         ],
  42.         "returns": {
  43.           "type": "string",
  44.           "description": "Message localized for current locale."
  45.         }
  46.       }
  47.     ],
  48.     "events": []
  49.   }
  50. ]
  51.