Nos bénévoles n'ont pas encore traduit cet article en Français. Inscrivez-vous et aidez-nous à réaliser cette tâche !
Vous pouvez également lire cet article en English (US).
This object removes itself from the associated result when the tree is detached; this prevents circular references. It's important to be aware of this—if you want to reuse the same viewer, you need to keep your own reference to it, then reinitialize it when the tree changes.
If you use this object and attach it to a result without attaching it to a tree, then forget about it, it will leak.
| || || |
Controls whether duplicate adjacent elements are collapsed into a single item in the tree. This prevents you from seeing multiple entries for things when you have selected to get visits. When you sort by date, the multiple entries will then appear because they will be separated (unless you clicked reload a bunch of times in a row). If you know you'll only ever want one entry per site, you should ask for URIs back instead of visits so it will be more efficient.
| || ||This tells you how many items are in the flattened list of results, that is how many rows are in this tree right now. The tree adaptor will also QI to |
| || ||Returned by |
Returns the node for a given row index. This is only valid when a tree is attached.
nsINavHistoryResultNode nodeForTreeIndex( in unsigned long aIndex );
- The row index of the note to return.
The node located at the specified index in the tree.
Returns the row index corresponding to the specified node within the tree, or
INDEX_INVISIBLE if the tree is unattached or the node is not visible (if, for example, its parent container is collapsed).
unsigned long treeIndexForNode( in nsINavHistoryResultNode aNode );
- The node whose index is to be returned. This must be a node retrieved from the same result that the viewer displays.
The row index of the node specified by
INDEX_INVISIBLE for nodes that are hidden (by their parents being collapsed, for example) or if there is no attached tree.