getParentItemForBookmark => getParentItemForBookmarkItem
git-svn-id: http://www.cozmixng.org/repos/piro/treestyletab/trunk@4849 599a83e7-65a4-db11-8015-0010dcdd6dc2
This commit is contained in:
parent
83a7f89827
commit
8623f70bed
@ -61,7 +61,7 @@ var TreeStyleTabBookmarksProperty = {
|
||||
initParentMenuList : function()
|
||||
{
|
||||
var id = gEditItemOverlay.itemId;
|
||||
var parent = TreeStyleTabService.getParentItemForBookmark(id);
|
||||
var parent = TreeStyleTabService.getParentItemForBookmarkItem(id);
|
||||
|
||||
var popup = this.popup;
|
||||
var range = document.createRange();
|
||||
@ -82,7 +82,7 @@ var TreeStyleTabBookmarksProperty = {
|
||||
let parent;
|
||||
let current = aId;
|
||||
let nest = 0;
|
||||
while ((parent = current in parents ? parents[current] : TreeStyleTabService.getParentItemForBookmark(current) ) != -1)
|
||||
while ((parent = current in parents ? parents[current] : TreeStyleTabService.getParentItemForBookmarkItem(current) ) != -1)
|
||||
{
|
||||
if (siblings.indexOf(parent) >= siblings.indexOf(current)) break;
|
||||
nest++;
|
||||
|
@ -2622,7 +2622,7 @@ catch(e) {
|
||||
this._addingBookmarkTreeStructure = [];
|
||||
},
|
||||
|
||||
getParentItemForBookmark : function(aId)
|
||||
getParentItemForBookmarkItem : function(aId)
|
||||
{
|
||||
if (aId < 0) return -1;
|
||||
var annotations = PlacesUtils.getAnnotationsForItem(aId);
|
||||
@ -2637,7 +2637,7 @@ catch(e) {
|
||||
getTreeStructureFromBookmarkItems : function(aIDs)
|
||||
{
|
||||
var treeStructure = aIDs.map(function(aId) {
|
||||
let id = this.getParentItemForBookmark(aId);
|
||||
let id = this.getParentItemForBookmarkItem(aId);
|
||||
return id < 0 ? -1 : aIDs.indexOf(id);
|
||||
}, this);
|
||||
treeStructure = treeStructure.reverse();
|
||||
|
Loading…
Reference in New Issue
Block a user