rem:  if (transaction.isValid[i]) { if (BMSVC.isBookmarkedResource(rSource)) rSource = BMSVC.cloneResource(rSource); transaction.item  [i] = rSource; transaction.parent[i] = aTarget.parent; transaction.index [i] = index++; } else { transaction.item  [i] = rSource; transaction.parent[i] = aSelection.parent[i]; } 
add: if (BMSVC.isBookmarkedResource(rSource)) rSource = BMSVC.cloneResource(rSource); transaction.item  [i] = rSource; transaction.parent[i] = aTarget.parent; transaction.index [i] = index++; 
context:   insertSelection: function (aAction, aSelection, aTarget)  {    var transaction     = new BookmarkInsertTransaction(aAction);    transaction.item    = new Array(aSelection.length);    transaction.parent  = new Array(aSelection.length);    transaction.index   = new Array(aSelection.length);    if (aAction != "move")      transaction.isValid = BookmarksUtils.isSelectionValidForInsertion(aSelection, aTarget, aAction);    else // isValid has already been determined in moveSelection      transaction.isValid = aSelection.isValid;    var index = aTarget.index;    for (var i=0; i<aSelection.length; ++i) {      var rSource = aSelection.item[i];            if (transaction.isValid[i]) {        if (BMSVC.isBookmarkedResource(rSource))          rSource = BMSVC.cloneResource(rSource);        transaction.item  [i] = rSource;        transaction.parent[i] = aTarget.parent;        transaction.index [i] = index++;      } else {        transaction.item  [i] = rSource;        transaction.parent[i] = aSelection.parent[i];      }     }    if (!BookmarksUtils.all(transaction.isValid))      SOUND.beep();    var isCancelled = !BookmarksUtils.any(transaction.isValid);    if (!isCancelled) {      BMSVC.transactionManager.doTransaction(transaction);      BookmarksUtils.flushDataSource();    }    return !isCancelled;  },
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/ac77f358a61b45de690bdb84b46470c08b2a00a8/bookmarks.js/buggy/browser/components/bookmarks/content/bookmarks.js