Comment 110 for bug 193141

Revision history for this message
In , Mak77 (mak77) wrote :

the problem in the right pane of the organizer is due to this code in treeView.js

  isContainer: function PTV_isContainer(aRow) {
    this._ensureValidRow(aRow);
    if (this._flatList)
      return false; // but see getCellProperties

for a flatList containers are not marked as containers (but a container atom is manually added to them), so when D&D code calls isContainer it gets false and does not drop in

in getCellProperties:

    // To disable the tree gestures for containers (e.g. double-click to open)
    // we don't mark container nodes as such in flat list mode. The container
    // appearance is desired though, so we add the container atom manually.
    if (this._flatList && PlacesUtils.nodeIsContainer(node))
      aProperties.AppendElement(this._getAtomFor("container"));

getInsertionPoint and other D&D functions use view.isContainer() and view.isContainerOpen() that are returning false

Mano: why they should not be reported as containers there? i've tried to comment out the if code and everything is working fine (double click too)