B2G/gecko/browser/modules/NewTabUtils.jsm
/**
   * Sets the storage value for a given key.
   * @param aKey The storage key (a string).
   * @param aValue The value to set.
   */
Sets the storage value for a given key.
@param aKey The storage key (a string).
@param aValue The value to set.
Sets the storage value for a given key . @param aKey The storage key ( a string ) . @param aValue The value to set .
function Storage_set(aKey, aValue) {
    let string = Cc["@mozilla.org/supports-string;1"]
                   .createInstance(Ci.nsISupportsString);
    string.data = JSON.stringify(aValue);
    Services.prefs.setComplexValue(this._prefs[aKey], Ci.nsISupportsString,
                                   string);
  }
function Storage_set ( aKey , aValue ) { let string = Cc [ "@mozilla.org/supports-string;1" ] . createInstance ( Ci . nsISupportsString ) ; string . data = JSON . stringify ( aValue ) ; Services . prefs . setComplexValue ( this . _prefs [ aKey ] , Ci . nsISupportsString , string ) ; }
Sets the storage value for a given key.
Sets the storage value for a given key .
// Page titles may contain unicode, thus use complex values.