From: Oleg Broytman Date: Wed, 4 Aug 2010 17:10:39 +0000 (+0000) Subject: Load/store folder's root. X-Git-Tag: v4.5.3~139 X-Git-Url: https://git.phdru.name/?a=commitdiff_plain;ds=sidebyside;h=b3939ade7f545a07b93188543761ada36e996d11;p=bookmarks_db.git Load/store folder's root. git-svn-id: file:///home/phd/archive/SVN/bookmarks_db/trunk@237 fdd5c36f-1aea-0310-aeeb-c58d7e2b6c23 --- diff --git a/Storage/bkmk_stjson.py b/Storage/bkmk_stjson.py index cd6139f..00daa60 100644 --- a/Storage/bkmk_stjson.py +++ b/Storage/bkmk_stjson.py @@ -39,6 +39,8 @@ class storage_json(Walker): dict["lastModified"] = f.last_modified parent_idx = getattr(f, 'parent_idx') if parent_idx: dict["parent"] = parent_idx + root = getattr(f, 'root') + if root: dict["root"] = root dict["title"] = f.name.decode('utf-8') dict["type"] = "text/x-moz-place-container" self.folder_stack[-1].append(dict) @@ -118,6 +120,7 @@ class storage_json(Walker): folder.id = fdict["id"] folder.index = fdict.get("index") folder.parent_idx = fdict.get("parent") + folder.root = fdict.get("root") folder.name = encode(fdict["title"]) for record in fdict["children"]: