Community
Participate
Working Groups
(From the newsgroup) R3.4.2 (no, we can't migrate to 3.5 yet), WinXP I have a working CNF in my RCP -- nice navigator appears, shows the workspace, actions like "New -> Folder" work, all fine. I've added a bunch of objectContribution's, all of which work. Then, to try to add more content to the tree, I followed the directions in: http://help.eclipse.org/galileo/index.jsp?topic=/org.eclipse .platform.doc.isv/guide/cnf.htm and the more extensive ones in: http://scribbledideas.blogspot.com/2006/07/pdf-versions-now- available.html I have a content-provider and a label-provider and a bunch of XML that (to me) looks essentially identical to what is in the help docs ... But all I get when I try to expand the resource-type to which I've tried to attach the extra content is an error message: "Error: no label provider for ..." (and then the path of the resource). The fact that the CNF offers a child of the resource-type to which I've tried to attach the extra content indicates that some part of the plugging in worked. Obviously almost anything could be wrong, but does that error provide any sort of clue as to where to look? And what hints are there for debugging this? (For example, since my content-provider and label-provider are not being called, no point in setting breakpoints in them ...) -Paul Report message to a moderator - Re: Common Navigator "navigatorContent" fails [message #495927 is a reply to message #495167 ] Fri, 06 November 2009 11:36 Go to previous message Paul E. Keyser is currently offline Paul E. Keyser Messages: 845 Registered: July 2009 Senior Member Paul E. Keyser wrote: > R3.4.2 (no, we can't migrate to 3.5 yet), WinXP > > But all I get when I try to expand the resource-type to which I've tried > to attach the extra content is an error message: "Error: no label > provider for ..." (and then the path of the resource). > Found it -- the bug was (no surprise) in my code: I was returning a value of type Foo from the ContentProvider and the LabelProvider would return null for a value of type Foo. The example code does have a label-provider returning null for unhandled types ... and evidently the CNF handles a null from a LabelProvider by displaying that somewhat cryptic error. A clearer error-message might help: "Available label-providers all returned null for ..."