Opened 15 years ago

Closed 15 years ago

#3314 closed task (fixed)

Tree: implement icons

Reported by: bill Owned by: bill
Priority: high Milestone: 0.9
Component: Dijit Version: 0.9
Keywords: Cc:
Blocked By: Blocking:

Description (last modified by bill)

The tree control should be able to put icons to the left of each label. Icons should be specified in CSS as background images (they won't show up in high-contrast mode but that's OK because the text is still there).

User defines a class for each icon (just like Button and Menu icons) and then defines a function that generates the icon class based on the and the node expanded/closed state.

Maybe a default code like

iconAttr: "icon",

getIconClass: function(store, item, /*Boolean*/ opened){
   return store.getValue(item, this.iconAttr);

(For folder nodes there can be two icons, one for when it's expanded and one for when it's contracted, so we call the function every time we change state.)

Change History (4)

comment:1 Changed 15 years ago by bill

Milestone: 0.91.0

comment:2 Changed 15 years ago by bill

Description: modified (diff)

comment:3 Changed 15 years ago by bill

Milestone: 1.00.9
Status: newassigned

comment:4 Changed 15 years ago by bill

Resolution: fixed
Status: assignedclosed

(In [10265]) Implement icons for tree (fixes #3314). Still need to support change of icon for expanded/contracted state (ie, opened/closed folder)

Note: See TracTickets for help on using tickets.