Skip to main content
JADarnell
Inspiring
January 3, 2011
Question

(All versions) NodeIDClass

  • January 3, 2011
  • 1 reply
  • 2045 views

I am attempting to build my first PanelTreeView widget, and finding it extremely complex.  I have four columns that have no children and a varying number of rows.  The dialog will look something like this:

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

x  FileName            x    FilePath     x          Command1    x   Command2   x

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

x   Abc.indd            x  C:\def\xyz    x          relink             x  delete            x

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

x  Ghi.indd              x  C:\def\xyz    x          relink             x  delete             x

and so on.

First of all, since listbox is going to be deprecated some day, I am trying to follow the documentation's recommendation that I replace it with a panel tree view.

Is a panel tree view the best widget to use?  Is there a simpler widget since I don't need to expand any rows?

If paneltreeview is the best widget to use, then I have a whole bevy of questions, but for now I will ask just this one:  In the PanelTreeView sample, it creates a custom nodeid class inheriting from NodeIDClass, which is essentially a pure virtual class.

In that class, they have two functions: Read() = 0 and Write() = 0, but they don't indicate what the reading and writing is for so I don't have a clue as to what they are used for except for a vague sense that something gets read/written.  Does anyone have a clue as to what those two pure virtual functions are for?

TIA!

R,

John

This topic has been closed for replies.

1 reply

Inspiring
January 3, 2011

If I remember that correctly, one example where those NodeIDs are streamed is when the treeview controller suspends (on hide) and resumes its state including the selected nodes.

See also comments of ITreeNodeIDData - which is persistent.

Remember there are already prebuilt instances of NodeIDClass - FileNodeID could fit your purpose, or IntNodeID, StringNodeID, UIDNodeID.

Dirk