Bug 556509 - folders description not synchronised [r=mconnor]

Allow descriptions to be set on folder records and set description on creation.

--HG--
extra : rebase_source : d380f5d28130bd53532e5b4d293468aa053c19b2
This commit is contained in:
Edward Lee 2010-04-01 15:11:42 -07:00
parent dfeaeaf6ac
commit 1fddfb0347
2 changed files with 5 additions and 1 deletions

View File

@ -509,6 +509,9 @@ BookmarksStore.prototype = {
record._insertPos);
this._log.debug(["created folder", newId, "under", record._parent, "at",
record._insertPos, "as", record.title].join(" "));
if (record.description)
Utils.anno(newId, "bookmarkProperties/description", record.description);
break;
case "livemark":
let siteURI = null;
@ -767,6 +770,7 @@ BookmarksStore.prototype = {
record.parentName = Svc.Bookmark.getItemTitle(parent);
record.title = this._bms.getItemTitle(placeId);
record.description = this._getDescription(placeId);
break;
case this._bms.TYPE_SEPARATOR:

View File

@ -127,7 +127,7 @@ BookmarkFolder.prototype = {
_logName: "Record.Folder",
};
Utils.deferGetSet(BookmarkFolder, "cleartext", "title");
Utils.deferGetSet(BookmarkFolder, "cleartext", ["description", "title"]);
function Livemark(uri) {
BookmarkFolder.call(this, uri, "livemark");